Skip to content

Commit fa731f5

Browse files
committed
readme update
mysql transaction now work
1 parent 3a239fc commit fa731f5

File tree

2 files changed

+6
-9
lines changed

2 files changed

+6
-9
lines changed

README.md

Lines changed: 4 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -104,8 +104,6 @@ Creates a prepared statement and lets you fill the `?` with values.
104104

105105
Takes several statements and wraps them into a single transaction for the server to process. Use `statement : [...actions...]` to create such a transaction. Only `select`, `insert` and `raw` commands are allowed right now.
106106

107-
Be aware: This is only tested and working with PostgreSQL currently.
108-
109107
{
110108
"action" : "transaction",
111109
"statements" : [
@@ -117,12 +115,12 @@ Be aware: This is only tested and working with PostgreSQL currently.
117115
},
118116
{
119117
"action" : "raw",
120-
"command" : "UPDATE account SET balance=balance+? WHERE name=?",
118+
"command" : "UPDATE account SET balance=balance+1 WHERE name='Mr. Test'",
121119
},
122120
{
123-
"action" : "select",
124-
"table" : "account",
125-
"fields" : ["balance"]
121+
"action" : "prepared",
122+
"statement" : "UPDATE account SET balance=balance+? WHERE name=?",
123+
"values" : [25, 'Mr. Test']
126124
}
127125
]
128126
}

src/test/scala/io/vertx/asyncsql/test/mysql/MySqlTest.scala

Lines changed: 2 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -51,9 +51,8 @@ CREATE TABLE """ + tableName + """ (
5151
@Test
5252
override def preparedSelect(): Unit = super.preparedSelect()
5353
@Test
54+
override def transaction(): Unit = super.transaction()
55+
@Test
5456
override def transactionWithPreparedStatement(): Unit = super.transactionWithPreparedStatement()
55-
// @Ignore("not working currently")
56-
// @Test
57-
// override def transaction(): Unit = super.transaction()
5857

5958
}

0 commit comments

Comments
 (0)