IP Library Granted Patent US 12,681,934
Granted Patent B2
US 12,681,934 · App. 18/769,269 · Granted Jul 14, 2026

Efficient merging of tabular data with post-processing compaction

Inventors: Bart Samwel (Oegstgeest, NL); Tathagata Das (New Haven, CT); Lars Kroll (Almere, NL); Yijia Cui (Sunnyvale, CA); Juliusz Sompolski (Amsterdam, NL); Tom Van Bussel (Amsterdam, NL); Prakhar Jain (Sunnyvale, CA)
Assignee: Databricks, Inc.
G06F16/24544G06F11/3409G06F16/2282G06F16/285
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,681,934
App. No.
18/769,269
Filed
Jul 10, 2024
Granted
Jul 14, 2026
Kind
B2
Examiner
LE, HUNG D
Art Unit
2161
USPC
707/714
Abstract

A method, system, and computer system for performing an operation with respect to a target table are disclosed. The method includes performing first and second jobs, obtaining one or more other resulting files based at least in part on unmatched rows, and obtaining a set of processed files based at least in part on performing a post-processing operation with respect to the set of resulting files. The set of processed files has less files than the set of resulting files. Performing the first job includes determining a set of matching target table files and storing target table information indicating for each of the set of matching target table files, a particular set of rows having matching rows. Performing the second job includes performing a matching action based on matched rows and obtaining the second job resulting file(s).

Claims (46)

1 . A system comprising:

one or more computer processors; and

one or more computer-readable mediums storing instructions that, when executed by the one or more computer processors, cause the system to perform operations comprising:

merging a target table and a source table, wherein the source table has one or more records that are different from the target table, wherein the merging yields a set of resulting files;

determining that a subset of the set of resulting files satisfy a compaction criteria defined by a compaction policy by determining that a number of files in the subset of the set of resulting files is greater than a threshold number of files;

compacting the subset of the set of resulting files to obtain a set of compacted files, wherein the compacting reduces a number of files in the subset of the set of resulting files;

determining that a given file from the set of resulting files should not be compacted based on determining that a size of the given file is larger than a threshold size defined by the compaction policy; and

obtaining a resulting table based at least in part on the set of compacted files and the given file that is not compacted, the resulting table comprising a result of merging the target table and the source table.

2 . The system of claim 1 , wherein the resulting table is obtained based at least in part on the set of compacted files and one or more remaining files of the set of resulting files that were not subject to compaction.

3 . The system of claim 2 , wherein determining that the subset of the set of resulting files satisfy the compaction criteria comprises:

determining that an expected amount of time for combining the subset of the set of resulting files does not exceed a time threshold defined by the compaction policy.

4 . The system of claim 1 , wherein determining that the subset of the set of resulting files satisfy the compaction criteria comprises:

determining that a size of each file in the subset of the set of resulting files is less than the threshold size defined by the compaction policy.

5 . The system of claim 4 , wherein determining that the subset of the set of resulting files satisfy the compaction criteria further comprises:

determining that the subset of the set of resulting files are ordered adjacent to each other in the set of resulting files.

6 . The system of claim 4 , wherein determining that the subset of the set of resulting files satisfy the compaction criteria further comprises:

determining that a number of files in the set of resulting files exceeds a threshold number of files defined by the compaction policy.

7 . The system of claim 4 , wherein determining that the subset of the set of resulting files satisfy the compaction criteria further comprises:

determining that a merged size of the subset of resulting files does not exceed a threshold merged size defined by the compaction policy.

8 . The system of claim 7 , wherein determining that the subset of the set of resulting files satisfy the compaction criteria further comprises:

determining that a merged size of a first file and a second file from the set of resulting files is larger than the threshold merged size defined by the compaction policy; and

determining that the first file and the second file should not be compacted based on determining that the merged size of the first file and the second file from the set of resulting files is larger than the threshold merged size defined by the compaction policy.

9 . The system of claim 1 , wherein determining that the subset of the set of resulting files satisfy the compaction criteria comprises:

determining that a time of creation of each file within the subset of the set of resulting files falls within a threshold time window defined by the compaction policy.

10 . The system of claim 1 , wherein determining that the subset of the set of resulting files satisfy the compaction criteria comprises:

determining that each file within the subset of the set of resulting files belongs to a same partition of the set of resulting files.

11 . The system of claim 1 , wherein obtaining the resulting table comprises:

identifying a set of unmatched rows among the target table and the source table; and

obtaining the set of resulting files based at least in part on the unmatched rows among the target table and the source table.

12 . A method comprising:

merging a target table and a source table, wherein the source table has one or more records that are different from the target table, wherein the merging yields a set of resulting files;

determining that a subset of the set of resulting files satisfy a compaction criteria defined by a compaction policy by determining that a number of files in the subset of the set of resulting files is greater than a threshold number of files;

compacting the subset of the set of resulting files to obtain a set of compacted files, wherein the compacting reduces a number of files in the subset of the set of resulting files;

determining that a given file from the set of resulting files should not be compacted based on determining that a size of the given file is larger than a threshold size defined by the compaction policy; and

obtaining a resulting table based at least in part on the set of compacted files and the given file that is not compacted, the resulting table comprising a result of merging the target table and the source table.

13 . The method of claim 12 , wherein the resulting table is obtained based at least in part on the set of compacted files and one or more remaining files of the set of resulting files that were not subject to compaction.

14 . The method of claim 12 , wherein determining that the subset of the set of resulting files satisfy the compaction criteria comprises:

determining that a size of each file in the subset of the set of resulting files is less than the threshold size defined by the compaction policy.

15 . The method of claim 14 , wherein determining that the subset of the set of resulting files satisfy the compaction criteria further comprises:

determining that the subset of the set of resulting files are ordered adjacent to each other in the set of resulting files.

16 . A non-transitory computer-readable medium storing instructions that, when executed by one or more computer processors of a computing system, cause the computing system to perform operations comprising:

merging a target table and a source table, wherein the source table has one or more records that are different from the target table, wherein the merging yields a set of resulting files;

determining that a subset of the set of resulting files satisfy a compaction criteria defined by a compaction policy by determining that a number of files in the subset of the set of resulting files is greater than a threshold number of files;

compacting the subset of the set of resulting files to obtain a set of compacted files, wherein the compacting reduces a number of files in the subset of the set of resulting files;

determining that a given file from the set of resulting files should not be compacted based on determining that a size of the given file is larger than a threshold size defined by the compaction policy; and

obtaining a resulting table based at least in part on the set of compacted files and the given file that is not compacted, the resulting table comprising a result of merging the target table and the source table.

Assignments (2)
SECURITY INTEREST Recorded Jan 6, 2025
From: DATABRICKS, INC.
To: JPMORGAN CHASE BANK, N.A., AS COLLATERAL AGENT
Reel/Frame 069825/0419 →
ASSIGNMENT OF ASSIGNOR'S INTEREST Recorded Jul 11, 2024
From: SAMWEL, BART; DAS, TATHAGATA; KROLL, LARS; CUI, YIJIA; SOMPOLSKI, JULIUSZ; VAN BUSSEL, TOM; JAIN, PRAKHAR
To: DATABRICKS, INC.
Reel/Frame 068279/0538 →
Continuity (2)
Continuation 17895877 · Aug 25, 2022
Related Publication 20250013644A1 · Jan 9, 2025
References Cited (57)
US 6300886B1 · Hayami · 2001 [cited by applicant]
US 7188334B1 · Sinclair · 2007 [cited by applicant]
US 8136031B2 · Massand · 2012 [cited by applicant]
US 8359325B1 · Gui et al. · 2013 [cited by applicant]
US 8396860B1 · Ramesh et al. · 2013 [cited by applicant]
US 9740666B1 · Galante et al. · 2017 [cited by applicant]
US 9875277B1 · Kiryakov et al. · 2018 [cited by applicant]
US 10599395B1 · Slager et al. · 2020 [cited by applicant]
US 11256672B1 · Daimler et al. · 2022 [cited by applicant]
US 11256684B1 · Papakonstantinou et al. · 2022 [cited by applicant]
US 11537613B1 · Cruanes · 2022 [cited by examiner]
US 11544285B1 · Govil et al. · 2023 [cited by applicant]
US 11567941B1 · Chimanchode et al. · 2023 [cited by applicant]
US 11755242B2 · Kuo et al. · 2023 [cited by applicant]
US 11868331B1 · Riddle et al. · 2024 [cited by applicant]
US 20010049699A1 · Pratley et al. · 2001 [cited by applicant]
US 20040193565A1 · Feng et al. · 2004 [cited by applicant]
US 20040196845A1 · Kunze et al. · 2004 [cited by applicant]
US 20040243550A1 · Gu et al. · 2004 [cited by applicant]
US 20050076007A1 · Evans et al. · 2005 [cited by applicant]
US 20070083490A1 · Au et al. · 2007 [cited by applicant]
US 20080075278A1 · Gaubatz et al. · 2008 [cited by applicant]
US 20080104498A1 · Molander et al. · 2008 [cited by applicant]
US 20090177621A1 · Le et al. · 2009 [cited by applicant]
US 20120023107A1 · Nachnani et al. · 2012 [cited by applicant]
US 20120173226A1 · Mcevoy et al. · 2012 [cited by applicant]
US 20130159248A1 · Mueller · 2013 [cited by applicant]
US 20150026131A1 · Schreter · 2015 [cited by applicant]
US 20150081652A1 · Bardini et al. · 2015 [cited by applicant]
US 20160275121A1 · Dave et al. · 2016 [cited by applicant]
US 20160292346A1 · Venkatesh et al. · 2016 [cited by applicant]
US 20170206208A1 · Zhu et al. · 2017 [cited by applicant]
US 20180005066A1 · Bellert · 2018 [cited by applicant]
US 20180005067A1 · Bellert · 2018 [cited by applicant]
US 20180060537A1 · Tiwari et al. · 2018 [cited by applicant]
US 20180081946A1 · Bondalapati et al. · 2018 [cited by applicant]
US 20180096007A1 · Liu et al. · 2018 [cited by applicant]
US 20200004840A1 · Zavora · 2020 [cited by examiner]
US 20200133937A1 · Cruanes · 2020 [cited by examiner]
US 20200167343A1 · Cseri · 2020 [cited by examiner]
US 20200175561A1 · Leung · 2020 [cited by examiner]
US 20200183906A1 · Spillane · 2020 [cited by examiner]
US 20200195948A1 · Li et al. · 2020 [cited by applicant]
US 20200201821A1 · Wang · 2020 [cited by examiner]
US 20200201822A1 · Wang · 2020 [cited by examiner]
US 20200278967A1 · Chen · 2020 [cited by applicant]
US 20200394163A1 · Wang et al. · 2020 [cited by applicant]
US 20210037287A1 · Ha · 2021 [cited by examiner]
US 20210200736A1 · Luo · 2021 [cited by examiner]
US 20210303404A1 · Shah et al. · 2021 [cited by applicant]
US 20210303597A1 · Zhang et al. · 2021 [cited by applicant]
US 20210334251A1 · Mire et al. · 2021 [cited by applicant]
US 20210374134A1 · He et al. · 2021 [cited by applicant]
US 20220083566A1 · Ben Ze'Ev · 2022 [cited by examiner]
US 20230034941A1 · Bos et al. · 2023 [cited by applicant]
US 20240070155A1 · Samwel · 2024 [cited by examiner]
United States Office Action, U.S. Appl. No. 17/895,877, filed Nov. 8, 2023, nine pages. [cited by applicant]