Googled the problems around ~30 mins landed nowhere ChatGPT Taught me how to write that SQL correctly in Prisma.queryRaw. Got to know about the ANY,CAST functions in postgres and nice code examples too figure out new concepts easily! The future is here.