oskare100 Posted October 30, 2006 Share Posted October 30, 2006 Hello,When I rund this part of the script:[code=php:0]$sql13 = "select account_username from paypal_sales where txn_id = '$txn_id'";$result13 = mysql_query($sql13) or die( mysql_error() );$del_account_username = mysql_result($result13);echo "Username: $del_account_username";[/code]I get the error:Warning: Wrong parameter count for mysql_result() in /home/httpd/vhosts/com/What does that mean? There is a value for account_username in the table paypal_sales where the txn_id in the database is the same as the $txn_id variable in the script.Best RegardsOskar R Link to comment https://forums.phpfreaks.com/topic/25604-warning-wrong-parameter-count-for-mysql_result-in-homehttpdvhostscom/ Share on other sites More sharing options...
obsidian Posted October 30, 2006 Share Posted October 30, 2006 mysql_result() takes a minimum of 2 parameters: the result ID and the row number. You also typically need to pass the column name of the value you're after, too:[code]<?php$del_account_username = mysql_result($result13, 0, 'username');?>[/code] Link to comment https://forums.phpfreaks.com/topic/25604-warning-wrong-parameter-count-for-mysql_result-in-homehttpdvhostscom/#findComment-116864 Share on other sites More sharing options...
Recommended Posts
Archived
This topic is now archived and is closed to further replies.