marshymallow
marshymallow
KKysely
Created by marshymallow on 12/23/2023 in #help
Sqlite JSON
Hello, I'm a new user to Kysely and I'm having trouble using the JSON interface. I would normally just stringify and parse JSON myself when using Kysely, but it looks like I can addColumn("myColumn", "json"). However, when I try to insert values as JSON, I get TypeError: SQLite3 can only bind numbers, strings, bigints, buffers, and null. If I strigify my JSON first, it adds to the database properly, but the Kysely gives me type errors. Should I have my Database table column of type string when I am passing type "json" to Kysely?
8 replies