BlackMagic: Automatic Inlining of Scalar UDFs into SQL Queries with Froid
Summary: Froid automatically translates imperative, multistatement scalar UDFs into equivalent relational algebra, exposing them to SQL optimization. This eliminates black-box, iterative execution in favor of set-oriented parallel plans, yielding orders-of-magnitude speedups and powering SQL Server 2019 UDF inlining. (summarized by gpt-5.6-luna on Jul 24 2026)
Incoming Non-self Citations Over Time
Authors
- 1. Karthik Ramachandra (Microsoft)
- 2. Kwanghyun Park (Microsoft)
BibTeX Citation
@article{ramachandra_vldb19,
title = {{BlackMagic: Automatic Inlining of Scalar UDFs into SQL Queries with Froid}},
author = {Ramachandra, Karthik and Park, Kwanghyun},
journal = {PVLDB},
series = {{VLDB} '19},
volume = {12},
number = {12},
pages = {1810--1813},
doi = {10.14778/3352063.3352072},
url = {https://doi.org/10.14778/3352063.3352072},
year = {2019}
}
Incoming Citations (Sorted by Pagerank)
Showing 9 of 9 citing papers.
| Rank | Citing Paper | Year | Venue | Pagerank |
|---|---|---|---|---|
| 3,194 | One WITH RECURSIVE is Worth Many GOTOs | 2021 | SIGMOD | 7.5498012e-05 |
| 5,684 | iTurboGraph: Scaling and Automating Incremental Graph Analytics | 2021 | SIGMOD | 6.0391416e-05 |
| 6,400 | Functional-Style SQL UDFs With a Capital 'F' | 2020 | SIGMOD | 5.7981078e-05 |
| 8,345 | MONSOON: Multi-Step Optimization and Execution of Queries with Partially Obscured Predicates | 2020 | SIGMOD | 5.3511996e-05 |
| 9,493 | ProcAnalyzer: Effective Code Analyzer for Tuning Imperative Programs in SAP HANA | 2020 | SIGMOD | 5.1708619e-05 |
| 9,637 | QURE: AI-Assisted and Automatically Verified UDF Inlining | 2025 | SIGMOD | 5.1462239e-05 |
| 10,223 | SQL Engines Excel at the Execution of Imperative Programs | 2024 | VLDB | 5.0572221e-05 |
| 10,448 | EncoderForge: Generating Efficient SQL for Encoders in Machine Learning Inference Pipelines | 2026 | SIGMOD | 4.9793485e-05 |
| 11,602 | Hardware-Efficient Data Imputation through DBMS Extensibility | 2024 | VLDB | 4.9793485e-05 |
Previous
Page 1 / 1
Next
Outgoing Citations (Sorted by Pagerank)
Showing 3 of 3 cited papers.
Citations counted here include only citations to other VLDB/SIGMOD/CIDR/PODS papers in this database.
| Rank | Cited Paper | Year | Venue | Pagerank |
|---|---|---|---|---|
| 552 | Orthogonal Optimization of Subqueries and Aggregation | 2001 | SIGMOD | 0.0001653835 |
| 896 | Froid: Optimization of Imperative Programs in a Relational Database | 2018 | VLDB | 0.00013209291 |
| 1,378 | Execution Strategies for SQL Subqueries | 2007 | SIGMOD | 0.00010864448 |
Previous
Page 1 / 1
Next
Semantically Similar Papers
| # | Overall Rank | Paper | Year | Venue |
|---|---|---|---|---|
| 1 | 3,642 | User-Defined Operators: Efficiently Integrating Custom Algorithms into Modern Databases | 2022 | VLDB |
| 2 | 3,988 | Exploiting Correlations for Expensive Predicate Evaluation | 2015 | SIGMOD |
| 3 | 5,719 | Accelerating Python UDFs in Vectorized Query Execution | 2022 | CIDR |
| 4 | 6,400 | Functional-Style SQL UDFs With a Capital 'F' | 2020 | SIGMOD |
| 5 | 11,168 | UDFBench: A Tool for Benchmarking UDF Queries on SQL Engines | 2025 | SIGMOD |
| 6 | 9,694 | The UDFBench Benchmark for General-purpose UDF Queries | 2025 | VLDB |
| 7 | 6,085 | Dear User-Defined Functions, Inlining isn't working out so great for us. Let's try batching to make our relationship work. Sincerely, SQL | 2024 | CIDR |
| 8 | 7,983 | Efficient Execution of User-Defined Functions in SQL Queries | 2023 | VLDB |
| 9 | 9,588 | The Key to Effective UDF Optimization: Before Inlining, First Perform Outlining | 2025 | VLDB |
| 10 | 896 | Froid: Optimization of Imperative Programs in a Relational Database | 2018 | VLDB |