DB lookup not working

Hi,

The following code seems to work for users with lotus notes 6 but not with lotus notes 5. Does the lotus notes version make a difference or should I be coding this differently? Basically this code prompts the user to enter their profile information in the database, if it has already been entered, they are able to create a new request.

requestor := @Name([CN]; @UserName);

Lookup := (@DbLookup(“”:“NoCache”;“”;“Development Contact”;requestor;2;[FailSilent]));

@If(Lookup = “”;

@Return(@Do(@Prompt([Ok];“Contact Information Missing!”;“Please fill out your contact information on the following form.” );@Command([Compose];“Development Contact”)));

@Success);

@Command([Compose];“Production Form”)

Thanks so much in advance!

Subject: DB lookup not working.

I doubt it’s affecting it, but you don’t need an extra set of parenthesis around this statment:Lookup := (@DbLookup(“”:“NoCache”;“”;“Development Contact”;requestor;2;[FailSilent]));

THIS will work as well:

Lookup :=@DbLookup(“”:“NoCache”;“”;“Development Contact”;requestor;2;[FailSilent]);

Also… I don’t recall… [FailSilent] in R5, if that is a new 6 flag… that would explain it.

Subject: RE: DB lookup not working.

Hi,

Thanks…You are right…it is new to r6. do you know what else I could insert in place of failsilent

Thanks!

Subject: Try this

This should work… but I have not tested the syntax… you have a few extra parens.

@If(

@DbLookup(“”:“NoCache”;“”;“Development Contact”;requestor;2);[this means if a positive result comes back, then…]

@Success; [else]

@Do(

@Prompt([Ok];“Contact Information Missing!”;“Please fill out your contact information on the following form.” );

@Command([Compose];“Development Contact”));

@Command([Compose];“Production Form”) [not sure why or when you are calling this form]

Subject: RE: Try this

Hi,

I’m calling the production form if the user profile is already existing in the database. If its there, they can create a new request(production form). If not, then they need to out their information first.

Subject: Ok then…

@If(@DbLookup(“”:“NoCache”;“”;“Development Contact”;requestor;2);[this means if a positive result comes back, then…]

@Do(

@Command([Compose];“Production Form”));

[else]

@Do(

@Prompt([Ok];“Contact Information Missing!”;“Please fill out your contact information on the following form.” );

@Command([Compose];“Development Contact”));

Subject: RE: Ok then…

Thanks for your help!

Subject: RE: Ok then…

Not a problem… If your company is ever looking for a support company… give me a call, it’s what I do.

Ruth Inman

ruth.inman@imwebworks.com