Yes Lukas,
rewriting the SQL procedures into JOOQ is my POC.
As its a complex procedure I wrote in a different way
1) All fetching logic in JOOQ. ( select abc from employee ; -- here goes
all the complex logic which is written in JOOQ).
2) the update logic in SQL as show in below
String updateQuery = "update employee" +
" set computed_value = "+ abc;
int status = connection.createStatement().executeUpdate(updateQuery);
System.out.println(" status : " + status);
Unfortunately in first part , it fails at ctx.decode().when( .....);
My code is as below
DSLContext ctx = DSL.using(connection, SQLDialect.SQLSERVER2008);
Result<Record1<BigDecimal>> rec = ctx.select(
((DSL)ctx).decode().when(...) ).from(uoijt);
Error is -- Exception in thread "main" java.lang.ClassCastException:
org.jooq.impl.DefaultDSLContext cannot be cast to org.jooq.impl.DSL
Even when i change ctx.decode() // It wont find decode() method.
And it does not even work for ((DefaultDSLContext)ctx).decode();//// It
wont find decode() method
How to resolve this.
where have i gone wrong ?
~Shyam
--
You received this message because you are subscribed to the Google Groups "jOOQ
User Group" group.
To unsubscribe from this group and stop receiving emails from it, send an email
to [email protected].
For more options, visit https://groups.google.com/groups/opt_out.