Search code examples
sqlsybasesqlanywhere

How to hide data of uncommitted transactions from other connections?


I am inserting data into multiple tables and expected all data to be invisible to others until I committed them. But in fact some other application is starting to pick up the data before I am done. I verified this by using a delay between inserts and saw the data immediately.

I read about isolation levels, but it looks like i.e. SET TEMPORARY OPTION isolation_level = 3; has no effect when set only on my side.

Is this a difference between Sybase and other databases, or are there just wrong settings somewhere?

I'm using Sybase SQL Anywhere 11+16.


Solution

  • Here is the proper page for isolation levels in SQL Anywhere 11.0.

    I think you should use SET OPTION isolation_level=1; on the user accessing your table (or the group PUBLIC).