About Question enthuware.oce-jpad.v6.2.583 :

Moderator: admin

Post Reply
PtFyEH
Posts: 8
Joined: Sun Dec 20, 2015 6:28 pm
Contact:

About Question enthuware.oce-jpad.v6.2.583 :

Post by PtFyEH » Sun Jun 26, 2016 3:38 am

In the correct answer the third row of the citeriaquery is:

Code: Select all

cq.select(pRoot<Student>.get("presenter")).distinct(true);
This confuses me because i expect it to be

Code: Select all

cq.select(pRoot.<Student>get("presenter")).distinct(true);
It appears to be invalid Java syntax or am i missing something?

__JJ__
Posts: 125
Joined: Thu Jul 05, 2018 6:44 pm
Contact:

Re: About Question enthuware.oce-jpad.v6.2.583 :

Post by __JJ__ » Mon Sep 17, 2018 2:34 pm

PtFyEH wrote:
Sun Jun 26, 2016 3:38 am
In the correct answer the third row of the citeriaquery is:

Code: Select all

cq.select(pRoot<Student>.get("presenter")).distinct(true);
This confuses me because i expect it to be

Code: Select all

cq.select(pRoot.<Student>get("presenter")).distinct(true);
It appears to be invalid Java syntax or am i missing something?
I was just thinking that myself. It looks like a type witness, and type witnesses go after the dot, not before.

Online
admin
Site Admin
Posts: 8243
Joined: Fri Sep 10, 2010 9:26 pm
Contact:

Re: About Question enthuware.oce-jpad.v6.2.583 :

Post by admin » Wed Sep 19, 2018 9:25 pm

You are right. Fixed.
thank you for your feedback!
If you like our products and services, please help us by posting your review here.

Post Reply

Who is online

Users browsing this forum: No registered users and 3 guests