Warning: mysql_result() [function.mysql-result]: HELP

PHP programming forum. Ask questions or help people concerning PHP code. Don't understand a function? Need help implementing a class? Don't understand a class? Here is where to ask. Remember to do your homework!

Moderator: General Moderators

Post Reply
dv_evan
Forum Commoner
Posts: 42
Joined: Wed Apr 09, 2008 8:23 am

Warning: mysql_result() [function.mysql-result]: HELP

Post by dv_evan »

Hello everyone,

I ran into some problem with my php codes pulling from a MYSQL database and am asking for your assistance.
I am running a code to extract contacts from a database, everything is coming out fine such as first & Last names/Emails/Telephone. However, I have two address fields with data and this (see below) is what I am getting for these two address fields:

Warning: mysql_result() [function.mysql-result]: Add_1 not found in MySQL result index 3
Warning: mysql_result() [function.mysql-result]: Add_2 not found in MySQL result index 3

I tried changing the field names around and changing the characters values from 'TEXT' to 'VARCHAR' but no success.
These address fields consist of characters such as (commas, #, P.O. Box, etc) I don't know if these are the faults and what to do.

Its strange because the other fields are comming out perfect.

Please, kindly assist.

Regards
Dave
User avatar
novice4eva
Forum Contributor
Posts: 327
Joined: Thu Mar 29, 2007 3:48 am
Location: Nepal

Re: Warning: mysql_result() [function.mysql-result]: HELP

Post by novice4eva »

since the error is for result index 3, maybe the query returned less than 4 rows, have you checked??
Post Reply