Ashu
Ashu

Reputation: 357

How to load JSON data in snappydata table with rowstore mode using sql query?

I'm using snappydata.I have 1M rows of JSON file,i want to load that JSON file to snappydata table using sql(snappydata sql).

Upvotes: 1

Views: 49

Answers (1)

jagsr
jagsr

Reputation: 535

Step 1)

create external table t1 using json options(path 'location of your json file(s)');

Step 2)

Load into a Snappy column or row table:

create table My-in-memory-table using column as (select * from t1);

I think, there could be some issue if your json docs are multi-line. but, there are ways to work around this.

Upvotes: 1

Related Questions