Save Time Writing SQL with UDFs

An introduction to SQL UDFs with examples

Jye Sawtell-Rickson
Towards Data Science
4 min readOct 7, 2022

--

Writing SQL is an important part of many data scientists’ and data analysts’ roles, but it’s often the least enjoyable way to spend time. It can become tedious and time consuming to get the data you need in order to run analyses. User-defined functions (UDFs) are a great way to solve this problem by acting as a shortcut to the query-writing process. In this article we’ll go through what UDFs are, why you might use them, where they’re supported, and some basic examples.

--

--