FAQ
Hi!
Is it possible to bind an array in code like below? Binding simple variables
works perfectly...

@myArray = (1,2,3);

my $superSchema = [$c->model('myApp::mySuperSchema')->search (
{},
{
bind => [ @myArray, $number]
}
) ];

I'm using query like that in my schema mySuperSchema.pm:

SELECT column_id, number FROM table
WHERE column_id IN (?) AND number != ?

Now I get an error:
"Cannot bind unknown placeholder 3"

So is it matter of '?' in SQL query or I should specify bind parameter in
different way?

Regards
Jakub Tutaj


--
View this message in context: http://www.nabble.com/How-to-bind-an-array-using-my-own-schema-tp23526664p23526664.html
Sent from the Catalyst Web Framework mailing list archive at Nabble.com.

Search Discussions

Discussion Posts

Follow ups

Related Discussions

Discussion Navigation
viewthread | post
posts ‹ prev | 1 of 3 | next ›
Discussion Overview
groupcatalyst @
categoriescatalyst, perl
postedMay 13, '09 at 6:10p
activeMay 13, '09 at 6:20p
posts3
users3
websitecatalystframework.org
irc#catalyst

People

Translate

site design / logo © 2022 Grokbase