Page 1 of 1

SDAC - No Locking because of granularity

Posted: Fri 09 Jun 2017 05:37
by Alex Schickel
When I try to lock a record (LockMode = Pessimistic) I get the Error message
---------------------------------------------------
Exception Class EMSError "the Row-Granularity hint for the table can't be used because lock are not allowed with the mentioned granularity..."

(It's roughly translated from the german message)

How can I avoid this error?

brgds. alex.

Re: SDAC - No Locking because of granularity

Posted: Mon 12 Jun 2017 06:26
by Alex Schickel
Changing my Database from my beloved Advantage Database Server to MS SQL-Server I was not aware that when EMS SQL Manager creates an index it uses the parameters:
......
ALLOW_ROW_LOCKS = OFF,
ALLOW_PAGE_LOCKS = OFF
.....
as a default. You have to allow the locking otherwise you get the granularity error.

brgds. alex.

Re: SDAC - No Locking because of granularity

Posted: Mon 12 Jun 2017 09:47
by azyk
Glad to see you have found the reason of the problem. If any other questions come up, please contact us.