SriniK has asked for the wisdom of the Perl Monks concerning the following question:
but im not getting the required output. its giving just empty.$Agent1=$dbh->prepare('select substring_index(substring_index(substrin +g_index(Name,"$$$",1),"$$",1),"\$",-1) as Phone_no, substring_index(s +ubstring_index(Name,"$$$",1),"$$",-1) as Mail_Id from CustomFieldValu +es where CustomField =291 and Name like "$name%";') || die "$DBI::er +rstr"; $Agent1->execute() || die "$DBI::errstr" ; ( $phone_no,$mail )= $Agent1->fetchrow_array; print "Phone:\t$phone,Mail:\t$mail\n";
i have changed it like placeholder.... but its not working.Phone: ,Mail:
|
|---|
| Replies are listed 'Best First'. | |
|---|---|
|
Re: DBI Substring index query and passing value
by marto (Cardinal) on Dec 11, 2012 at 11:27 UTC | |
|
Re: DBI Substring index query and passing value
by Anonymous Monk on Dec 11, 2012 at 09:29 UTC | |
by SriniK (Beadle) on Dec 11, 2012 at 10:41 UTC | |
by Anonymous Monk on Dec 11, 2012 at 11:12 UTC |