NUQL:OPTIONS
path: CHRISTIAN EYERMAN > CATEGORY:EDUCATION > MODERNIZATION PROFESSIONAL SERVICES > NUQL:COMMANDS > NUQL:OPTIONS

Nucleus Query Language

NUQL Options

The options designate the format of the output data tables.

  • B - Browse. Save a browse set of 20 items each that can be retrieved via the NUQL BROWSE command. (for option Q, sequential records only and forces SELECT mode so no locking occurs).
  • Bn - Where n is the number of items per browse page.
  • C - Correlated set of data in nuCSDynaSetTable.
  • J - JavaScript Object Notation (JSON)
  • M - MIME format in nuCSDynaSet
  • O - Use Optomistic Locking
  • Q - Sequential records in nuCSDynaSet
  • R - Reformat output to target file (internal format as sequential. Same as using REFORMAT NUQL command).
  • S - Use Soft Locking
  • V - Verbose. Show the internal process messages.
  • Z - force normalization of mv sets.
  • G - State enGine internal process. sets flag.InternalProcess. Modifies the action of ADD, INSERT, DELETE to work on internal items only and does not retrieve or update to the database. The CORRRELATIVE and VALIDATE commands are by deafult flag.InternalProcess = TRUE.
  • XML - Reformat output as XML and related formats (internal format as sequential).
  • XSL - Create the XML style sheet.

See Also

NUQL Modifiers

Examples

Extraction of data in the form of a correlated set ::

NUQL SELECT PARTS,SUM(QTY),SUM(EXT.PRICE) FROM SCR.INV GROUP-BY PARTS WHERE PARTS LIKE "N.%" (CV

The internal select process is as follows:

 

SELECT INV WITH PARTS LIKE "N.%"

3 Records selected

SSELECT INV BY-EXP PARTS LIKE "N.%"

5 Records selected

Generated Details as a correlated list:

PARTS]QTY]EXT.PRICE
N.101]N.201]N.201]N.301]N.310

1]1]1]1]1
295.00]795.00]295.00]795.00]295.00
NuQL Completed Successfully '5 records processed with 5 lines'

Note: In this format, the data set is arranged so that the first row corresponds to PARTS, the second row corresponds to QTY, and the third row corresponds to EXT.PRICE.

Extraction of data in MIME format ::

MIME means Multipurpose Internet Mail Extensions, and refers to an official Internet standard that specifies how messages must be formatted so that they can be exchanged between different email systems. MIME is a very flexible format, permitting one to include virtually any type of file or document in an email message. Specifically, MIME messages can contain text, images, audio, video, or other application-specific data.

Adding the "M"' option to the NuQL command line will output data in MIME format as:

NUQL SELECT PARTS,SUM(QTY),SUM(EXT.PRICE) FROM SCR.INV GROUP-BY PARTS WHERE PARTS LIKE "N.%" (MV
Open SCR.INV
err 10000

SELECT INV WITH PARTS LIKE "N.%"

3 Records selected
SSELECT INV BY-EXP PARTS LIKE "N.%"
5 Records selected

Generated Detail MIME Data Set:

PARTSÿQTYÿEXT.PRICE
PARTS=N.101&QTY=1&EXT.PRICE=295.00
PARTS=N.201&QTY=1&EXT.PRICE=795.00
PARTS=N.201&QTY=1&EXT.PRICE=295.00
PARTS=N.301&QTY=1&EXT.PRICE=795.00
PARTS=N.310&QTY=1&EXT.PRICE=295.00
NuQL Completed Successfully '5 records processed with 5 lines'

Extraction of data in XML format ::

Extensible Markup Language (XML) is a simple, very flexible text format derived from SGML (ISO 8879). Originally designed to meet the challenges of large-scale electronic publishing, XML is also playing an increasingly important role in the exchange of a wide variety of data on the Web and elsewhere. Of importance to those using Multi-dimensional databases, is the fact that XML provides a mechanism for the definition of "real-world" datasets as delimited, multi-dimensional data.

Adding the "X"' option to the NuQL command line will output data in XML format as:

NUQL SELECT PARTS,SUM(QTY),SUM(EXT.PRICE) FROM SCR.INV GROUP-BY PARTS WHERE PARTS LIKE "N.%" (XV
Open SCR.INV
err 10000
SELECT INV WITH PARTS LIKE "N.%"

3 Records selected
SSELECT INV BY-EXP PARTS LIKE "N.%"
5 Records selected

Generated Detail XML Data Set:

PARTSÿQTYÿEXT.PRICE

<ITEM>
<PARTS>N.101</PARTS><QTY>1</QTY><EXT.PRICE>295.00</EXT.PRICE>
</ITEM>
<ITEM>
<PARTS>N.201</PARTS><QTY>1</QTY><EXT.PRICE>795.00</EXT.PRICE>
</ITEM>
<ITEM>
<PARTS>N.201</PARTS><QTY>1</QTY><EXT.PRICE>295.00</EXT.PRICE>
</ITEM>
<ITEM>
<PARTS>N.301</PARTS><QTY>1</QTY><EXT.PRICE>795.00</EXT.PRICE>
</ITEM>
<ITEM>
<PARTS>N.310</PARTS><QTY>1</QTY><EXT.PRICE>295.00 </ITEM>
NuQL Completed Successfully '5 records processed with 5 lines'
Importing XML data into Multi-dimensional files ::

NuQL includes utilities to easily import XML formatted data into a Multi-dimensional environment. If the specified file does not exist, Nucleus will create the file, automatically build the dictionary definitions and convert the XML data into standard multi-dimensional file structures.