I created an XPage and added a view control to it, based on a Notes view in which some of the columns are based on formulas rather than fields (for example, @If(nomprov="";cifprov;nomprov)). As a result, the column name on the XPage is a number preceded by a dollar sign, such as $14. View columns that are field based do not show such behavior (the column name on the XPage is the name of the field).
This did not harm on any way, but now I am trying to implement full-text search on the XPage view, and the search on $* columns is not working. This is the definition of one of these columns on the page source:
<xp:viewColumn id="viewColumn3" styleClass="columna"
columnName="$14">
<xp:viewColumnHeader value="Proveedor"
id="viewColumnHeader3" styleClass="cabecera" sortable="true">
</xp:viewColumnHeader>
</xp:viewColumn>
And this is the code I have on the property data\data\search of the view:
var qstring;
if (sessionScope.searchNumfac != null & sessionScope.searchNumfac != "") {
qstring = "(Field numfac = *" + sessionScope.searchNumfac + "*)"
+ " OR (Field nomsociedad = *" + sessionScope.searchNumfac + "*)"
+ " OR (Field $14 = *" + sessionScope.searchNumfac + "*)";
}
sessionScope.queryString = qstring;
return qstring
Where searchNumFac corresponds to the value on the search box. The search on columns "numfac" and "nomsociedad" works great, but it fails on the $14 column. I also tried changing the $14 on the code by the column title on the Notes view (proveedor) and the column title on the XPage view (Proveedor), but it is still not working.
Do you know of any way to work around this?
Thanks a lot,
Carlos