In your query you have compid specified twice. If this field is named the
same in two seperate tables, preface your fieldnames with the table names...
>$sql="SELECT fname, lname, users.compid, status, dept, room, bldg, phone,
>ticket_num, tickets.compid, date_rpt, request_type, hardware, model, dci,
>dci_num,software_type, software_pkg, problem, comments, entered_by
>FROM users, tickets
>WHERE users.compid = tickets.compid
>ORDER BY lname";
At 10:04 AM 4/6/01 -0400, Toni Barskile wrote:
>Hi:
>
>Can someone please explain the following error message?
>
>ERROR 1052: Column: 'compid' in field list is ambiguous
>
>Here's my mySQL statement:
>
>$sql="SELECT fname, lname, compid, status, dept, room, bldg, phone,
>ticket_num, compid, date_rpt, request_type, hardware, model, dci,
>dci_num,software_type, software_pkg, problem, comments, entered_by
>FROM users, tickets
>WHERE users.compid = tickets.compid
>ORDER BY lname";
>
>
>Thanks in Advance
>
>Toni
>_________________________________________________________________
>Get your FREE download of MSN Explorer at http://explorer.msn.com
>
>
>--
>PHP General Mailing List (http://www.php.net/)
>To unsubscribe, e-mail: [EMAIL PROTECTED]
>For additional commands, e-mail: [EMAIL PROTECTED]
>To contact the list administrators, e-mail: [EMAIL PROTECTED]
>
>
--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
To contact the list administrators, e-mail: [EMAIL PROTECTED]