I am using HSQLDB and am trying to run a select statement which contains NOLOCK
in the query.
When the statements are exeuted, a BadSqlGrammarException
is thrown.
Is there a way to get around this issue as the command runs perfectly well with SQL Server?
a_horse_with_no_name is correct with his comment:
To clarify this,
NOLOCK
is a SQL Server specific keyword specifying a hint to the database how to behave. It even has its own tag nolock here on Stack Overflow:Thus, SQL queries including this keyword are not valid for HyperSQL.
What you can do is:
NOLOCK
. How this would affect your application is impossible to say without more knowledge about it.As a side note, HyperSQL fully supports the SQL specification: