I am trying this simple thing but I am lost somewhere. I don’t know what I am missing. I am trying to do Dblookup to fetch values from the third column in a view based on the first two coulmn values.
I have 3 fields in a form. For the first field, I am doing Dblookup from the first column of the view. For the second field, I am doing Dblookup from the second column of the view based on the values selected in first field.
Now for the 3rd field, I have to get the value from the third column of the view based on the values selected in first 2 fields. In sort, I have to do dblookup based on 2 keys rather than one. I was trying giving values selected in first 2 fields as a key fro 3rd field separated by colon but its not working.
This is not a multiple key problem.You need an additional view.
Do a copy/paste of your lookup view.
Say the first colum evaluates to dsp1 and the second to dsp2.
Replace the first 2 columns by only one sorted column with a formula like @Text(dsp1)+“*”+@Text(dsp2). You have now only 2 columns left in your new view named say “myview”.
In your form, the formula of the lookup in your 3rd field should now be:
You will see from the designer help that multiple keys are not supported in @formulae for starters.
Second, a lot of Domino devs have given up using anything other than single column lookups. It is common to construct a combined string key that allows a single lookup.
Also avoid looking up non-strings. That can be iffy also. For example non-string lookups fail via local notes Java api but do work using remote Java api. There are other wierd things going on.