On Fri, Jul 23, 2004 at 12:19:24PM -0500, Moreno, Javier wrote:
>    Hi all,
> 
>    I am having issues trying to do the following:
> 
>    SELECT I.idIssue, I.Description, I.idEntry, I.idStatus, E.Description, 
> E.CreateDate, E.idPriority,
>    E.idSeverity, E.idUser, E.DueDate FROM MASTER_Issue I, MASTER_Entry E WHERE 
> I.idIssue = ? AND I.idEntry
>    = E.idEntry
> 
>    The query runs fine but I get no information back from it. What could be wrong? I 
> ran the same query
>    (replacing the placeholder with the value) on the database and it ran fine and 
> returned information.

If I.idIssue is a CHAR type field then you'll need to tell DBD::Oracle
to bind the placeholder as a CHAR. Otherwise the value is bound as a varchar
and oracle doesn't use the blank-padded-comparison-semantics that you need.

        use DBI qw(:sql_types);

        ...
        $sth->bind_param(1, $foo, SQL_CHAR);

Tim.

Reply via email to