Changes

Jump to navigation Jump to search
179 bytes added ,  17:48, 26 October 2017
* The column names will be available if {{Code|header}} option is set to {{Code|true}}.
Rows in the The resulting records sequence data can be accessed with positional predicates, and columns can be accessed via the as follows:
* <code>$csv?records[25]</code> returns all entries of the second 5th record (row)* <code>$csv?records(2)</code> returns all entries of the second 2nd field (column)* <code>$csv?names?*</code> returns the names of all fields (if available)* Return string representation for each record '''Query:'''<pre class="brush:xquery">for $record at $pos in $csv?recordsreturn $pos || ". " || string-join($record?*, ', ')</pre>
The resulting representation consumes less memory than XML-based formats, and values can be directly accessed without conversion. Thus, it is recommendable for very large inputs and for efficient ad-hoc processing. Before {{Version|9.0}}, a {{Code|map}} format was available, which was now replaced with the more flexible and light-weight {{Code|xquery}} format.
Bureaucrats, editor, reviewer, Administrators
12,235

edits

Navigation menu