From b8cad842e1fd01d26b32cafc6dad4abfb066621a Mon Sep 17 00:00:00 2001 From: "Andrey.Tarashevskiy" Date: Sun, 17 Jan 2021 01:57:11 +0300 Subject: [PATCH] Updated FAQ (markdown) --- FAQ.md | 21 --------------------- 1 file changed, 21 deletions(-) diff --git a/FAQ.md b/FAQ.md index 4d011ff..8855a09 100644 --- a/FAQ.md +++ b/FAQ.md @@ -65,27 +65,6 @@ A: Yes, it's possible since Exposed 0.11.1 version A: See example here: https://github.com/JetBrains/Exposed/issues/248 -### Q: SQLite3 fails with the error Transaction attempt #0 failed: SQLite supports only TRANSACTION_SERIALIZABLE and TRANSACTION_READ_UNCOMMITTED. - -A1: Update to Exposed 0.24.1 or later -A2: Make your connect code look like below (taken from [ThreadLocalManagerTest.kt](https://github.com/JetBrains/Exposed/blob/4360ae18c708072dfda261742e65b8b56a696adc/src/test/kotlin/org/jetbrains/exposed/sql/tests/shared/ThreadLocalManagerTest.kt#L282-L291)). The setting below tells SQLite3 to enforce transactional integrity by [serializing writes from different connections](https://sqlite.org/isolation.html). -```kotlin -// Your connection properties here -Database.connect("jdbc:sqlite:my.db", "org.sqlite.JDBC") -TransactionManager.manager.defaultIsolationLevel = Connection.TRANSACTION_SERIALIZABLE // Or Connection.TRANSACTION_READ_UNCOMMITTED -``` - -### Q: Oracle fails with the error Transaction attempt #0 failed: `READ_COMMITTED and SERIALIZABLE are the only valid transaction levels` - -A1: Update to Exposed 0.24.1 or later -A2: Make your connect code look like below (taken from [ThreadLocalManagerTest.kt](https://github.com/JetBrains/Exposed/blob/4360ae18c708072dfda261742e65b8b56a696adc/src/test/kotlin/org/jetbrains/exposed/sql/tests/shared/ThreadLocalManagerTest.kt#L282-L291)). -```kotlin -// Your connection properties here -Database.connect("jdbc:jdbc:oracle:thin:@//localhost:1521/test", "oracle.jdbc.OracleDriver") -TransactionManager.manager.defaultIsolationLevel = Connection.TRANSACTION_SERIALIZABLE // Or Connection.TRANSACTION_READ_COMMITTED -``` - - ### Q: How can I use SAVEPOINT? A: It possible only through using a raw connection. See example [here](https://github.com/JetBrains/Exposed/issues/320#issuecomment-394825415).