Dblookup in Lotus Script

Hi,

I know you can do a dblookup in formula language. However, how do you do this in lotus script.

I am importing a name (eg Jane Smith) from an excel spread sheet and want to lookup her certification eg(Jane Smith/AUS/Company) from the address book database.

Thanks!!!

Subject: Dblookup in Lotus Script

Yes you can, but there’s no direct equivalent. The traditional way of doing a look-up in Lotusscript was to use the GetDocumentByKey method, and then extract the required data from the resulting NotesDocument: potentially very expensive in terms of disk I/O etc. Nowadays, one can also use the NotesViewEntryCollection and NotesViewEntry classes to do equivalent look-ups.

Subject: RE: Dblookup in Lotus Script

What about if the document you would like to look up is in a different database.

In my casem i have delevoped a database that needs to look up values from the address book database.

Thanks.

Subject: RE: Dblookup in Lotus Script

The name of the database you want to put into your script is “names.nsf” and the view that you want to access is ($VIMPeople). That is, if you know the exact name you’re looking for (i.e. First Last/Org, or First Last/OU1/Org).

Do look at the GetDocumentByKey example in online help. You CAN do it! Don’t be afraid of it.

Reach for the stars, you won’t come up with mud in your hands!

Marcus

Subject: RE: Dblookup in Lotus Script

Or Evaluate("@DbLookup