Category "user-defined-functions"

Spark scala data frame udf returning rows

Say I have an dataframe which contains a column (called colA) which is a seq of row. I want to to append a new field to each record of colA. (And the new filed

Excel UDF to Unpivot (Melt, Reverse pivot, Flatten, Normalize) blocks of data within Tables

This question will seek multiple approaches LET/LAMBDA VBA UDF and Power Query Function, so there will be no single right answer, but a solicitation of approach

How to avoid multiple function evals with the (func()).* syntax in a query?

Context When a function returns a TABLE or a SETOF composite-type, like this one: CREATE FUNCTION func(n int) returns table(i int, j bigint) as $$ BEGIN RETUR

Distribute group tasks evenly using pandas_udf in PySpark

I have a Spark Dataframe which contains groups of training data. Each group is identified by the "group" column. group | feature_1 | feature_2 | label --------

How do I create a SQL Function to return a BIT?

I am using this script below to create a function but I get an error in the messages log: CREATE FUNCTION [dbo].[MyFunction] () RETURNS BIT AS RETURN CAST(1 AS