IP Library Granted Patent US 12,650,982
Granted Patent B2
US 12,650,982 · App. 18/988,025 · Granted Jun 9, 2026

Query refresh using multiple processing pipelines

Inventors: Tyler Arthur Akidau (Seattle, WA); Fabian Hueske (Berlin, DE); Tyler Jones (Redwood City, CA); Daniel Mills (Seattle, WA); Leon Papke (Berlin, DE); Prasanna Rajaperumal (Bangalore, IN); Daniel E. Sotolongo (Seattle, WA)
Assignee: Snowflake Inc.
G06F16/24539
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 12,650,982
App. No.
18/988,025
Granted
Jun 9, 2026
Kind
B2
Abstract

A system includes at least one hardware processor and at least one memory storing instructions that cause the at least one hardware processor to perform operations. The operations include generating a log of changes posted to a plurality of intermediate materialized tables (MTs) during execution of a query in a network-based database system. The query is associated with a source MT that the intermediate MTs depend on. The operations include rendering the log of changes into a dependency graph. The operations include configuring a plurality of processing pipelines based on the dependency graph. The operations include performing refreshes on one or more of the plurality of intermediate MTs in at least one of the plurality of processing pipelines to complete the refresh operation. The refreshes are performed responsive to detecting an instruction for a refresh operation on the source MT.

Claims (56)

1 . A system comprising:

at least one hardware processor; and

at least one memory storing instructions that cause the at least one hardware processor to perform operations comprising:

generating a source materialized table (MT) based on a table definition, the table definition comprising a query on one or more base tables, and a lag duration value, the lag duration value indicating a maximum time period that a result of a prior refresh of the query can lag behind a current time instance;

generating a log of changes posted to a plurality of intermediate MTs during execution of the query in a network-based database system, the query associated with the source MT that the intermediate MTs depend on;

rendering the log of changes into a dependency graph;

configuring a plurality of processing pipelines based on the dependency graph; and

responsive to detecting an instruction for a refresh operation on the source MT, performing refreshes on one or more of the plurality of intermediate MTs in at least one of the plurality of processing pipelines to complete the refresh operation.

2 . The system of claim 1 , wherein the operations comprise:

partitioning the dependency graph into a plurality of sub-graphs based on an association of the changes to one or more user accounts of the network-based database system.

3 . The system of claim 2 , wherein the operations comprise:

configuring the plurality of processing pipelines to correspond to the plurality of sub-graphs.

4 . The system of claim 1 , wherein the operations comprise:

configuring a sub-graph of the plurality of sub-graphs to indicate dependencies among a subset of the plurality of intermediate MTs.

5 . The system of claim 4 , wherein the operations comprise:

configuring the subset with at least one composite MT, the at least one composite MT depending on at least two remaining MTs of the subset.

6 . The system of claim 1 , wherein the operations comprise:

performing the refreshes on the plurality of intermediate MTs in parallel in the plurality of processing pipelines to complete the refresh operation.

7 . The system of claim 1 , wherein the operations comprise:

generating the plurality of intermediate MTs based on a plurality of data processing operations in a query plan of the query.

8 . A method comprising:

generating, by at least one hardware processor, a source materialized table (MT) based on a table definition, the table definition comprising a query on one or more base tables, and a lag duration value, the lag duration value indicating a maximum time period that a result of a prior refresh of the query can lag behind a current time instance;

generating, by the at least one hardware processor, a log of changes posted to a plurality of intermediate MTs during execution of the query in a network-based database system, the query associated with the source MT that the intermediate MTs depend on;

rendering the log of changes into a dependency graph;

configuring a plurality of processing pipelines based on the dependency graph; and

responsive to detecting an instruction for a refresh operation on the source MT, performing refreshes on one or more of the plurality of intermediate MTs in at least one of the plurality of processing pipelines to complete the refresh operation.

9 . The method of claim 8 , further comprising:

partitioning the dependency graph into a plurality of sub-graphs based on an association of the changes to one or more user accounts of the network-based database system.

10 . The method of claim 9 , further comprising:

configuring the plurality of processing pipelines to correspond to the plurality of sub-graphs.

11 . The method of claim 9 , further comprising:

configuring a sub-graph of the plurality of sub-graphs to indicate dependencies among a subset of the plurality of intermediate MTs.

12 . The method of claim 11 , further comprising:

configuring the subset with at least one composite MT, the at least one composite MT depending on at least two remaining MTs of the subset.

13 . The method of claim 8 , further comprising:

performing the refreshes on the plurality of intermediate MTs in parallel in the plurality of processing pipelines to complete the refresh operation.

14 . The method of claim 8 , further comprising:

generating the plurality of intermediate MTs based on a plurality of data processing operations in a query plan of the query.

15 . A computer-storage medium comprising instructions that, when executed by one or more processors of a machine, configure the machine to perform operations comprising:

generating a source materialized table (MT) based on a table definition, the table definition comprising a query on one or more base tables, and a lag duration value, the lag duration value indicating a maximum time period that a result of a prior refresh of the query can lag behind a current time instance;

generating a log of changes posted to a plurality of intermediate MTs during execution of the query in a network-based database system, the query associated with the source MT that the intermediate MTs depend on;

rendering the log of changes into a dependency graph;

configuring a plurality of processing pipelines based on the dependency graph; and

responsive to detecting an instruction for a refresh operation on the source MT, performing refreshes on one or more of the plurality of intermediate MTs in at least one of the plurality of processing pipelines to complete the refresh operation.

16 . The computer-storage medium of claim 15 , the operations further comprising:

partitioning the dependency graph into a plurality of sub-graphs based on an association of the changes to one or more user accounts of the network-based database system.

17 . The computer-storage medium of claim 16 , the operations further comprising:

configuring the plurality of processing pipelines to correspond to the plurality of sub-graphs.

18 . The computer-storage medium of claim 16 , the operations further comprising:

configuring a sub-graph of the plurality of sub-graphs to indicate dependencies among a subset of the plurality of intermediate MTs.

19 . The computer-storage medium of claim 18 , the operations further comprising:

configuring the subset with at least one composite MT, the at least one composite MT depending on at least two remaining MTs of the subset.

20 . The computer-storage medium of claim 15 , the operations further comprising:

performing the refreshes on the plurality of intermediate MTs in parallel in the plurality of processing pipelines to complete the refresh operation.

21 . The computer-storage medium of claim 15 , the operations further comprising:

generating the plurality of intermediate MTs based on a plurality of data processing operations in a query plan of the query.

Assignments (1)
ASSIGNMENT OF ASSIGNOR'S INTEREST Recorded Dec 19, 2024
From: AKIDAU, TYLER ARTHUR; HUESKE, FABIAN; JONES, TYLER; MILLS, DANIEL; PAPKE, LEON; RAJAPERUMAL, PRASANNA; SOTOLONGO, DANIEL E.
To: SNOWFLAKE INC.
Reel/Frame 069641/0862 →
Continuity (4)
Continuation 18362898 · Jul 31, 2023
Continuation 17931590 · Sep 13, 2022
Provisional Application 63366197 · Jun 10, 2022
Related Publication 20250117382A1 · Apr 10, 2025
References Cited (22)
US 6205451B1 · Norcott · 2001 [cited by examiner]
US 6334128B1 · Norcott · 2001 [cited by examiner]
US 9430552B2 · Adya · 2016 [cited by examiner]
US 10187260B1 · Chen et al. · 2019 [cited by applicant]
US 11379525B1 · Deutsch et al. · 2022 [cited by applicant]
US 11762855B1 · Akidau et al. · 2023 [cited by applicant]
US 20040122868A1 · Chan · 2004 [cited by examiner]
US 20120054533A1 · Shi et al. · 2012 [cited by applicant]
US 20120246179A1 · Garza et al. · 2012 [cited by applicant]
US 20140379904A1 · Shimasaki et al. · 2014 [cited by applicant]
US 20150149436A1 · Mckenna et al. · 2015 [cited by applicant]
US 20150199415A1 · Bourbonnais · 2015 [cited by examiner]
US 20170147671A1 · Bensberg · 2017 [cited by examiner]
US 20190146970A1 · Chamieh et al. · 2019 [cited by applicant]
US 20190392067A1 · Sonawane et al. · 2019 [cited by applicant]
US 20230409574A1 · Akidau et al. · 2023 [cited by applicant]
“U.S. Appl. No. 17/931,590, Non Final Office Action mailed May 4, 2023”, 10 pgs. [cited by applicant]
“U.S. Appl. No. 17/931,590, Notice of Allowance mailed Jul. 11, 2023”, 8 pgs. [cited by applicant]
“U.S. Appl. No. 17/931,590, Response filed May 31, 2023 to Non Final Office Action mailed May 4, 2023”, 12 pgs. [cited by applicant]
“U.S. Appl. No. 18/362,898, Non Final Office Action mailed Mar. 28, 2024”, 11 pgs. [cited by applicant]
“U.S. Appl. No. 18/362,898, Notice of Allowance mailed Oct. 16, 2024”, 8 pgs. [cited by applicant]
“U.S. Appl. No. 18/362,898, Response filed Jun. 28, 2024 to Non Final Office Action mailed Mar. 28, 2024”, 12 pgs. [cited by applicant]