Standard Format For @Dblookup

Not every client will always put the databases in the same path every time and
that could be a large pain. Note that now the path is dynamic and all that
should concern you is that all of the databases are in the same directory. But
otherwise, it is a good idea to always have the same template for the lookup.
It makes it easier for future developers to read your code.
CLASS := "Notes";
NOCACHE := "NoCache";
CACHE := "Cache";
SERVER := @Subset(@DbName; 1);
fullpath:= @Word(@Implode(@DbName; ";"); ";"; 2);
REM 'replace the 10 below with the exact number of characters in the DB name
including the .nsf';
path := @LeftBack(fullpath; 10) + Version;
REM 'dbname.nsf is the name of the database you are going to look in';
DATABASE := path + "dbname.nsf";
VIEW := "($Lookup)";
KEY := keyword;
COLUMN := 7;
LookUp := @DbLookup(CLASS : CACHE; SERVER : DATABASE;VIEW; KEY; COLUMN);
@If(@IsError(LookUp); ""; LookUp);

Dig Deeper on Domino Resources

Start the conversation

Send me notifications when other members comment.

Please create a username to comment.

-ADS BY GOOGLE

SearchWindowsServer

Search400

  • iSeries tutorials

    Search400.com's tutorials provide in-depth information on the iSeries. Our iSeries tutorials address areas you need to know about...

  • V6R1 upgrade planning checklist

    When upgrading to V6R1, make sure your software will be supported, your programs will function and the correct PTFs have been ...

  • Connecting multiple iSeries systems through DDM

    Working with databases over multiple iSeries systems can be simple when remotely connecting logical partitions with distributed ...

SearchDataCenter

SearchContentManagement

Close