-
Notifications
You must be signed in to change notification settings - Fork 3.8k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
sql: add UDFs to sqlsmith #90782
Labels
A-sql-routine
UDFs and Stored Procedures
branch-release-23.1
Used to mark GA and release blockers, technical advisories, and bugs for 23.1
C-enhancement
Solution expected to add code/behavior + preserve backward-compat (pg compat issues are exception)
GA-blocker
T-sql-queries
SQL Queries Team
Comments
mgartner
added
the
C-enhancement
Solution expected to add code/behavior + preserve backward-compat (pg compat issues are exception)
label
Oct 27, 2022
exalate-issue-sync
bot
added
T-sql-queries
SQL Queries Team
and removed
T-sql-queries
SQL Queries Team
labels
Oct 27, 2022
Hi @mgartner, please add branch-* labels to identify which branch(es) this release-blocker affects. 🦉 Hoot! I am a Blathers, a bot for CockroachDB. My owner is dev-inf. |
mgartner
added
the
branch-release-23.1
Used to mark GA and release blockers, technical advisories, and bugs for 23.1
label
Mar 16, 2023
rharding6373
added a commit
to rharding6373/cockroach
that referenced
this issue
Apr 11, 2023
This PR gives sqlsmith the capability to issue `CREATE FUNCTION` commands. It randomly chooses from available and valid function options. It also contains up to 10 `SELECT` statements in the UDF body. This PR also leaves several TODOs, including support for params, return types other than records, and calling UDFs in queries after they are created. Epic: CRDB-20370 Informs: cockroachdb#90782 Release note: None
rharding6373
added a commit
to rharding6373/cockroach
that referenced
this issue
Apr 11, 2023
This PR gives sqlsmith the capability to issue `CREATE FUNCTION` commands. It randomly chooses from available and valid function options. It also contains up to 10 `SELECT` statements in the UDF body. This PR also leaves several TODOs, including support for params, return types other than records, and calling UDFs in queries after they are created. Epic: CRDB-20370 Informs: cockroachdb#90782 Release note: None
craig bot
pushed a commit
that referenced
this issue
Apr 11, 2023
100868: jobs: wrap payload vs progress err differently r=adityamaru a=dt Release note: none. Epic: none 101159: copy: fix copyfrom roachtest session var settings r=cucaroach a=cucaroach Need to use a separate user as root user cannot have session vars set via ALTER ROLE. Epic: None Fixes: #101158 Release note: None 101205: sqlsmith: add support for creating udfs r=rharding6373 a=rharding6373 This PR gives sqlsmith the capability to issue `CREATE FUNCTION` commands. It randomly chooses from available and valid function options. It also contains up to 10 `SELECT` statements in the UDF body. This PR also leaves several TODOs, including support for params, return types other than records, and calling UDFs in queries after they are created. Epic: CRDB-20370 Informs: #90782 Release note: None 101251: kv: mark admission epoch lifo verb as safe string r=irfansharif a=nvanbenschoten Avoids log garbage like this: ``` I230411 02:07:26.905045 79 util/admission/work_queue.go:489 â<8b>® [n59] 1861224 â<80>¹sql-kv-responseâ<80>º: FIFO threshold for tenant 1 â<80>¹isâ<80>º -128 ``` Epic: None Release note: None Co-authored-by: David Taylor <[email protected]> Co-authored-by: Tommy Reilly <[email protected]> Co-authored-by: rharding6373 <[email protected]> Co-authored-by: Nathan VanBenschoten <[email protected]>
rharding6373
added a commit
to rharding6373/cockroach
that referenced
this issue
Apr 11, 2023
This PR adds up to 9 parameters of any type. It also adds return types besides records and ensures that the last statement in the UDF body returns that type. It also disables CTEs while generating the statements for the UDF body, since CTEs are not currently supported. Epic: CRDB-20370 Informs: cockroachdb#90782 Release note: None
rharding6373
added a commit
to rharding6373/cockroach
that referenced
this issue
Apr 12, 2023
This PR adds up to 9 parameters of any type. It also adds return types besides records and ensures that the last statement in the UDF body returns that type. It also disables CTEs while generating the statements for the UDF body, since CTEs are not currently supported. Epic: CRDB-20370 Informs: cockroachdb#90782 Release note: None
craig bot
pushed a commit
that referenced
this issue
Apr 12, 2023
101266: sqlsmith: add params and return types to udfs r=rharding6373 a=rharding6373 This PR adds up to 9 parameters of any type. It also adds return types besides records and ensures that the last statement in the UDF body returns that type. It also disables CTEs while generating the statements for the UDF body, since CTEs are not currently supported. Epic: CRDB-20370 Informs: #90782 Release note: None 101303: multitenant: display the dropping state as "dropping" not "drop" r=ecwall a=knz Requested by `@ecwall` [here](#100613 (review)). Needed for #100613. This specific data state for secondary tenants indicate that the tenant keyspace is queued for asynchronous deletion by a GC jobs; however, it may not have been deleted yet. Therefore, the visual representation of that state is best named "dropping" instead of "drop". Release note: None Epic: CRDB-23559 Co-authored-by: rharding6373 <[email protected]> Co-authored-by: Raphael 'kena' Poss <[email protected]>
rharding6373
added a commit
to rharding6373/cockroach
that referenced
this issue
Apr 13, 2023
This PR adds UDFs created by sqlsmith to the list of available functions that can then be called in other queries generated by sqlsmith. Epic: CRDB-20370 Informs: cockroachdb#90782 Release note: None
rharding6373
added a commit
to rharding6373/cockroach
that referenced
this issue
Apr 13, 2023
Randomly generated UDFs may now reference their parameters inside the UDF body statements. Epic: CRDB-20370 Fixes: cockroachdb#90782 Release note: None
craig bot
pushed a commit
that referenced
this issue
Apr 14, 2023
101402: sqlsmith: call udfs in sqlsmith queries r=rharding6373 a=rharding6373 This PR adds UDFs created by sqlsmith to the list of available functions that can then be called in other queries generated by sqlsmith. Epic: CRDB-20370 Informs: #90782 Release note: None Co-authored-by: rharding6373 <[email protected]>
craig bot
pushed a commit
that referenced
this issue
Apr 14, 2023
101510: sqlsmith: allow udf params to be referenced inside udfs r=rharding6373 a=rharding6373 Randomly generated UDFs may now reference their parameters inside the UDF body statements. Epic: CRDB-20370 Fixes: #90782 Release note: None Co-authored-by: rharding6373 <[email protected]>
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Labels
A-sql-routine
UDFs and Stored Procedures
branch-release-23.1
Used to mark GA and release blockers, technical advisories, and bugs for 23.1
C-enhancement
Solution expected to add code/behavior + preserve backward-compat (pg compat issues are exception)
GA-blocker
T-sql-queries
SQL Queries Team
We should create and execute UDFs in randomized tests like sqlsmith.
Epic: CRDB-20370
Jira issue: CRDB-20941
The text was updated successfully, but these errors were encountered: