By using this site, you agree to our updated Privacy Policy and our Terms of Use. Manage your Cookies Settings.
444,027 Members | 1,199 Online
Bytes IT Community
+ Ask a Question
Need help? Post your question and get tips & solutions from a community of 444,027 IT Pros & Developers. It's quick & easy.

DLookups

P: n/a
Hi,
I am trying to get a report to lookup certain fields from a table. I have
different employees that work at different branches. I have made a table with
the employees names and the branch they work at. I need for this to look and
see that a certain employee works and a certain branch. It seems to be
looking at the table but will only give me the first branch name on the table.

example: I have an employee Amanda McFall and another one Joyce Reed. Amanda
works at our East Branch but Joyce works at our Main Branch. Because Amanda
is first in the table at East Branch this is the only branch I get for all
employees.
Here is what I have wrote:
=DLookup("[BranchName]","TellerWeeklyEmployeeBranch","[Employee]=[Employee]")

Any help would be great!]
Thanks

Oct 13 '06 #1
Share this Question
Share on Google+
2 Replies


P: n/a
Where is the dlookup? If it in OnOpen, it will only run once. If it is
OnFormat of the detail section, it will run once for each record.

Why not link the branch table to the report's source query? It would be far
faster then dlookup.

"TyraWY" <u27848@uwewrote in message news:67b76024f02ef@uwe...
Hi,
I am trying to get a report to lookup certain fields from a table. I have
different employees that work at different branches. I have made a table
with
the employees names and the branch they work at. I need for this to look
and
see that a certain employee works and a certain branch. It seems to be
looking at the table but will only give me the first branch name on the
table.
>
example: I have an employee Amanda McFall and another one Joyce Reed.
Amanda
works at our East Branch but Joyce works at our Main Branch. Because
Amanda
is first in the table at East Branch this is the only branch I get for all
employees.
Here is what I have wrote:
=DLookup("[BranchName]","TellerWeeklyEmployeeBranch","[Employee]=[Employee]"
)
>
Any help would be great!]
Thanks

Oct 13 '06 #2

P: n/a

"TyraWY" <u27848@uweschreef in bericht news:67b76024f02ef@uwe...
Hi,
I am trying to get a report to lookup certain fields from a table. I have
different employees that work at different branches. I have made a table with
the employees names and the branch they work at. I need for this to look and
see that a certain employee works and a certain branch. It seems to be
looking at the table but will only give me the first branch name on the table.

example: I have an employee Amanda McFall and another one Joyce Reed. Amanda
works at our East Branch but Joyce works at our Main Branch. Because Amanda
is first in the table at East Branch this is the only branch I get for all
employees.
Here is what I have wrote:
=DLookup("[BranchName]","TellerWeeklyEmployeeBranch","[Employee]=[Employee]")

Any help would be great!]
Thanks
Maybe "[Employee]=[Employee]" is confusng Access?
This is always true so Access gives you the first matching record.

I guess you need:
=DLookup("[BranchName]","TellerWeeklyEmployeeBranch","[Employee]=" & Me![Employee])

Arno R
Oct 13 '06 #3

This discussion thread is closed

Replies have been disabled for this discussion.