How long can a command sent to MySQL from Perl be?

How long can a command sent to MySQL from Perl be?

am 17.03.2003 23:04:17 von Hal Vaughan

I'm new to SQL and MySQL, so if there is a better way to do this, I don't=
mind=20
hearing this.

I need to select records from one database and put them in a temporary ta=
ble=20
and I'm using the Perl DBI module. The records I need to select will hav=
e to=20
match anywhere from a small to a large number of criteria. I'd like to b=
e=20
able to send one LONG command to MySQL, something that might look like th=
is:

SELECT * FROM Clients where (Field1 =3D "xyz" and Field2 =3D "ABC") or (F=
ield1 =
"tuv" and FIeld2 =3D "DEF);

I'd like to be able to use many more critieria (actually my client would =
like=20
to be able to use many more critieria), so I might have 12 criteria joine=
d by=20
AND or OR.

So just how long a line can I send to MySQL from Perl without the line ge=
tting=20
chomped off or rejected? How can I build really long command lines simil=
iar=20
to multi-line commands when I'm using the MySQL prompt?

Thanks for comments and ideas!

Hal


------------------------------------------------------------ ---------
Please check "http://www.mysql.com/Manual_chapter/manual_toc.html" before
posting. To request this thread, e-mail msql-mysql-modules-thread2085@lists.mysql.com

To unsubscribe, send a message to the address shown in the
List-Unsubscribe header of this message. If you cannot see it,
e-mail msql-mysql-modules-unsubscribe@lists.mysql.com instead.