4.26. export
Exports a database to a delimited text file (see also import).
4.26.1. Summary
[export table other_named_attributes]
Parameters | Description | Default |
base | Alias for table | DEFAULT_VALUE |
database | Alias for table | DEFAULT_VALUE |
delete | If 'verify' attribute also set, deletes column specified by 'field' attribute rather than adding a column. | DEFAULT_VALUE |
field | The column to add (or delete if delete and verify are true) | DEFAULT_VALUE |
file | Filename to export to. Note that the NoAbsolute directive and other conditions may affect actual location of the output file. | DEFAULT_VALUE |
sort | Output sorted rows (usage: sort="sort_field:sort_option") (see search/form variable 'mv_sort_option' for sort options) | DEFAULT_VALUE |
table | The table to export | DEFAULT_VALUE |
type |
Specifies the [line, record] delimiter types. Either NOTES or one of the following:
my %Delimiter = ( 2 => ["\n", "\n\n"], 3 => ["\n%%\n", "\n%%%\n"], 4 => ["CSV","\n"], 5 => ['|', "\n"], 6 => ["\t", "\n"], 7 => ["\t", "\n"], 8 => ["\t", "\n"], LINE => ["\n", "\n\n"], '%%%' => ["\n%%\n", "\n%%%\n"], '%%' => ["\n%%\n", "\n%%%\n"], CSV => ["CSV","\n"], PIPE => ['|', "\n"], TAB => ["\t", "\n"], );
|
DEFAULT_VALUE |
verify | must be true when deleting a column | DEFAULT_VALUE |
Attributes | Default |
interpolate (reparse) | No |
Other_Characteristics | |
Invalidates cache | YES |
Container tag | No |
Has Subtags | No |
Nests | Yes |
Tag expansion example:
[export table] --- 1
ASP-like Perl call:
$Tag->export( { table => VALUE_table }, $body );
or similarly with positional parameters,
$Tag->export(table, $attribute_hash_reference, $body);
4.26.2. Description
Exports 'table' to a delimited text file. See also import tag which imports files into databases.
4.26.2.1. delete
If 'verify' attribute also set, deletes column specified by 'field' attribute rather than adding a column.
4.26.2.2. field
The column to add (or delete if delete and verify are true)
4.26.2.3. file
Filename to export to. Note that the NoAbsolute directive and other conditions may affect actual location of the output file.
4.26.2.4. sort
Output sorted rows (usage: sort="sort_field:sort_option") (see search/form variable 'mv_sort_option' for sort options)
4.26.2.5. table
The table to export
4.26.2.6. type
Specifies the [line, record] delimiter types. Either NOTES or one of the following:
my %Delimiter = ( 2 => ["\n", "\n\n"], 3 => ["\n%%\n", "\n%%%\n"], 4 => ["CSV","\n"], 5 => ['|', "\n"], 6 => ["\t", "\n"], 7 => ["\t", "\n"], 8 => ["\t", "\n"], LINE => ["\n", "\n\n"], '%%%' => ["\n%%\n", "\n%%%\n"], '%%' => ["\n%%\n", "\n%%%\n"], CSV => ["CSV","\n"], PIPE => ['|', "\n"], TAB => ["\t", "\n"], );
- If using NOTES
- notes_separator (defaults to "\f")
- notes_field (defaults to "notes_field")
4.26.2.7. verify
must be true when deleting a column