Re: [PHP] php mysql array question

This is a discussion on Re: [PHP] php mysql array question within the PHP General forums, part of the PHP Programming Forums category; > Is there any php function to pull a query into an array? I know there is a > way ...


Go Back   Usenet Forums > PHP Programming Forums > PHP General

FAQ Members List Calendar Search Today's Posts Mark Forums Read
  #1 (permalink)  
Old 07-11-2003
Cpt John W. Holmes
 
Posts: n/a
Default Re: [PHP] php mysql array question

> Is there any php function to pull a query into an array? I know there is
a
> way to get the first row of the results in an array, but I'm having to

loop
> through each row pushing the row onto an array to get the result I'm

looking
> for and it seems like a lot of code for something that I would think is

used
> a lot.


There's no PHP function to do so. Some abastraction layers provide this, but
it's just doing a loop like you're doing.

Show your code and we can offer tips on how to improve performance.

---John Holmes...

Reply With Quote
  #2 (permalink)  
Old 07-11-2003
Philip Olson
 
Posts: n/a
Default Re: [PHP] php mysql array question

On Fri, 11 Jul 2003, CPT John W. Holmes wrote:

> > Is there any php function to pull a query into an array? I know there is

> a
> > way to get the first row of the results in an array, but I'm having to

> loop
> > through each row pushing the row onto an array to get the result I'm

> looking
> > for and it seems like a lot of code for something that I would think is

> used
> > a lot.

>
> There's no PHP function to do so. Some abastraction layers provide this, but
> it's just doing a loop like you're doing.
>
> Show your code and we can offer tips on how to improve performance.


I'm glad this feature doesn't exist. Just think how abused it would
be, how many people would use it, when few would actually need it.
Most people can use the data while in the loop, not after. Or do
what is needed in the sql, not php. Maybe I'm a little too parental
though, but so be it. :)

Regards,
Philip

Reply With Quote
Reply


Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are Off
[IMG] code is Off
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On



All times are GMT +1. The time now is 07:14 PM.


Powered by vBulletin® Version 3.6.8
Copyright ©2000 - 2008, Jelsoft Enterprises Ltd.
Content Relevant URLs by vBSEO 3.0.0