schizophrenicmaniac commented on PR #40212:
URL: https://github.com/apache/shardingsphere/pull/40212#issuecomment-6343556151

   @terrymanu Thanks, I pushed a commit for all three.
   
   1. Column types now only come from columns the binder marks as physical 
table columns, so a column from a subquery or CTE, like the `CASE WHEN true 
THEN id ELSE k END AS x` case, no longer resolves anything. An IN list is only 
used when every value in it is a parameter or a plain literal, so `id IN ($1, 
1::oid)` keeps `$1` as text and PostgreSQL picks the common type the same way 
it does on master. Literals are still allowed because none of their types read 
decimal integer text differently, and `id IN (?, 1)` still decodes `010` to 10. 
There are tests for the IN cast, the IN literal and the derived column cases.
   
   2. `putInsertValueColumnTypes` and the local that passes the insert column 
names to it now use `Collection`. `resolveInsertParameterTypes` keeps `List` 
because Describe reads by position.
   
   3. The schema, table name and column name helpers now come right after 
`putInsertValuesColumnTypes` in call order, and the other new helpers follow 
their first caller too. In the test, `createBoundPreparedStatement`, 
`createInsertPreparedStatement` and `prepareInsertTableMetaData` now sit after 
the first test that uses them.


-- 
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