Sounds like it’s not really SQL as a query language but rather the whole database paradigm that’s the problem here.
Look into noSQL databases and their respective drivers. They often use JSON-like syntax and are more likely to be seamlessly integrated with whatever programming language you’re using.
If a search engine won’t point you in the right direction I’d suggest having a look at MongoDB, which is well documented and fairly accessible to mess around with.
Definitely Sonic Adventure. But I’ll also name a gem no one else is going to mention: