Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Support literals in Panache projection #34140

Open
sjaakd opened this issue Jun 19, 2023 · 1 comment
Open

Support literals in Panache projection #34140

sjaakd opened this issue Jun 19, 2023 · 1 comment
Labels
area/panache kind/enhancement New feature or request

Comments

@sjaakd
Copy link

sjaakd commented Jun 19, 2023

Description

In HQL it is possible to use constants (like below) for DTO projection. This i however not possible (yet) in Panache.

@Entity
@Table(schema = "DINO_DBA", name = "GDW_LKS_SFR_RD")
@NamedQuery(
    name = "GdwLksSfrRd.search",
    query = "select new nl.bro.microservices.dlp.model.common.ObjectDto( p.broId, p.geometry, 'SOIL', 'BRO', 'sfr' ) "
        + "from GdwLksSfrRd p where p.broId like :criterion order by p.broId"
)

See also #33310

Implementation ideas

A suggestion that has been made in #33310 is to support static factory methods. That looks like an interesting way forward.

@sjaakd sjaakd added the kind/enhancement New feature or request label Jun 19, 2023
@quarkus-bot
Copy link

quarkus-bot bot commented Jun 19, 2023

/cc @FroMage (panache), @loicmathieu (panache)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
area/panache kind/enhancement New feature or request
Projects
None yet
Development

No branches or pull requests

1 participant