Skip to content

Error parsing generated ALTER COLUMN query #122

@larkee

Description

@larkee

The generated query when calling alter_column is using the PostGres syntax:

ALTER TABLE table_id ALTER COLUMN column_id DROP NOT NULL

However, the Spanner way of doing this would be:

ALTER TABLE table_id ALTER COLUMN column_id column_type [null_constraint]

e.g. to remove NOT NULL

ALTER TABLE Venue ALTER COLUMN LastUpdateTime TIMESTAMP

e.g. to add NOT NULL

ALTER TABLE Venue ALTER COLUMN LastUpdateTime TIMESTAMP NOT NULL

See #118 (comment) for original example and error.

Metadata

Metadata

Assignees

Labels

api: spannerIssues related to the googleapis/python-spanner-sqlalchemy API.priority: p2Moderately-important priority. Fix may not be included in next release.type: bugError or flaw in code with unintended results or allowing sub-optimal usage patterns.

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions