469,903 Members | 2,218 Online
Bytes | Developer Community
New Post

Home Posts Topics Members FAQ

Post your question to a community of 469,903 developers. It's quick & easy.

Check value by DLookup

This is the query which i run when the form load. In
tbl_EquipmentChronology there are three variables Equipment1,
Equipment2, Equipment3. If Equipment1 and 2 are not empty then the
query copy equipment2 value in txt of table tbl_Event. Is it possible i
do the same IIF or any other way i check into DLookup. I mean same if
in tbl_EquipmentChronology Equipment1, 2 and 3 are not empty it shows
the value from Equipment3 in List17.

Thanks

Me.List17=DLookUp("[Equipment1]","tbl_EquipmentChronology",
"[TicketNum] ='" & tbl_Events.TicketNum & "' And [Outlet]='" &
tbl_Events.PPVVOD_Outlet & "'")
This is the query which i run:

UPDATE
tbl_Events
SET
tbl_Events.txt =
iif(nz([tbl_EquipmentChronology].[Equipment3]
,"")<>"",[tbl_EquipmentChronology].[Equipment3],
iif(nz([tbl_EquipmentChronology].[Equipment2]
,"")<>"",[tbl_EquipmentChronology].[Equipment2],
[tbl_EquipmentChronology].[Equipment1]))
From
tbl_Events
INNER JOIN tbl_EquipmentChronology
ON tbl_Events.TicketNum =
tbl_EquipmentChronology.TicketNum
WHERE
tbl_Events.PPVVOD_Outlet=[Tbl_EquipmentChronology].[Outlet]
And tbl_Events.PPVVOD_Outlet<>0

Aug 23 '06 #1
1 1800
Why are you not listening ??
Please do NOT multipost !!!!

If you *have to* then crosspost.
Multi-posting really is wasting people's time.

Arno R
"Eric" <eh******@gmail.comschreef in bericht news:11**********************@h48g2000cwc.googlegr oups.com...
This is the query which i run when the form load. In
tbl_EquipmentChronology there are three variables Equipment1,
Equipment2, Equipment3. If Equipment1 and 2 are not empty then the
query copy equipment2 value in txt of table tbl_Event. Is it possible i
do the same IIF or any other way i check into DLookup. I mean same if
in tbl_EquipmentChronology Equipment1, 2 and 3 are not empty it shows
the value from Equipment3 in List17.

Thanks

Me.List17=DLookUp("[Equipment1]","tbl_EquipmentChronology",
"[TicketNum] ='" & tbl_Events.TicketNum & "' And [Outlet]='" &
tbl_Events.PPVVOD_Outlet & "'")
This is the query which i run:

UPDATE
tbl_Events
SET
tbl_Events.txt =
iif(nz([tbl_EquipmentChronology].[Equipment3]
,"")<>"",[tbl_EquipmentChronology].[Equipment3],
iif(nz([tbl_EquipmentChronology].[Equipment2]
,"")<>"",[tbl_EquipmentChronology].[Equipment2],
[tbl_EquipmentChronology].[Equipment1]))
From
tbl_Events
INNER JOIN tbl_EquipmentChronology
ON tbl_Events.TicketNum =
tbl_EquipmentChronology.TicketNum
WHERE
tbl_Events.PPVVOD_Outlet=[Tbl_EquipmentChronology].[Outlet]
And tbl_Events.PPVVOD_Outlet<>0
Aug 24 '06 #2

This discussion thread is closed

Replies have been disabled for this discussion.

Similar topics

3 posts views Thread by Josh Armstrong | last post: by
3 posts views Thread by Annette Massie | last post: by
2 posts views Thread by Mike N. | last post: by
reply views Thread by Salome Sato | last post: by
By using this site, you agree to our Privacy Policy and Terms of Use.