Leader1.StaffID is a field in the Dynamic table that contains the StaffIDs. A dynamic table is a table of results from your SQL query that appear in the browser. The table appears ok for everything but this query?
ok I have another query which displays all the staffIDs and the number of closed calls they have made with the SQL:
SELECT StaffID, count(CallID)
FROM callinfo
WHERE callinfo.CallStatus = 'Closed'
GROUP BY StaffID
ORDER BY CallID ASC
This works! It puts all the data into a dynamic table. The...
Could the following line cause this?
WHERE callinfo.StaffID = '{$row_Leader1['StaffID']}'
I say this because I have only called $row which I presume is one row?
Ah problem was the case of:
print $query_callsAssignedCount;
just remembered its case sensitive and so therefore needs to be:
print $query_CallsAssignedCount;
Ok its now loading up code in the browser and the same in View Source, this is:
SELECT StaffID, count(CallID) FROM callinfo WHERE...
will remember that one! ok I was getting a parse error so change too, but presume this is ok:
exit();
when I load up the browser it returns a blank page, I presume this is not right!
ok so I copied:
$query_CallsAssignedCount ;
into my code after:
$totalRows_CallsAssignedCount = mysql_num_rows($CallsAssignedCount);
Then when I opened up the browser it gave me one result like before, is this what you asked? still learning...
I have tried looping the code below but its still only returning one StaffID?
mysql_select_db($database_MARTIN, $MARTIN);
$query_CallsAssignedCount = "SELECT StaffID, count(CallID) FROM callinfo WHERE callinfo.StaffID = '$row_Leader1[StaffID]' GROUP BY StaffID ORDER BY CallID ASC"...
Hi! Any ideas why this:
mysql_select_db($database_MARTIN, $MARTIN);
$query_CallsAssignedCount = "SELECT StaffID, count(CallID) FROM callinfo WHERE callinfo.StaffID = '$row_Leader1[StaffID]' GROUP BY StaffID ORDER BY CallID ASC";
$CallsAssignedCount = mysql_query($query_CallsAssignedCount...
Hi! Any ideas why this:
mysql_select_db($database_MARTIN, $MARTIN);
$query_CallsAssignedCount = "SELECT StaffID, count(CallID) FROM callinfo WHERE callinfo.StaffID = '$row_Leader1[StaffID]' GROUP BY StaffID ORDER BY CallID ASC";
$CallsAssignedCount = mysql_query($query_CallsAssignedCount...
Hi! Any ideas why this:
mysql_select_db($database_MARTIN, $MARTIN);
$query_CallsAssignedCount = "SELECT StaffID, count(CallID) FROM callinfo WHERE callinfo.StaffID = '$row_Leader1[StaffID]' GROUP BY StaffID ORDER BY CallID ASC";
$CallsAssignedCount = mysql_query($query_CallsAssignedCount...
Actually I have it now printing all the calls that are open for the first StaffID but not for the rest????
SELECT StaffID, count(CallID)
FROM callinfo
WHERE callinfo.CallStatus = 'Closed'
GROUP BY StaffID
ORDER BY CallID ASC
The rest just get the same number of calls as the first for some...
Excellent that worked! I want to add an extra column to the results, I am using:
SELECT count(callID)
FROM callinfo
WHERE callinfo.StaffID = '$row_Leader1.StaffID'
Where '$row_Leader1.StaffID' is the StaffID result from the last query as its printing out in a dynamic table in Dreamweaver...
I am using PHP. What I want for the user to enter too dates in 01-01-2004 format. First they enter the Start Date then they enter an End Date. Then when they click submit a list of all CallsIDs in the DB will be listed that are between the two specified dates. Cheers
Hello all, ok I want to query mySQL database for my web site. I have the columns StaffID, CallID and status in the DB. Status is either open or closed. StaffID is a list off all users, and finally callID is the call number they closed i.e. whether they closed call 1 or call 2 etc.
So in my...
Is there a command in Dreamweaver MX that compares 2 text boxes, which will contain dates that are stored in MySQL. It will then print out all the dates that are inbetween them preferably underneath or on the next page. Cheers!
Staff ID is a column in my dynamic table. The table gets each value from the recordset:
SELECT *
FROM callinfo
WHERE callinfo.CallStatus = 'Open' AND callinfo.Priority = 'Amber'
Then prints it all out in a table on the page. But what I want is for the PHP code to look in the table in the...
See what u mean, thanks! I have changed this now to:
if ($row_ViewAmberCalls['StaffID'] == "Unassigned")
{echo "<font color = \"#FF0000\">";}
This looks in the ViewAmberCalls table, row "StaffID' and looks for any record that is called unassigned and changed the unassigned text to red...
Right! ok well anyway, got rid of the parse error and the page loads up but the unassigned text does not go red????
if ($ViewAmberCalls.StaffID == "Unassigned")
{echo "<font color = \"#FF0000\">";}
This is not far off.... is it?
This site uses cookies to help personalise content, tailor your experience and to keep you logged in if you register.
By continuing to use this site, you are consenting to our use of cookies.