XPages ComboBox list values from a view

I have an XPage which works fine on my local client for the following but not on the server version.

I have created a combobox using controls.

In Properties-values I computed the following using javascript to get a list of values from a Notes view in the database.

I used the following script which as I said worked fine and displayed the correct values on local but will not on the server.

var list1 = @DbColumn(“app.nsf”, “View”, 1);

var list2 = @DbColumn(“app.nsf”, “View”, 2);

return @Explode(list + “- " + list2,”,")

The field displays the value

“NaN- undefined”

This error is in the Notes Client view.

-I get http 404 errors when I try and view in the browser on the server.

-http task is running,

-anonymous is in the acl,

-launch is set to specified XPage

-same code/page works locally in the client

What do I need to check here?

Subject: Solved

Solved this by setting field as scoped variable - Request Scope and changing code to

var dbname = new Array(@Subset(@DbName(), 1),“Name of database”);

sessionScope.varname = @DbColumn(dbname,“View Name”,1);

return varname

Subject: @Dbcolumn

I don’t think you’ve got your reference to the database correct. It should be an array with server and database, not just the database name. Look it up in the help

Subject: The Database Help is not helpful

The Help says use the following format when referencing the same db:

@DbColumn(“”, “All”, 1) and this is what I did but this does not work.

Ref:

Lotus Domino Designer XPages Reference > JavaScript language elements > @Functions > @dbcolumn