yesodweb / persistent

Persistence interface for Haskell allowing multiple storage methods.
MIT License
467 stars 297 forks source link

Second pass at Postgres - fixes some migration bugs #1556

Closed curranosaurus closed 1 month ago

curranosaurus commented 1 month ago

I realized that if you run the test suite twice, it starts to break due to repeated CREATe TABLE ... commands.

The root cause is because we were escaping the schema name in places where we shouldn't escape it. Escaping the name is proper when you are using it as a SQL relation name, but when you are trying to pass the value around as a string it needs to remain unescaped.