Subject Re: [firebird-php] ibase_param_info
Author Lester Caine
Sándor Tamás wrote:
> I've tried it with field names, but didn't help. (I think, it is
> correct, because I don't have to include all the fields in SELECT which
> I want to filter inWHERE)
>
> I think now that the driver uses the same structure for parameters as
> for fields, but for parameters, these values (name, alias, and relation)
> are left empty.

That may well be the case since the parameters are not passed to the prepared
query using names ... they only need to be in the same order as the '?'s in the
query? I have the names for these in the array that I am feeding to the query so
I've never had to look ;)

> 2010.07.28. 11:16 keltezéssel, Lester Caine írta:
>>
>> Sándor Tamás wrote:
>>> I'm just curious about the naming of FB parameters.
>>> I realized, that ibase_param_info returns an array which has a "name"
>>> and an "alias" key. How can I give these values to an ibase_prepare
>>> statement?
>>
>> I think you will find that using the '*' is part of the problem. If
>> you include
>> the field names in the query, then the I believe that the output is
>> correct, but
>> I'm not sure if one would call the problem a 'bug' or 'as designed'
>> since on one
>> had we need to know what to look for before processing the prepare but
>> the '*'
>> means that the information is only available AFTER the prepare.


--
Lester Caine - G8HFL
-----------------------------
Contact - http://lsces.co.uk/wiki/?page=contact
L.S.Caine Electronic Services - http://lsces.co.uk
EnquirySolve - http://enquirysolve.com/
Model Engineers Digital Workshop - http://medw.co.uk//
Firebird - http://www.firebirdsql.org/index.php