Closed apstndb closed 2 days ago
This incompatibility is detected by #90.
https://cloud.google.com/spanner/docs/reference/standard-sql/data-definition-language#model_statements
{ CREATE MODEL | CREATE OR REPLACE MODEL | CREATE MODEL IF NOT EXISTS } model_name [INPUT ( column_list ) OUTPUT ( column_list )] REMOTE [OPTIONS ( model_options )] where column_list is: { column_name data_type [OPTIONS ( model_column_options )] [, ... ] } and model_column_options is: { required = { true | false } } and model_options is: { endpoint = '{endpoint_address}', endpoints = [ '{endpoint_address}' [, ...] ], default_batch_size = int64_value }
https://cloud.google.com/spanner/docs/reference/standard-sql/data-definition-language#alter-model
ALTER MODEL [ IF EXISTS ] model_name SET OPTIONS ( model_options ) where model_options is: { endpoint = '{endpoint_address}', endpoints = [ '{endpoint_address}' [, ...] ], default_batch_size = int64_value }
https://cloud.google.com/spanner/docs/reference/standard-sql/data-definition-language#drop-model
DROP MODEL [ IF EXISTS ] model_name
CREATE MODEL m1 INPUT( feature INT64 ) OUTPUT( label STRING(MAX) ) REMOTE OPTIONS ( endpoint = '//aiplatform.googleapis.com/projects/tp/locations/tl/endpoints/schemaless' );
syntax error:testdata/models.test:4:8: expected pseudo keyword: DATABASE, TABLE, INDEX, UNIQUE, NULL_FILTERED, ROLE, CHANGE but: MODEL 4: CREATE MODEL m1 ^~~~~
https://cloud.google.com/spanner/docs/release-notes#October_11_2022
This incompatibility is detected by #90.
Spec
https://cloud.google.com/spanner/docs/reference/standard-sql/data-definition-language#model_statements
https://cloud.google.com/spanner/docs/reference/standard-sql/data-definition-language#alter-model
https://cloud.google.com/spanner/docs/reference/standard-sql/data-definition-language#drop-model
Reproducing input
Current error
Related update of this syntax
https://cloud.google.com/spanner/docs/release-notes#October_11_2022