Skip to content
This repository has been archived by the owner on Jan 17, 2025. It is now read-only.

Error: pq: syntax error at or near "-" when deleting redshift DB #124

Open
fraserc182 opened this issue Jul 7, 2023 · 2 comments · May be fixed by #125
Open

Error: pq: syntax error at or near "-" when deleting redshift DB #124

fraserc182 opened this issue Jul 7, 2023 · 2 comments · May be fixed by #125

Comments

@fraserc182
Copy link

fraserc182 commented Jul 7, 2023

I've been trying to destroy a redshift DB and getting this error, not too sure if this is a bug or if we're running into something else here.
The only way we can get round it is to either delete it manually.

Terraform will perform the following actions:

  # redshift_database.db will be destroyed
  - resource "redshift_database" "db" {
      - connection_limit = -1 -> null
      - id               = "27376203" -> null
      - name             = "database-prd" -> null
      - owner            = (sensitive) -> null
    }

Plan: 0 to add, 0 to change, 1 to destroy.
redshift_database.db: Destroying... [id=27376203]
╷
│ Error: pq: syntax error at or near "-"
│ 
│ 
╵
Problem applying destroying terraform environment
@mtesch-um mtesch-um linked a pull request Jul 7, 2023 that will close this issue
@mtesch-um
Copy link
Contributor

mtesch-um commented Jul 7, 2023

@fraserc182 as a workaround until the fix gets merged you can should be able to manually run DROP DATABASE "database-prd";

@fraserc182
Copy link
Author

@mtesch-um yup can do. Thanks for working on this.

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants