On Tue, Jan 26, 2010 at 10:42 PM, Peter Rabbitson <rabbit+dbic@rabbit.uswrote:
Drew Taylor wrote:
SQL::Abstract.
In short:
to supply a string of raw sql:
\$sql
to supply a string of raw sql bundled with bind values for placeholders:
\[ $sql, @list_of_bindvals ]
Drew Taylor wrote:
I'm not a DBIC expert, but I don't think so. The [...] construct creates
an arrayref, so the leading '\' would just create a reference to a
reference which is probably NOT what you want. :-) Perhaps you're
thinking about passing a scalar ref to put raw SQL into the query, ie.
\"some sql"?
This is exactly what you want. Please refer to the fine docs ofan arrayref, so the leading '\' would just create a reference to a
reference which is probably NOT what you want. :-) Perhaps you're
thinking about passing a scalar ref to put raw SQL into the query, ie.
\"some sql"?
SQL::Abstract.
In short:
to supply a string of raw sql:
\$sql
to supply a string of raw sql bundled with bind values for placeholders:
\[ $sql, @list_of_bindvals ]
learned something new. :-)
Drew
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://lists.scsys.co.uk/pipermail/dbix-class/attachments/20100126/b9814196/attachment.htm
An HTML attachment was scrubbed...
URL: http://lists.scsys.co.uk/pipermail/dbix-class/attachments/20100126/b9814196/attachment.htm