Hello,
I have simple HQL query
Code:
DELETE FROM DocDefParamValueFlat dcp
WHERE dcp.docDefParam.idDocDefParam = 16
AND dcp.orgCompanyGroup.idOrgCompanyGroup = 2
which generates correct SQL
Code:
delete
from
next."DOC_DEF_PARAM_VALUE_FLAT"
where
"ID_DOC_DEF_PARAM"=16
and "ID_ORG_COMPANY_GROUP"=2
Now problem when I put bracket ")" by mistake
Code:
DELETE FROM DocDefParamValueFlat dcp
WHERE dcp.docDefParam.idDocDefParam = 16 ) <-------------- HERE
AND dcp.orgCompanyGroup.idOrgCompanyGroup = 2
hibernate generates SQL like that
Code:
delete
from
next."DOC_DEF_PARAM_VALUE_FLAT"
where
"ID_DOC_DEF_PARAM"=16
He cuts everything after ")"
How to resolve this problem
Best regards
Mirek