plainblack / ving

An opinionated web services starter for Nuxt3 that provides REST and per-field privileges out of the box.
https://plainblack.github.io/ving/
58 stars 7 forks source link

sql debugging #55

Closed rizen closed 4 months ago

rizen commented 5 months ago

add sql debugging to the logs, either via:

https://orm.drizzle.team/docs/goodies#logging

or

use .toSQL() method:

const query = db.select().from(user).toSQL();

console.log(query);
{
  sql: 'select "id", "email", "emailVerified", "username", "name", "image", "createdAt" from "user"',
  params: []
}