© 2026 Hedgehog Software, LLC

TwitterGitHubDiscord
More
CommunitiesDocsAboutTermsPrivacy
Search
Star
Setup for Free
Drizzle TeamDT
Drizzle Team•14mo ago•
1 reply
cv01

sql.raw with params array

Is there a way to create a
SQL
SQL
instance using something like
sql.raw('select * from users where id = $1', ['user-id'])
sql.raw('select * from users where id = $1', ['user-id'])
? I am not able to use string templates and I already have a
Query
Query
object like
{sql: "select * from users where id = $1", params: ["user-id"]}
{sql: "select * from users where id = $1", params: ["user-id"]}
that I simply want to run.
Drizzle TeamJoin
The official Discord for all Drizzle related projects, such as Drizzle ORM, Drizzle Kit, Drizzle Studio and more!
11,879Members
Resources

Similar Threads

Was this page helpful?
Recent Announcements

Similar Threads

Run Raw SQL with sql``
Drizzle TeamDTDrizzle Team / help
16mo ago
How to include array literals in raw sql?
Drizzle TeamDTDrizzle Team / help
3y ago
pgTable - raw sql
Drizzle TeamDTDrizzle Team / help
3y ago