MarkLogic Server 11.0 Product Documentation
op.viewCol

op.viewCol(
   viewName as String,
   colName as String
) as columnIdentifier

Summary

Identifies a column where the combination of view and column name is unique. Identifying the schema isn't necessary (and it might not exist).

If the combination of view and column name is not unique, an ambiguous column error is thrown.

Parameters
viewName The name of the view.
colName The name of the column.

Example

const op = require('/MarkLogic/optic');

op.fromView('main', 'employees')
	      .orderBy(op.viewCol('employees', 'EmployeeID'))
	      .result();
  
Powered by MarkLogic Server | Terms of Use | Privacy Policy