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

CaseBuilder() is throwing error #1303

Closed
pradeep-tal opened this issue Apr 5, 2015 · 5 comments
Closed

CaseBuilder() is throwing error #1303

pradeep-tal opened this issue Apr 5, 2015 · 5 comments
Milestone

Comments

@pradeep-tal
Copy link

@pradeep-tal pradeep-tal commented Apr 5, 2015

I am trying to create Case Expression

NumberExpression<Float> numExpression = (summary.field1.floatValue().divide(summary.field2.floatValue()).multiply(100));        
NumberExpression<Float> numberExpression2 = summary.impressions.when(0L).then(0.0F).otherwise(numExpression);

So the formed SQL Query will contain :

when summary.impression=0 then 0.0
else cast summay.field as flaot/ cast summary.field2 as float) * 100 end

it throwing error at * ...unexpected token end i guess not allowing any operators we can expect same error for / also

@timowest timowest changed the title CaseBuilder() is throwing error . CaseBuilder() is throwing error Apr 5, 2015
@timowest
Copy link
Member

@timowest timowest commented Apr 5, 2015

Do you use Querydsl JPA or Querydsl SQL and which version? Which underlying SQL database do you use?

@pradeep-tal
Copy link
Author

@pradeep-tal pradeep-tal commented Apr 5, 2015

I am using Query DSL JPA version 3.6.2
Data base i am using is Mysql

@pradeep-tal
Copy link
Author

@pradeep-tal pradeep-tal commented Apr 8, 2015

How can merge this changes into version 3.6.2 which i am using currently.
does this changes available in 3.6.3 version .

@timowest
Copy link
Member

@timowest timowest commented Apr 8, 2015

Once it is merged, you can use the latest snapshot from here oss.sonatype.org/content/repositories/snapshots

@pradeep-tal
Copy link
Author

@pradeep-tal pradeep-tal commented Apr 13, 2015

when this fix will be available and when it will be merged

@timowest timowest removed the progress label May 9, 2015
@timowest timowest added this to the 4.0.0 milestone May 9, 2015
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Linked pull requests

Successfully merging a pull request may close this issue.

2 participants
You can’t perform that action at this time.