From de2f52833e1e4cc09a9dba162b6703877efe1759 Mon Sep 17 00:00:00 2001 From: Andrew Lamb Date: Thu, 3 Oct 2024 12:59:21 -0400 Subject: [PATCH] Improve description of function migration --- dev/update_function_docs.sh | 24 +++++++++++++++---- .../user-guide/sql/aggregate_functions.md | 6 +++++ .../user-guide/sql/aggregate_functions_new.md | 6 ++++- .../source/user-guide/sql/scalar_functions.md | 8 +++++++ .../user-guide/sql/scalar_functions_new.md | 6 ++++- .../source/user-guide/sql/window_functions.md | 10 +++++++- .../user-guide/sql/window_functions_new.md | 11 +++++++-- 7 files changed, 62 insertions(+), 9 deletions(-) diff --git a/dev/update_function_docs.sh b/dev/update_function_docs.sh index a4236eefc8c8..f1f26c8b2f58 100755 --- a/dev/update_function_docs.sh +++ b/dev/update_function_docs.sh @@ -58,7 +58,11 @@ dev/update_function_docs.sh file for updating surrounding text. # Aggregate Functions (NEW) -This page is a WIP and will replace the Aggregate Functions page once completed. +Note: this documentation is in the process of being migrated to be [automatically created from the codebase]. +Please see the [Aggregate Functions (old)](aggregate_functions.md) page for +the rest of the documentation. + +[automatically created from the codebase]: https://github.com/apache/datafusion/issues/12740 Aggregate functions operate on a set of values to compute a single result. EOF @@ -105,7 +109,12 @@ dev/update_function_docs.sh file for updating surrounding text. # Scalar Functions (NEW) -This page is a WIP and will replace the Scalar Functions page once completed. +Note: this documentation is in the process of being migrated to be [automatically created from the codebase]. +Please see the [Scalar Functions (old)](aggregate_functions.md) page for +the rest of the documentation. + +[automatically created from the codebase]: https://github.com/apache/datafusion/issues/12740 + EOF echo "Running CLI and inserting scalar function docs table" @@ -151,9 +160,16 @@ dev/update_function_docs.sh file for updating surrounding text. # Window Functions (NEW) -This page is a WIP and will replace the Window Functions page once completed. +Note: this documentation is in the process of being migrated to be [automatically created from the codebase]. +Please see the [Window Functions (Old)](window_functions.md) page for +the rest of the documentation. + +[automatically created from the codebase]: https://github.com/apache/datafusion/issues/12740 -A _window function_ performs a calculation across a set of table rows that are somehow related to the current row. This is comparable to the type of calculation that can be done with an aggregate function. However, window functions do not cause rows to become grouped into a single output row like non-window aggregate calls would. Instead, the rows retain their separate identities. Behind the scenes, the window function is able to access more than just the current row of the query result +A _window function_ performs a calculation across a set of table rows that are somehow related to the current row. +This is comparable to the type of calculation that can be done with an aggregate function. +However, window functions do not cause rows to become grouped into a single output row like non-window aggregate calls would. +Instead, the rows retain their separate identities. Behind the scenes, the window function is able to access more than just the current row of the query result Here is an example that shows how to compare each employee's salary with the average salary in his or her department: diff --git a/docs/source/user-guide/sql/aggregate_functions.md b/docs/source/user-guide/sql/aggregate_functions.md index edb0e1d0c9f0..4e0b8e51e783 100644 --- a/docs/source/user-guide/sql/aggregate_functions.md +++ b/docs/source/user-guide/sql/aggregate_functions.md @@ -21,6 +21,12 @@ Aggregate functions operate on a set of values to compute a single result. +Note: this documentation is in the process of being migrated to be [automatically created from the codebase]. +Please see the [Aggregate Functions (new)](aggregate_functions_new.md) page for +the rest of the documentation. + +[automatically created from the codebase]: https://github.com/apache/datafusion/issues/12740 + ## General - [avg](#avg) diff --git a/docs/source/user-guide/sql/aggregate_functions_new.md b/docs/source/user-guide/sql/aggregate_functions_new.md index 8303c50c2471..34f83c9d7836 100644 --- a/docs/source/user-guide/sql/aggregate_functions_new.md +++ b/docs/source/user-guide/sql/aggregate_functions_new.md @@ -27,7 +27,11 @@ dev/update_function_docs.sh file for updating surrounding text. # Aggregate Functions (NEW) -This page is a WIP and will replace the Aggregate Functions page once completed. +Note: this documentation is in the process of being migrated to be [automatically created from the codebase]. +Please see the [Aggregate Functions (old)](aggregate_functions.md) page for +the rest of the documentation. + +[automatically created from the codebase]: https://github.com/apache/datafusion/issues/12740 Aggregate functions operate on a set of values to compute a single result. diff --git a/docs/source/user-guide/sql/scalar_functions.md b/docs/source/user-guide/sql/scalar_functions.md index 469fb705b71f..646b0fd41d89 100644 --- a/docs/source/user-guide/sql/scalar_functions.md +++ b/docs/source/user-guide/sql/scalar_functions.md @@ -19,6 +19,14 @@ # Scalar Functions +Scalar functions operate on a single row at a time and return a single value. + +Note: this documentation is in the process of being migrated to be [automatically created from the codebase]. +Please see the [Scalar Functions (new)](scalar_functions_new.md) page for +the rest of the documentation. + +[automatically created from the codebase]: https://github.com/apache/datafusion/issues/12740 + ## Math Functions - [abs](#abs) diff --git a/docs/source/user-guide/sql/scalar_functions_new.md b/docs/source/user-guide/sql/scalar_functions_new.md index ae2744c1650e..9f1205cc9b82 100644 --- a/docs/source/user-guide/sql/scalar_functions_new.md +++ b/docs/source/user-guide/sql/scalar_functions_new.md @@ -27,7 +27,11 @@ dev/update_function_docs.sh file for updating surrounding text. # Scalar Functions (NEW) -This page is a WIP and will replace the Scalar Functions page once completed. +Note: this documentation is in the process of being migrated to be [automatically created from the codebase]. +Please see the [Scalar Functions (old)](aggregate_functions.md) page for +the rest of the documentation. + +[automatically created from the codebase]: https://github.com/apache/datafusion/issues/12740 ## Math Functions diff --git a/docs/source/user-guide/sql/window_functions.md b/docs/source/user-guide/sql/window_functions.md index 4d9d2557249f..53da219d42f5 100644 --- a/docs/source/user-guide/sql/window_functions.md +++ b/docs/source/user-guide/sql/window_functions.md @@ -19,7 +19,15 @@ # Window Functions -A _window function_ performs a calculation across a set of table rows that are somehow related to the current row. This is comparable to the type of calculation that can be done with an aggregate function. However, window functions do not cause rows to become grouped into a single output row like non-window aggregate calls would. Instead, the rows retain their separate identities. Behind the scenes, the window function is able to access more than just the current row of the query result +A _window function_ performs a calculation across a set of table rows that are somehow related to the current row. + +Note: this documentation is in the process of being migrated to be [automatically created from the codebase]. +Please see the [Window Functions (new)](window_functions_new.md) page for +the rest of the documentation. + +[automatically created from the codebase]: https://github.com/apache/datafusion/issues/12740 + +Window functions are comparable to the type of calculation that can be done with an aggregate function. However, window functions do not cause rows to become grouped into a single output row like non-window aggregate calls would. Instead, the rows retain their separate identities. Behind the scenes, the window function is able to access more than just the current row of the query result Here is an example that shows how to compare each employee's salary with the average salary in his or her department: diff --git a/docs/source/user-guide/sql/window_functions_new.md b/docs/source/user-guide/sql/window_functions_new.md index 1ab6740a6f87..ee981911f5cb 100644 --- a/docs/source/user-guide/sql/window_functions_new.md +++ b/docs/source/user-guide/sql/window_functions_new.md @@ -27,9 +27,16 @@ dev/update_function_docs.sh file for updating surrounding text. # Window Functions (NEW) -This page is a WIP and will replace the Window Functions page once completed. +Note: this documentation is in the process of being migrated to be [automatically created from the codebase]. +Please see the [Window Functions (Old)](window_functions.md) page for +the rest of the documentation. -A _window function_ performs a calculation across a set of table rows that are somehow related to the current row. This is comparable to the type of calculation that can be done with an aggregate function. However, window functions do not cause rows to become grouped into a single output row like non-window aggregate calls would. Instead, the rows retain their separate identities. Behind the scenes, the window function is able to access more than just the current row of the query result +[automatically created from the codebase]: https://github.com/apache/datafusion/issues/12740 + +A _window function_ performs a calculation across a set of table rows that are somehow related to the current row. +This is comparable to the type of calculation that can be done with an aggregate function. +However, window functions do not cause rows to become grouped into a single output row like non-window aggregate calls would. +Instead, the rows retain their separate identities. Behind the scenes, the window function is able to access more than just the current row of the query result Here is an example that shows how to compare each employee's salary with the average salary in his or her department: