[Israel.pm] DBI

Chanan Berler bc.other at gmail.com
Sun Oct 31 07:12:25 PDT 2010


many thanks for your reply
Chanan

On Sun, Oct 31, 2010 at 2:42 PM, Meir Guttman <meir at guttman.co.il> wrote:
> My dear shlomi,
>
> OK, and how would you use placeholders to pass the following (My)SQL query?
>
> LOAD DATA INFILE myLDIfile.tsv
>
> INTO TABLE tbl_name
>
> COLUMNS TERMINATED BY '\t' OPTIONALLY ENCLOSED BY "'" ESCAPED BY '\\'
>
> LINES TERMINATED BY '\r\n'
>
> Meir
>
>
>
> -----Original Message-----
> From: Shlomi Fish [mailto:shlomif at iglu.org.il]
> Sent: Sunday, October 31, 2010 1:59 PM
> To: perl at perl.org.il
> Cc: Meir Guttman; Chanan Berler
> Subject: Re: [Israel.pm] DBI
>
>
>
> On Sunday 31 October 2010 13:44:00 Meir Guttman wrote:
>
>> Dear Chanan,
>
>>
>
>> I think the answer is DBI's 'quote' method. Please lookup
>
>> http://search.cpan.org/~timb/DBI-1.615/DBI.pm#quote
>
>>
>
>
>
> Placeholders are normally preferable over $dbh->quote() (as Jaime noted).
>
>
>
> Regards,
>
>
>
>       Shlomi Fish
>
>
>
> --
>
> -----------------------------------------------------------------
>
> Shlomi Fish       http://www.shlomifish.org/
>
> http://www.shlomifish.org/humour/ways_to_do_it.html
>
>
>
> <rindolf> She's a hot chick. But she smokes.
>
> <go|dfish> She can smoke as long as she's smokin'.
>
>
>
> Please reply to list if it's a mailing list post - http://shlom.in/reply .



-- 
===================
----     Chanan Berler    ----
===================


More information about the Perl mailing list