Re: Interbase DB, again =)
| From: | Tomas V.V.Cox | Date: | Mon, 18 Feb 2002 15:41:36 +0000 |
| Subject: | Re: Interbase DB, again =) | ||
| References: | 1 2 3 | Groups: | php.pear.dev |
| Request: | Send a blank email to pear-dev+get-4780@lists.php.net to get a copy of this message | ||
Ludovico Magnocavallo wrote:
>
> > Can you try to find if it's a behavior of get_object_vars() or
> > ibase_fetch_object()? For ex:
>
> Ehm , I could stated this in my first post =)
>
> >From the get_object_vars() php manual page:
>
> "This function returns an associative array of defined object properties for
> the specified object obj. If variables declared in the class of which the
> obj is an instance, have not been assigned a value, those will not be
> returned in the array."
>
> It's the php function that is skipping vars. I may be wrong, but I'd much
> prefer to get back all object vars, even empty ones, from such a function.
Ah, I see. Yes, can't understand very well why the function doesn't
return empty values. Change request? :-)
> Any chance on getting its behavior changed, or should we look for a hack in
> ibase.php?
What about trying my other solution?
$obj = ibase_fetch_object($result);
if (is_object($obj)) {
$ar = (array)$obj;
} else {
$ar = null;
}
Tomas V.V.Cox