Excerpted from my apache logs, I'm seeing:

DEBUG: $self->_process_cc_pre_confirm() says the sql.get_new_subscribe +r query reads: $VAR1 = 'SELECT lsmb_acct_id, addr1, addr2, city, state, zip, billing_ +plan, billing_cycle, fname, lname, email, phone FROM accounts a LEFT +JOIN account_users u ON a.account_code = u.account_code WHERE account +_billing_contact = \\\\\\'yes\\\\\\' AND a.account_code = ?'; Uncaught exception from user code: \tDBD::Pg::st execute failed: called with 1 bind variables when 0 are +needed at . . . line 569.
This log noise is thrown by code reading:

my $sql = $self->{'cfg'}->param("sql.get_new_subscriber"); $self->log('DEBUG','$self->_process_cc_pre_confirm() says the sql.ge +t_new_subscriber query reads: ',$sql); my $sth = $self->{'dbh'}->prepare($sql); $sth->execute($self->{'s'}->param('account_code')); my $subscriber = $sth->fetchrow_hashref();
My configuration file reads in relevant part:

get_new_subscriber='SELECT lsmb_acct_id, addr1, addr2, city, state, zi +p, billing_plan, billing_cycle, fname, lname, email, phone FROM accou +nts a LEFT JOIN account_users u ON a.account_code = u.account_code WH +ERE account_billing_contact = \'yes\' AND a.account_code = ?'
I have no idea why my quoted value for account_billing_contact gets so thoroughly escaped in my logs. Nor any idea why the need for my bind variable is not recognized. Though I suspect the two questions may be related somehow.

Any thoughts on how to resolve this issue?

-- Hugh

if( $lal && $lol ) { $life++; }
if( $insurance->rationing() ) { $people->die(); }

In reply to A bind variable is really needed here . . . by hesco

Title:
Use:  <p> text here (a paragraph) </p>
and:  <code> code here </code>
to format your post, it's "PerlMonks-approved HTML":



  • Posts are HTML formatted. Put <p> </p> tags around your paragraphs. Put <code> </code> tags around your code and data!
  • Titles consisting of a single word are discouraged, and in most cases are disallowed outright.
  • Read Where should I post X? if you're not absolutely sure you're posting in the right place.
  • Please read these before you post! —
  • Posts may use any of the Perl Monks Approved HTML tags:
    a, abbr, b, big, blockquote, br, caption, center, col, colgroup, dd, del, details, div, dl, dt, em, font, h1, h2, h3, h4, h5, h6, hr, i, ins, li, ol, p, pre, readmore, small, span, spoiler, strike, strong, sub, summary, sup, table, tbody, td, tfoot, th, thead, tr, tt, u, ul, wbr
  • You may need to use entities for some characters, as follows. (Exception: Within code tags, you can put the characters literally.)
            For:     Use:
    & &amp;
    < &lt;
    > &gt;
    [ &#91;
    ] &#93;
  • Link using PerlMonks shortcuts! What shortcuts can I use for linking?
  • See Writeup Formatting Tips and other pages linked from there for more info.