Trino (Presto) queries as named queries

31 views
Skip to first unread message

Sergio Pérez Felipe

unread,
Nov 22, 2022, 8:55:55 AM11/22/22
to Querydsl
I'm using QueryDSL to create queries for Trino.
This example generates a query as a named query, and I don't want it

```

SQLQuery sqlQuery = new SQLQuery(new Configuration(H2Templates.builder().build())); 

PathBuilder<SessionList> pathBuilder = new PathBuilder(SessionList.class, "session_list");

Predicate predicate = pathBuilder.get("city", String.class).eq("Madrid");

sqlQuery.where(predicate);

```

sqlQuery.toString create next string:

from dual where session_list.city = ?

But I need it to generate:

from dual where session_list.city = 'Madrid'

Any idea?


Confidentiality Notice: This email and any files transmitted with it are confidential and intended solely for the use of the individual or entity to whom they are addressed.  Additionally, this email and any files transmitted with it may not be disseminated, distributed or copied. Please notify the sender immediately by email if you have received this email by mistake and delete this email from your system. If you are not the intended recipient, you are notified that disclosing, copying, distributing or taking any action in reliance on the contents of this information is strictly prohibited.

https://exp-now.medallia.com/
 ​​ 
Reply all
Reply to author
Forward
0 new messages