Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations wOOdy-Soft on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Recent content by Sitehelp

  1. Sitehelp

    Display ALL Results from DB

    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?
  2. Sitehelp

    Display ALL Results from DB

    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...
  3. Sitehelp

    Display ALL Results from DB

    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?
  4. Sitehelp

    Display ALL Results from DB

    Got ya! yep it returns one result! there should be more!
  5. Sitehelp

    Display ALL Results from DB

    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...
  6. Sitehelp

    Display ALL Results from DB

    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!
  7. Sitehelp

    Display ALL Results from DB

    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...
  8. Sitehelp

    Display ALL Results from DB

    by the way sorry for cross posting someone recommended trying there in the SQL forum earlier!
  9. Sitehelp

    Display ALL Results from DB

    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"...
  10. Sitehelp

    Display more than one Result from DB

    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...
  11. Sitehelp

    Display ALL Results from DB

    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...
  12. Sitehelp

    Display ALL results

    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...
  13. Sitehelp

    Query DB for Call Total etc

    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...
  14. Sitehelp

    Query DB for Call Total etc

    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...
  15. Sitehelp

    Compare Dates 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

Part and Inventory Search

Back
Top