I'd expect it to be a raw SQL statement. Syntax
knex.schema.raw('set transaction isolation level serializable;')
This setting persists for the current session. That means you might have to change it to something else for other queries in the same session.
您可以使用交易选项,例如:
this.knex.transaction(async (trx) => { ... }, { isolationLevel: 'repeatable read' });
The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.