Data import and export in RethinkDB
RethinkDB provides the facility to dump existing data either coming from traditional databases such as MySQL and MSSQL in a suitable format, that is, CSV
or JSON
, or freshly generated JSON documents.
In Chapter 3, Data Exploration Using RethinkDB, we used the import
utility to dump a JSON file consisting of 1,000 documents directly into a table. In this section, we are going to refresh the import
utility.
Here is the command:
rethinkdb import -f <file path> --table <Database name>.<table name>
You can also specify the port options and other configuration; for more information, please visit Chapter 3, Data Exploration Using RethinkDB.
Let's look at a few use cases where we can really make use of the import
utility. ...
Get Mastering RethinkDB now with the O’Reilly learning platform.
O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.