I think you mean this

                SELECT  UserName, FirstName, LastName, Email
                FROM     Users
                WHERE  UserNumber=#Session.UserNumber#
                  AND      UserNumber=#GetOrder.UserNumber#
                  AND      UserNumber=#GetOrder.ApprovalBy#

Bare in mind that each row returned will have the UserName, FirstName,
LastName, Email columns





"Gene Kraybill" <[EMAIL PROTECTED]> on 09/29/2000 02:20:31 PM

Please respond to [EMAIL PROTECTED]

To:   CF-Talk <[EMAIL PROTECTED]>
cc:    (bcc: Jerry Tolentino/SIAC)
Subject:  OT: combining SQL queries




<CFQUERY NAME="GetSenderDetails" DATASOURCE="#datasource#">
     SELECT UserName, FirstName, LastName, Email
     FROM Users
     WHERE UserNumber=#Session.UserNumber#
     </CFQUERY>
<CFQUERY NAME="GetOrdererDetails" DATASOURCE="#datasource#">
     SELECT UserName, FirstName, LastName, Email
     FROM Users
     WHERE UserNumber=#GetOrder.UserNumber#
     </CFQUERY>
<CFQUERY NAME="GetApproverDetails" DATASOURCE="#datasource#">
     SELECT UserName, FirstName, LastName, Email
     FROM Users
     WHERE UserNumber=#GetOrder.ApprovalBy#
     </CFQUERY>

Any way to combine these three queries and still be able to reference the
Sender,
Orderer and Approver in my output?

Gene Kraybill
---------------------------------
Gene Kraybill
LPW & Associates LLC
www.lpw.net
---------------------------------------------------------------------------
---
Archives: http://www.mail-archive.com/cf-talk@houseoffusion.com/
To Unsubscribe visit
http://www.houseoffusion.com/index.cfm?sidebar=lists&body=lists/cf_talk or
send a message to [EMAIL PROTECTED] with 'unsubscribe' in
the body.






------------------------------------------------------------------------------
Archives: http://www.mail-archive.com/cf-talk@houseoffusion.com/
To Unsubscribe visit 
http://www.houseoffusion.com/index.cfm?sidebar=lists&body=lists/cf_talk or send a 
message to [EMAIL PROTECTED] with 'unsubscribe' in the body.

Reply via email to