4 ms·
I've been through the hassle of programatically piecing together complex SQL queries, and I'd far rather be able to just put together hashes that represent my q
by mattparlane 14y ago
I've been through the hassle of programatically piecing together complex SQL queries, and I'd far rather be able to just put together hashes that represent my query.
SQL was originally designed so that people who were savvy but not necessarily developers were able to query databases, but I can't think of the last time my boss would have wanted to run some random query against our production database.
- msarchet 14y agoThis is a daily occurrence at some companies
- sm_sohan 14y agoI am not sure of its origin. But these days you'll find good ORMs that would craft the query for you. My point is, the Mongo API seems to be more of a machine readable API with the $ keys used somewhat in a hacky way.
- cerales 14y agoSurely by the time you're programmatically generating SQL queries you should be using either an ORM or some other kind of SQL expression language embedded in a more expressive language (such as SQLAlchemy or the myriad lisp DSPs for relational databases)?