Add support for BigQuery ANY TYPE data type (#1602)

Co-authored-by: Martin Abelson Sahlen <sahlen@Martins-MacBook-Air.local>
Co-authored-by: Martin Abelson Sahlen <sahlen@Mac.lan>
This commit is contained in:
Martin Abelson Sahlen 2024-12-15 11:39:42 +02:00 committed by GitHub
parent 885aa93465
commit 7bc6ddb8fb
No known key found for this signature in database
GPG key ID: B5690EEEBB952194
3 changed files with 25 additions and 1 deletions

View file

@ -2212,3 +2212,19 @@ fn test_any_value() {
bigquery_and_generic().verified_expr("ANY_VALUE(fruit HAVING MAX sold)");
bigquery_and_generic().verified_expr("ANY_VALUE(fruit HAVING MIN sold)");
}
#[test]
fn test_any_type() {
bigquery().verified_stmt(concat!(
"CREATE OR REPLACE TEMPORARY FUNCTION ",
"my_function(param1 ANY TYPE) ",
"AS (",
"(SELECT 1)",
")",
));
}
#[test]
fn test_any_type_dont_break_custom_type() {
bigquery_and_generic().verified_stmt("CREATE TABLE foo (x ANY)");
}