newb question: ... LIKE "%somestring%" fails

------=_NextPart_000_0009_01C4C64B.A40BF370
Content-Type: text/plain;
charset="us-ascii"
Content-Transfer-Encoding: 7bit

Hello everyone,



I'm trying to get a query going which contains a percentage mark (in
conjunction with the sql LIKE operator). Perl doesn't seem to like this in a
string (containing my query) however. Does anyone know how to circumvent or
solve this?



Thanks in advance,



Edgar Meij


------=_NextPart_000_0009_01C4C64B.A40BF370--
Edgar Meij [ Di, 09 November 2004 11:02 ] [ ID #473498 ]

RE: newb question: ... LIKE "%somestring%" fails

Escape the % signs like "\%something\%"

Regards,
Pete
----
Peter P. Benac, CCNA
Celtic Spirit Networking
Providing Network and Systems Project Management and Installation and =
Web
Hosting.
Phone: 919-618-2557
Web: http://www.emacolet.com
Need quick reliable Systems or Network Management advice visit
http://www.nmsusers.org

To have principles...
First have courage.. With principles comes integrity!!!




-----Original Message-----
From: Edgar Meij [mailto:Edgar.Meij [at] student.uva.nl]
Sent: Tuesday, November 09, 2004 5:03 AM
To: perl [at] lists.mysql.com
Subject: newb question: ... LIKE "%somestring%" fails


Hello everyone,



I'm trying to get a query going which contains a percentage mark (in
conjunction with the sql LIKE operator). Perl doesn't seem to like this =
in a
string (containing my query) however. Does anyone know how to circumvent =
or
solve this?



Thanks in advance,



Edgar Meij



--
MySQL Perl Mailing List
For list archives: http://lists.mysql.com/perl
To unsubscribe: http://lists.mysql.com/perl?unsub=3Dgcdmp-msql-mysql-modules [at] m.gmane.org
ppbenac [ Di, 09 November 2004 11:26 ] [ ID #473499 ]
Datenbanken » gmane.comp.db.mysql.perl » newb question: ... LIKE "%somestring%" fails

Vorheriges Thema: Spaces in Data Fields
Nächstes Thema: Client authentication error -- suddenly