-
Notifications
You must be signed in to change notification settings - Fork 50
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Implementing multi-row insert for liftQuery(...).foreach #172
Conversation
@@ -78,7 +78,7 @@ trait JdbcContextVerbExecute[+Dialect <: SqlIdiom, +Naming <: NamingStrategy] ex | |||
groups.flatMap { | |||
case BatchGroup(sql, prepare) => | |||
val ps = conn.prepareStatement(sql) | |||
logger.underlying.debug("Batch: {}", sql) | |||
//logger.underlying.debug("Batch: {}", sql.take(200) + (if (sql.length > 200) "..." else "")) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
unintentional?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Whoops. I’ll fix that
@@ -0,0 +1,7 @@ | |||
#!/bin/bash | |||
|
|||
# Make the Postgres DB image have 100ms latency for all requests. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
50ms
Are all variables sanitized ? I cannot find anything related. For jdbc, it is safe to execute via |
Have a look at Particularize. It's like an advanced version of ReifyLiftings.
I'm only supporting this functionality for JDBC contexts for now. This will need to be tested separately for Jasync and others. |
Also Fixing: zio/zio-quill#1269 for ProtoQuill
Implementing multi-insertion capabilities for most contexts via the VALUES (clauseA), (clauseB), (clauseC), etc... construct. The performance benefits of this when working of a network with any kind of real latency are significant e.g. insertion of 1 million rows goes down from 6.6 minutes to 10 seconds!