K
Kysely•2y ago
dj0024javia

Mysql Query execution never ends

Hello, I have a question regarding my new integration of kysely in trpc. I wanted to port my prisma code to kysely and found that queries are indeed firing to db, but they never end the execution. Anyone knows why this is happening? Connection is taken from pool and mysql workbench also shows connection to db. Just the data is not returning. Same code is working with Prisma. Not sure where its going wrong. Can anyone help?
Solution:
Hey 👋 Try importing createPool from mysql2 and not mysql2/promise....
Jump to solution
2 Replies
Solution
Igal
Igal•2y ago
Hey 👋 Try importing createPool from mysql2 and not mysql2/promise.
dj0024javia
dj0024javia•2y ago
yeah, did that. Initially I imported from mysql after i saw the incorrect import, which took 1.2ms time to fire a simple select query. Using mysql2. it took 2.4ms.... Hmm...found something wierd...and its replicating as well on subsequent attempts Thanks @Igal for the help though. In my old code, I was using promise based pool so copied import from there 🙈
Want results from more Discord servers?
Add your server