Jump to content

Recommended Posts

Why am i getting this error and how can i fix it please help..!!

 

Here are lines 702 and on....

$oldreports=mysql_query("SELECT matchid,challenger,challenged FROM matches WHERE status='Waiting for Scores'");
while(list($matchid,$challenger,$challenged)=mysql_fetch_row($oldreports)){

$getreport=mysql_query("SELECT * FROM match_reports WHERE reporter='$challenger' AND matchid='$matchid'");
$getreport=mysql_fetch_array($getreport);

$getreport2=mysql_query("SELECT * FROM match_reports WHERE reporter='$challenged' AND matchid='$matchid'");
$getreport2=mysql_fetch_array($getreport2);

 

 

I was missing challenged in my table... can anyone tell fropm this code what lines i need in the table challanged....

 

Like for example

 

challangerid varchar 225

 

$oldreports=mysql_query("SELECT matchid,challenger,challenged FROM matches WHERE status='Waiting for Scores'");
while(list($matchid,$challenger,$challenged)=mysql_fetch_row($oldreports)){

$getreport=mysql_query("SELECT * FROM match_reports WHERE reporter='$challenger' AND matchid='$matchid'");
$getreport=mysql_fetch_array($getreport);

$getreport2=mysql_query("SELECT * FROM match_reports WHERE reporter='$challenged' AND matchid='$matchid'");
$getreport2=mysql_fetch_array($getreport2);


if($getreport[reportid] AND !$getreport2[reportid]){

$_updated = strtotime($getreport[reported]);
$time = time();
$diff = $time - $_updated;
$diff = $diff - '60';
if ($diff > 14400){

$getwinner=mysql_query("SELECT * FROM team WHERE teamid='$challenger'");
$getwinner=mysql_fetch_array($getwinner);

$getloser=mysql_query("SELECT * FROM team WHERE teamid='$challenged'");
$getloser=mysql_fetch_array($getloser);

I don't know what you're trying to say here...  I don't see where you're trying to select from the table 'challenger'.

 

Do you mean that the field 'challenger' doesn't exist and you want to change it to 'challengerid'?

This thread is more than a year old. Please don't revive it unless you have something important to add.

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Restore formatting

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.