Hi Matthias, Thank you very much for bringing this to our attention. Indeed, the current implementation doesn't work with SQL Server 2008, only with 2012 onwards. I have registered an issue to fix this: https://github.com/jOOQ/jOOQ/issues/5403
I guess in 2008, we'll have to use raiserror instead... Thanks again for reporting, Lukas 2016-07-11 12:38 GMT+02:00 matscheer via jOOQ User Group < [email protected]>: > Hello together, > > i've created a 'create table' statement with > DSLCONTEXT.createTableIfNotExists (SQLDialect is set to SQLSERVER2008). > > jOOQ generates the following sql: > > begin try create table > ... > end try begin catch if error_number() != 2714 throw; end catch > > The execution of the Sql throws an SQLException: > com.microsoft.sqlserver.jdbc.SQLServerException: Falsche Syntax in der > Nähe von 'throw'. > > Throw Statement is only supported up to SQL Server 2012... isnt it? > > Greetings > Matthias > > -- > 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/d/optout. > -- 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/d/optout.
