You are viewing a plain text version of this content. The canonical link for it is here.
Posted to user@ignite.apache.org by NSquare <te...@gmail.com> on 2020/05/19 09:30:10 UTC
Exporting SQL DB
Hi,
I have a 3 node ignite cluster which stores data in SQL tables. All the
tables and table contents can be seen with sqline.sh tool.
How can I export these tables as an SQL DB file for future reference?
Cheers,
NSquare
Re: Exporting SQL DB
Posted by akorensh <al...@gmail.com>.
Your best choice is to write your own exporter/use sqlline/other tool to get
the data from Ignite.
Ignite's db files are in a proprietary format that can't be used w/other
tools.
more info here:
https://cwiki.apache.org/confluence/display/IGNITE/Ignite+Persistent+Store+-+under+the+hood
--
Sent from: http://apache-ignite-users.70518.x6.nabble.com/
Re: Exporting SQL DB
Posted by NSquare <te...@gmail.com>.
Hi Alex,
Thanks for your response. I want to export the data into a SQL db file
which can be then loaded with any standard SQL viewer. CSV would be
difficult for me as the data stored in these tables is huge. Just to give
some context, one of the services running on this cluster would pump one
record every 10ms and the entire system would run for about 20 hours. There
are 14 such services that pump data with a duration of 20ms to 2 sec per
record for such duration.
I am not sure if ignite stores data to the SQL db file which can be used
for later usage. Please let me know if you need any further information.
-- Nishant
On Wed, May 20, 2020 at 1:42 AM akorensh <al...@gmail.com> wrote:
> Hi,
> You can record data output from sqlline
> 0: jdbc:ignite:thin://127.0.0.1/> !outputformat csv
> jdbc:ignite:thin://127.0.0.1/> !record data.csv
> Saving all output to "data.csv". Enter "record" with no arguments to stop
> it.
> 0: jdbc:ignite:thin://127.0.0.1/> select * from Person
>
> here the output from the "select" will go into data.csv
>
> You can then clean up the csv and use it as need be.
>
> see: https://apacheignite-sql.readme.io/docs/sqlline
> Thanks, Alex
>
>
>
> --
> Sent from: http://apache-ignite-users.70518.x6.nabble.com/
>
Re: Exporting SQL DB
Posted by akorensh <al...@gmail.com>.
Hi,
You can record data output from sqlline
0: jdbc:ignite:thin://127.0.0.1/> !outputformat csv
jdbc:ignite:thin://127.0.0.1/> !record data.csv
Saving all output to "data.csv". Enter "record" with no arguments to stop
it.
0: jdbc:ignite:thin://127.0.0.1/> select * from Person
here the output from the "select" will go into data.csv
You can then clean up the csv and use it as need be.
see: https://apacheignite-sql.readme.io/docs/sqlline
Thanks, Alex
--
Sent from: http://apache-ignite-users.70518.x6.nabble.com/