| CPC G06F 16/254 (2019.01) [G06F 16/835 (2019.01)] | 27 Claims |

|
1. A system comprising:
at least one hardware processor; and
a memory storing instructions that cause the at least one hardware processor to perform operations comprising:
receiving a query, the query referencing a unified representation for structured type data and semi-structured type data, the unified representation being provided in storage and in memory during query processing, the unified representation comprising a set of structured type fields that include a set of semi-structured typed fields that enables type safety and enforcement for the set of structured type fields, and flexibility for the set of semi-structured typed fields in a same column, the unified representation in storage including type information for the semi-structured type data as part of the semi-structured type data, the unified representation being utilized for structured type data and semi-structured type data;
processing the query using the unified representation stored in the memory, the unified representation providing performance parity between structured type data and semi-structured type data;
receiving a set of code statements, the set of code statements including first code indicating a particular structured data type;
determining that the set of code statements includes a definition of content type for an array, an object, or a map;
determining that the set of code statements includes second code to perform a type conversion from the particular structured data type to a particular semi-structured data type; and
performing, using the second code, the type conversion from the particular structured data type to the particular semi-structured data type based at least in part on the definition of content type.
|