Hey Mark,

please consider the value that `Dialect.supportsValuesList()` returns as irrelevant. It doesn't return the correct value for all databases as you figured. Apart from that, we are trying to get rid of such functions in Dialect and integrate this into the SqlAstTranslator as much as possible. I'll add the cleanup of this method to the JIRA issue: https://hibernate.atlassian.net/browse/HHH-14483

Regards,

Christian

Am 09.03.2021 um 14:13 schrieb Mark Rotteveel:
Looking at this again, I wonder if `Dialect.supportsValuesList()` would be the right check. A lot of dialects return false for this (except CockroachDB, DB2, PostgreSQL and SQL Server), but - I assume - they don't fail this test.

I guess those dialects support the values list in insert, but not elsewhere.

I will split the specific test into two tests, and explicitly ignore it for Firebird. I first considered adding a dialect feature check, but as supportsValuesList() doesn't seem to be the right thing to check, I guess it is better to only exclude known failing dialects.

Mark

On 07-03-2021 16:29, Mark Rotteveel wrote:
Testing against Firebird, it seems like Dialect.supportsValuesList() is ignored.

Specifically the test org.hibernate.orm.test.query.hql.InsertUpdateTests.testInsertValues generates the following statement even with Dialect.supportsValuesList() return false:

```
     insert
     into
         Ticket
         (id, ticket_key, subject, details)
     values
         (2, 'XYZ123', 'Outage', 'Something is broken'),  (
             13, 'HIJ456', 'x', 'x'
         )
```

Or is this a situation where this is ignored because the HQL explicitly contains two lists?


_______________________________________________
hibernate-dev mailing list -- hibernate-dev@lists.jboss.org
To unsubscribe send an email to hibernate-dev-le...@lists.jboss.org
%(web_page_url)slistinfo%(cgiext)s/%(_internal_name)s

Reply via email to