Views: Export query into file¶
Plugin ID: eca_views_export
Available since: 1.0.0
Use a view to execute a query and save the results to a file. You can also save the results in a token.
Token results are complete entities, not field-configured output
When the option to store results in a token is enabled, the token contains a list of complete entity objects — not the formatted field output configured in the View. Field formatters, labels, rewritten fields, and display settings from the View have no effect on the token values. See the Views: Execute query documentation for details.
The exported file itself does use the View's display and field configuration as expected.
Fields¶
Store results also in a token?— config key:load_results_into_token-
Check this box to save the results to a token as well
Type:
checkbox· Required: no · Default:false Token name for file name— config key:token_for_filename-
Provide a token name where ECA will store the effectively used filename of the output. Please provide the token name only, without brackets.
Type:
textfield· Required: no · Default: empty string File name— config key:filename-
Sets the name of the file where the data will be exported. If left empty, the file name configured in the view will be used, or a random name otherwise.
This field supports tokens.Type:
textfield· Required: no · Default: empty string Name of token— config key:token_name-
Name of the token available after view execution. Contains an indexed list of elements that the view returns. Please provide the token name only, without brackets.
Type:
textfield· Required: no · Default: empty string View— config key:view_id-
Select the view from the list. The view will always return a list of complete entities.
When using the "Defined by token" option, make sure there is a token with this name: eca_views_export_view_idType:
select· Required: yes · Default: empty stringAllowed values depend on the configuration of the target site.
Value format: The machine name of a view on the target site.
Display— config key:display_id-
Write the view
display idto execute. Set as default to use the default view configuration.
This field supports tokens.Type:
textfield· Required: no · Default:defaultValue format: The machine name of a display within the selected view, for example default or page_1.
Arguments— config key:arguments-
Provide the values for contextual filters in the same order as they are defined in the view. Separate multiple values with the
/character.
This field supports tokens.Type:
textfield· Required: no · Default: empty string