Todd thank you!

i have recieved three respoonses with 3 differnt ways to do it!

hehe
they all work!

i just need to learn more basic sql....

again thank you.

-paul

Web Developer, NBBJ
Work:   [EMAIL PROTECTED]
        614 241-3534
fax:    614 485-5534

Home:   [EMAIL PROTECTED]
        614 449-1681

> icq:  47658358
> 
> -----Original Message-----
> From: Todd Stanley [SMTP:[EMAIL PROTECTED]]
> Sent: Tuesday, February 13, 2001 11:01 AM
> To:   CF-Talk
> Subject:      RE: <> Query not working right<> NEQ
> 
> You're pulling back all records from both tables where there is not a
> match.
> Try this
> 
> 
> <cfquery name="noVote">
>       SELECT
>               tbl_employee.employeeid,
>               firstname,
>               lastname
>       FROM
>               tbl_employee LEFT JOIN tbl_Awards
>               ON tbl_employee.employeeID = tbl_awards.employeeID
>       WHERE
>               tbl_awards.employeeID IS NULL
>               AND LastName NOT LIKE '%Conf%' 
>               AND LastName NOT LIKE '%Mailroom%' 
>               AND LastName NOT LIKE '%XEROX%' 
>               AND LastName NOT LIKE '%_NoUser%' 
>       ORDER BY 
>               LastName DESC 
> </cfquery>
> 
> 
> -----Original Message-----
> From: Paul Ihrig [mailto:[EMAIL PROTECTED]]
> Sent: Tuesday, February 13, 2001 10:40 AM
> To: CF-Talk
> Subject: <> Query not working right<> NEQ
> 
> 
> i want this simple query to show users who have not voted.
> it is not working the way i think it should.
> i have tried putting a DISTINCT on tbl_Employee.EmployeeID.
> 
> if you have any suggestions of somthing i have over looked i would
> appreciate it.
> i am using access.
> 
> <cfquery name="noVote">
> SELECT DISTINCT tbl_Employee.EmployeeID, FirstName, LastName 
> FROM tbl_Awards, tbl_Employee 
> WHERE tbl_Employee.EmployeeID<>tbl_Awards.EmployeeID
> AND LastName NOT LIKE '%Conf%' 
> AND LastName NOT LIKE '%Mailroom%' 
> AND LastName NOT LIKE '%XEROX%' 
> AND LastName NOT LIKE '%_NoUser%' 
> ORDER BY LastName DESC 
> </cfquery>
> 
>               
> <CFOUTPUT QUERY="noVote">  
>   <tr bgcolor="#IIF(CurrentRow MOD 2, DE('FFFFFF'), DE('D5D5D5'))#"> 
>     <td width="50%" height="17">#noVote.FirstName#  #noVote.LastName#
> </td>
>     <td width="50%" height="17">&nbsp;</td>
>   </tr>
> </cfoutput> 
> 
>          Thank You!
> 
> -paul
> 
> Web Developer, NBBJ
> Work:         [EMAIL PROTECTED]
>       614 241-3534
> fax:  614 485-5534
> 
> Home:         [EMAIL PROTECTED]
>       614 449-1681
> 
> > icq:        47658358
>
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
Structure your ColdFusion code with Fusebox. Get the official book at 
http://www.fusionauthority.com/bkinfo.cfm

Archives: http://www.mail-archive.com/[email protected]/
Unsubscribe: http://www.houseoffusion.com/index.cfm?sidebar=lists

Reply via email to