H
HB
Ihave a union query which in datashseet view shows correctly. The scneario is
Member has person1 and Person2. The union first sorts by person1 and the
second by person2, but I don't know how to get the person2 on the list? I
would have thought what appeared in datasheet view would have matched the
report but it's not. Why is this? for what it's worth...here is the query...
SELECT MEMBER.MemberNumber, [LastName1] & " " & [FirstName1] &
IIf([isSenior1]," *S") & " " & [LastName2] & " " & [FirstName2] &
IIf([isSenior2]," *S") AS Name, MEMBER.EquityStatus, MEMBER.CardExpireDate,
IIf([EquityStatus]="FULL","*F","") AS Expr1
tia.
HB
FROM MEMBER
WHERE (((MEMBER.EquityStatus)="Full" Or (MEMBER.EquityStatus)="Current" Or
(MEMBER.EquityStatus)="NonCurrent"))
ORDER BY MEMBER.LastName1;
UNION SELECT MEMBER.MemberNumber, [LastName2] & " " & [FirstName2] &
IIf([isSenior2]," *S") & " " & [LastName1] & " " & [FirstName1] &
IIf([isSenior2]," *S") AS Name, MEMBER.EquityStatus, MEMBER.CardExpireDate,
IIf([EquityStatus]="FULL","*F","") AS Expr1
FROM MEMBER
WHERE (((MEMBER.EquityStatus)="Full" Or (MEMBER.EquityStatus)="Current" Or
(MEMBER.EquityStatus)="NonCurrent") AND ((MEMBER.FirstName2) Is Not Null))
ORDER BY [Name];
Member has person1 and Person2. The union first sorts by person1 and the
second by person2, but I don't know how to get the person2 on the list? I
would have thought what appeared in datasheet view would have matched the
report but it's not. Why is this? for what it's worth...here is the query...
SELECT MEMBER.MemberNumber, [LastName1] & " " & [FirstName1] &
IIf([isSenior1]," *S") & " " & [LastName2] & " " & [FirstName2] &
IIf([isSenior2]," *S") AS Name, MEMBER.EquityStatus, MEMBER.CardExpireDate,
IIf([EquityStatus]="FULL","*F","") AS Expr1
tia.
HB
FROM MEMBER
WHERE (((MEMBER.EquityStatus)="Full" Or (MEMBER.EquityStatus)="Current" Or
(MEMBER.EquityStatus)="NonCurrent"))
ORDER BY MEMBER.LastName1;
UNION SELECT MEMBER.MemberNumber, [LastName2] & " " & [FirstName2] &
IIf([isSenior2]," *S") & " " & [LastName1] & " " & [FirstName1] &
IIf([isSenior2]," *S") AS Name, MEMBER.EquityStatus, MEMBER.CardExpireDate,
IIf([EquityStatus]="FULL","*F","") AS Expr1
FROM MEMBER
WHERE (((MEMBER.EquityStatus)="Full" Or (MEMBER.EquityStatus)="Current" Or
(MEMBER.EquityStatus)="NonCurrent") AND ((MEMBER.FirstName2) Is Not Null))
ORDER BY [Name];