Problem In DbLookup

I am facing one strange problem in DBlookup… there is one dialog box in which value comes through DbLookup…having this formula

tmp := @DbLookup(“”:“ReCache”;“”:“”;“(vwActiveContractorDepot)”;cheque_dl_depotname;2);

@If(@IsError(tmp);“”;tmp)

the cheque_dl_depotname (key) is defined havind default value as

user := @GetProfileField(“frmProfile”;“prfUser”);

role := @DbLookup(“”:“NoCache”;“”:“”;“(vwUserMaster)”;user;3);

depot := @Left(@Trim(user);4);

depotCode := @DbLookup(“”:“NoCache”;“”:“”;“vwdepotcode”;depot;2);

@If(role = “Depot”;depotcode;“”)

This field is not visible to the user’s as it takes default value from the view and hence the related value comes in the dialogbox through Dblookup…

My problem is that this is working fine for every user except for one user…as nothing is coming in the dialoglist when he is opening the form…I have checked all the condition’s in view

I am very much confused why the value is not coming in the view…

Kindly give me the solution ASAP

Subject: Problem In DbLookup

Please check ur lookup

@DbLookup(“”:“NoCache”;“”:“”;“vwdepotcode”;depot;2); is fetching any value for that particular user or in 2nd column of vwdepotcode view is having correspondence value for this user…

I am having doubt that the key is calculating null value for this user and thats why its not fetching any value in your final lookup.

tmp := @DbLookup(“”:“ReCache”;“”:“”;“(vwActiveContractorDepot)”;cheque_dl_depotname;2);

Subject: RE: Problem In DbLookup

But it is working finr for other 50 user’s…i used nocache but still it is not working

Subject: RE: Problem In DbLookup

have you checked the lookup key whether its null or not for that user.

As the lookup key is constructing based on user in user profile, may be for this user value is coming null in Key and ur final lookup is getting failed. have a look for ur key…

hope this will work out.

Subject: RE: Problem In DbLookup

this problem is solved now …there was a small proble only with key…value coming in the field was “upco” and in view from which lookup was happening was “upc” …so only this “o”

was creating problem…i modified the string and now value is coming…