geyanggang commented on PR #14665:
URL: https://github.com/apache/gravitino/pull/14665#issuecomment-6658197505

   Good catch, thanks @yuqi1129. You're right: a collation is a schema object, 
and the unqualified `COLLATE "name"` both failed when the collation's schema 
was off the search path and could silently rebind to a same-named collation in 
the table's schema.
   
   Fixed: `explicitColumnCollation()` now selects `collation_schema` and 
`collation_name` and emits `COLLATE "schema"."name"` with each identifier 
quoted separately. Added two regression tests that reproduce your cases (a 
collation in another schema, and a same-name clash) and assert the collation 
identity (schema + name) is preserved. The full `TestPostgreSqlTableOperations` 
suite passes on the PostgreSQL 13 Docker tests; I also confirmed both new tests 
fail against the previous name-only logic.
   


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]

Reply via email to