IP Library Granted Patent US 10,691,682
Granted Patent B2
US 10,691,682 · App. 15/724,457 · Granted Jun 23, 2020

Storing and processing JSON documents in a SQL database table

Inventors: Collin LeGault (Los Gatos, CA); Vinay Sawal (Fremont, CA); Bruce Amberden (Pleasanton, CA)
Assignee: EMC IP Holding Company LLC
G06F16/2438G06F16/22G06F16/221G06F16/2246G06F16/282
View Patent ↗
Loading inventors, assignments & file history…
Monitor This Case
Get email alerts when status or documents change.
Order Certified Copies
Most orders are placed with the USPTO same day — all within 24 business hours.
Order via The Patent Place →
Pre-filled with this patent's details
Quick Facts
Patent No.
US 10,691,682
App. No.
15/724,457
Granted
Jun 23, 2020
Kind
B2
Abstract

Embodiments for storing a JSON document tree in a single SQL database table by defining a schema to store JSON nodes in the table and converting each JSON document into a corresponding set of rows in the table using the schema to encode a hierarchical relationship of nodes and sub-nodes into a path that specifies a node path to a root node for each node. Embodiments further receiving a SQL query to retrieve a specific sub-document, responding to the query by returning all rows of the table belonging to the sub-document, and inflating the returned rows back into a JSON expression using the path to guide reconstruction of the original JSON document tree.

Claims (34)

1. A method comprising:

defining a schema to store JavaScript Object Notation (JSON) nodes in a Structured Query Language (SQL) database table in a memory storage device;

converting each JSON node into a corresponding row of the SQL database table using the schema to encode a hierarchical relationship of nodes and sub-nodes into a path that specifies a node path to a root node for each node;

receiving a SQL query to find a specific sub-node;

responding to the query by returning all rows of the SQL database table belonging to the sub-node; and

inflating the returned rows back into a JSON expression by using the path to guide reconstruction of the original JSON nodes.

2. The method of claim 1 wherein the JSON nodes comprise documents of a JSON document tree.

3. The method of claim 2 wherein the JSON nodes include each of six JSON data types of the group consisting of: object, array, string, number, Boolean, and null.

4. The method of claim 3 wherein the schema comprises an ID, path, type, name, and value; wherein the ID is a unique identification number for a node; the type is a JSON datatype specifier; the name is a user configurable JSON node name if the node is an object, and the value is a JSON node value if the node is not an array.

5. The method of claim 2 wherein the converting comprises:

reading the documents using a JSON database library function; and

automatically generating SQL insert statements into the documents to convert each document into the corresponding row of the SQL database table.

6. The method of claim 5 wherein the SQL database table comprises a single table, the method further comprising saving the entire document tree in the single SQL table.

7. The method of claim 6 wherein the single table is implemented in one of: SQLite3, PostgreSQL, MySQL, and Oracle.

8. The method of claim 2 wherein the inflating comprises using a JSON database library function to back-convert each corresponding row of the SQL database table into a live Javascript data object for a corresponding document or sub-document of the JSON document tree.

9. The method of claim 8 further comprising displaying the live Javascript data object to a user through a graphical user interface.

10. A system comprising:

an application executed in a networked computer to perform tasks using data processed in the system;

an application adapter providing application-level JSON (JavaScript Object Notation) storage handling functions;

a JSON adapter converting JSON documents embodying the data into corresponding rows of a SQL database table and inflates the rows of the table back into corresponding documents in response to a SQL query for the corresponding documents;

a database driver communicating between the JSON adapter and a database engine;

a storage device storing the data in the SQL database table as specified by the database engine.

11. The system of claim 10 wherein the JSON adapter converts JSON documents into SQL insert, update, and delete queries.

12. The system of claim 10 wherein the SQL database table is a single table and is implemented in one of: SQLite3, PostgreSQL, MySQL, and Oracle.

13. The system of claim 12 wherein the data is originally stored in a JSON document tree having nodes and sub-nodes corresponding to each of the JSON documents.

14. The system of claim 13 wherein the JSON nodes include each of six JSON data types of the group consisting of: object, array, string, number, Boolean, and null.

15. The system of claim 14 wherein the schema comprises an ID, path, type, name, and value; wherein the ID is a unique identification number for a node; the type is a JSON datatype specifier; the name is a user configurable JSON node name if the node is an object, and the value is a JSON node value if the node is not an array.

16. The system of claim 15 wherein the JSON adapter reads the documents using a JSON database library function, and automatically generates SQL insert statements into the documents to convert each document into the corresponding row of the SQL database table.

17. The system of claim 16 wherein the JSON adapter inflates by using a JSON database library function to back-convert each corresponding row of the SQL database table into a live Javascript data object for a corresponding document or sub-document of the JSON document tree.

18. A method comprising:

creating a JSON-style table in a SQL database;

writing a JSON document to the database by deflating the JSON document and executing a single insert query to write the entire JSON document to the database in this single query; and

reading the JSON document by executing a select query to request the document by its identifier (id), wherein the select query reads an entire JSON document sub-tree from the database, and inflating the JSON rows returned by the database into the JSON document.

19. The method of claim 18 further comprising defining a schema for the JSON-style table, wherein the schema comprises an ID, path, type, name, and value; wherein the ID is a unique identification number for a node; the type is a JSON datatype specifier; the name is a user configurable JSON node name if the node is an object, and the value is a JSON node value if the node is not an array.

Assignments (8)
RELEASE OF SECURITY INTEREST IN PATENTS PREVIOUSLY RECORDED AT REEL/FRAME (053546/0001) Recorded Jun 23, 2022
From: THE BANK OF NEW YORK MELLON TRUST COMPANY, N.A., AS NOTES COLLATERAL AGENT
To: DELL MARKETING L.P. (ON BEHALF OF ITSELF AND AS SUCCESSOR-IN-INTEREST TO CREDANT TECHNOLOGIES, INC.); DELL INTERNATIONAL L.L.C.; DELL PRODUCTS L.P.; DELL USA L.P.; EMC CORPORATION; DELL MARKETING CORPORATION (SUCCESSOR-IN-INTEREST TO FORCE10 NETWORKS, INC. AND WYSE TECHNOLOGY L.L.C.); EMC IP HOLDING COMPANY LLC
Reel/Frame 071642/0001 →
RELEASE OF SECURITY INTEREST IN PATENTS PREVIOUSLY RECORDED AT REEL/FRAME (044535/0109) Recorded May 20, 2022
From: THE BANK OF NEW YORK MELLON TRUST COMPANY, N.A., AS NOTES COLLATERAL AGENT
To: DELL PRODUCTS L.P.; EMC CORPORATION; EMC IP HOLDING COMPANY LLC; DELL MARKETING CORPORATION (SUCCESSOR-IN-INTEREST TO WYSE TECHNOLOGY L.L.C.)
Reel/Frame 060753/0414 →
RELEASE OF SECURITY INTEREST AT REEL 044535 FRAME 0001 Recorded Nov 2, 2021
From: CREDIT SUISSE AG, CAYMAN ISLANDS BRANCH
To: DELL PRODUCTS L.P.; EMC CORPORATION; EMC IP HOLDING COMPANY LLC; WYSE TECHNOLOGY L.L.C.
Reel/Frame 058298/0475 →
SECURITY AGREEMENT Recorded Apr 22, 2020
From: CREDANT TECHNOLOGIES INC.; DELL INTERNATIONAL L.L.C.; DELL MARKETING L.P.; DELL PRODUCTS L.P.; DELL USA L.P.; EMC CORPORATION; FORCE10 NETWORKS, INC.; WYSE TECHNOLOGY L.L.C.; EMC IP HOLDING COMPANY LLC
To: THE BANK OF NEW YORK MELLON TRUST COMPANY, N.A.
Reel/Frame 053546/0001 →
SECURITY AGREEMENT Recorded Mar 21, 2019
From: CREDANT TECHNOLOGIES, INC.; DELL INTERNATIONAL L.L.C.; DELL MARKETING L.P.; DELL PRODUCTS L.P.; DELL USA L.P.; EMC CORPORATION; FORCE10 NETWORKS, INC.; WYSE TECHNOLOGY L.L.C.; EMC IP HOLDING COMPANY LLC
To: THE BANK OF NEW YORK MELLON TRUST COMPANY, N.A.
Reel/Frame 049452/0223 →
PATENT SECURITY AGREEMENT (NOTES) Recorded Nov 29, 2017
From: DELL PRODUCTS L.P.; EMC CORPORATION; EMC IP HOLDING COMPANY LLC; WYSE TECHNOLOGY L.L.C.
To: THE BANK OF NEW YORK MELLON TRUST COMPANY, N.A., AS COLLATERAL AGENT
Reel/Frame 044535/0109 →
PATENT SECURITY AGREEMENT (CREDIT) Recorded Nov 29, 2017
From: DELL PRODUCTS L.P.; EMC CORPORATION; EMC IP HOLDING COMPANY LLC; WYSE TECHNOLOGY L.L.C.
To: CREDIT SUISSE AG, CAYMAN ISLANDS BRANCH, AS COLLATERAL AGENT
Reel/Frame 044535/0001 →
ASSIGNMENT OF ASSIGNOR'S INTEREST Recorded Oct 4, 2017
From: LEGAULT, COLLIN; SAWAL, VINAY; AMBERDEN, BRUCE
To: DELL PRODUCTS LP
Reel/Frame 043779/0035 →