US 12,007,993 B1
Multi database queries
Fabio Angius, El Sobrante, CA (US); Chen Luo, San Mateo, CA (US); and Sarvesh Singh, Issaquah, WA (US)
Assigned to Snowflake Inc., Bozeman, MT (US)
Filed by Snowflake Inc., Bozeman, MT (US)
Filed on Jun. 30, 2023, as Appl. No. 18/345,900.
Int. Cl. G06F 16/00 (2019.01); G06F 16/23 (2019.01); G06F 16/2453 (2019.01); G06F 16/28 (2019.01)
CPC G06F 16/24542 (2019.01) [G06F 16/2329 (2019.01); G06F 16/24535 (2019.01); G06F 16/285 (2019.01)] 18 Claims
OG exemplary drawing
 
1. A method comprising:
receiving, by at least one processor of a network-based data system, a query;
determining that the query references a plurality of databases stored in the network-based data system;
compiling objects referenced in the query associated with the plurality of databases;
generating a connection string based on the compiled objects, the connection string including mapping information related to the plurality of databases and cluster information describing locations of the plurality of databases are stored in the network-based data system;
generating a query plan including a set of operators to execute the query, the query plan including the connection string;
transmitting the query plan to one or more execution platforms in the network-based data system; and
executing, by the one or more execution platforms, the query plan using the connection string to access the objects in the plurality of databases, executing the query plan includes:
retrieving read versions of the objects from the plurality of databases using the connection string information in the query plan;
retrieving transaction status information for the objects;
generating transaction contexts for the objects based on the transaction status information; and
performing a scan operator of the set of operators in the query plan on at least one of the objects using the respective transaction context of the object.