Loading TOC...

MarkLogic 12 EA 2 Product Documentation
op.docColTypes

op.docColTypes() as rowColTypes

Summary

Provides the 3rd parameter for op.fromParam for row column types.

Example

declareUpdate();
const op = require('/MarkLogic/optic');
const rows =[
  {uri:'/optic/update/execute3.json', doc:{"doc":"execute3"}, collections:['execute', 'write'], quality:3, permissions:[xdmp.permission("rest-reader","read"),xdmp.permission("rest-writer","update")]},
  {uri:'/optic/update/execute4.json', doc:{"doc":"execute4"}, collections:['execute', 'write'], quality:4, permissions:[xdmp.permission("rest-reader","read"),xdmp.permission("rest-writer","update")]}
];
op.fromParam('bindingParam', null, op.docColTypes())
   .bind(op.as('metadata', op.jsonObject([op.prop('time', op.jsonString('2022-10-13T11:00:0'))])))
   .write()
   .execute({bindingParam:rows}, "trace=QueryFromParam");
  

Stack Overflow iconStack Overflow: Get the most useful answers to questions from the MarkLogic community, or ask your own question.