Page tree
Skip to end of metadata
Go to start of metadata

pjs.ds() returns a data structure reference. It is mainly used with  Record Level Access and User Interface API to store the resulting buffer into a data structure.

  1. Name of a data structure
Return Value

This function will return a JavaScript object with two properties:

  • name - the name of the data structure passed in
  • fieldsArr - array of field scopes
pjs.defineTable("productsp", { read: true, keyed: true, levelIds: [ '4AFA8C636F' ] });
pjs.define("myDs", { 
  type: 'data structure', 
  likeRec: 'products' 
pjs.define("data", { type: 'char', length: 50, varying: true });

productsp.getRecord([114], false, null, pjs.ds("myDs"));
if (productsp.found()) {
  data = pjs.char(myDs.prid);