mysql and php - some clarity please

Thread Solved

Join Date: May 2009
Posts: 15
Reputation: Namibnat is an unknown quantity at this point 
Solved Threads: 1
Namibnat Namibnat is offline Offline
Newbie Poster

mysql and php - some clarity please

 
0
  #1
34 Days Ago
Please could someone just clear up, or point me to the right thing to read regarding mysql and php.

Once you have made a query and saved it to results, I understand that the query accessed with a number of functions to extract that, such as mysql_fetch_array() and so on.

It returns an "associative array". What does that mean. I seem to always get it working just by trial and error, but I don't actually understand it.

I don't really like to ask questions like this on forums because it seems like I am lazy, but I also can't sit an read endless tutorials hoping that somewhere I will get it. But I am really happy to read tutorials, even if they are fairly verbose, as long as that connection is make clear to me.
Reply With Quote Quick reply to this message  
Join Date: Jun 2007
Posts: 1,227
Reputation: kkeith29 has a spectacular aura about kkeith29 has a spectacular aura about kkeith29 has a spectacular aura about 
Solved Threads: 167
kkeith29's Avatar
kkeith29 kkeith29 is offline Offline
Nearly a Posting Virtuoso
 
0
  #2
34 Days Ago
An associative array is one with named keys.
Ex.
  1. array(
  2. 'name' => 'Name here',
  3. 'other' => 'Other data here'
  4. );

In a mysql result, they are the column names.
Google is your friend.

Use [code] tags.

If you have found a solution to your problem, please mark the thread as SOLVED.
Reply With Quote Quick reply to this message  
Reply

Tags
mysql, php

This thread has been marked solved.
Perhaps start a new thread instead?
Message:


Thread Tools Search this Thread



About Us | Contact Us | Advertise | DaniWeb | Acceptable Use Policy | RSS Feed

©2003 - 2009 DaniWeb® LLC