Open devinivy opened 9 years ago
@devinivy wouldn't this depend on the adapter you are using? Postgresql accepts $1
just fine.
Ah, yeah it probably does. That method just uses the driver's query
method directly. The mysql driver wants ?
s. As long as they're consistent, I don't think there's any problem, but it sounds like there's an update needed. Maybe both adapters could support both syntaxes for now?
We don't do any parsing of the strings sent to the .query
method. The actual drivers are different so one accepts $1
and one accepts ?
. We would have to parse the query string to make it support both. We can just change the example or put one example with a postgresql label and one with a mysql label sort of how Knex shows examples for different databases.
At https://github.com/balderdashy/waterline-docs/blob/master/queries/query-methods.md#query-query-data-callback- the format of the query is shown as,
but it should use
?
instead, as such,Related: https://github.com/balderdashy/sails-mysql/issues/245