tursodatabase / libsql-client-ts

TypeScript/JavaScript client API for libSQL
https://docs.turso.tech/sdk/ts/quickstart
MIT License
226 stars 32 forks source link

Different ResultSet Output between Querying in Terminal and in Web Environment #148

Open cj-1010-1414 opened 9 months ago

cj-1010-1414 commented 9 months ago

For example, I have this code and email mas.bagus@gmail.com already in the database:

const email = "mas.bagus@gmail.com"
const inDBCheck = await db.execute(`select email from customer where email = "${email}";`)

When I run in a web environment (Deno in my case), that statement will return zero-length row of a ResultSet. But when I run in terminal, it returned a result.

Currently I have no problems with that, I change the double quote around ${email} into single quote. It works on the web!

But I wonder why does it give different results given different environment?