Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.

...

What

nameofinstance.xml

Required

no

Description

Export data (timeseries) from Delft-Fews to several file formats

schema location

httphttps://fewsfewsdocs.wldelftdeltares.nl/schemas/version1.0/timeSeriesExportRun.xsd


Excerpt
hiddentrue

Exports data to several file formats

...

This elements describes how to construct the filename(s) of the exported file(s).Image Removed

Image Added

If only the name element is given a fixed name is used for each export. The prefix and suffix elements describe how to create a filename prefix and/or suffix. The temporaryPrefix is used to generate a prefix for the temporary file as it is being written. After that the file is renamed.

The option useExternalLocationIdAsName (instead of the regular file name) forces the use of the location ID or Name as filename. Note that this option does not work in combination with an idMap that filters the locations to be exported.


validate

Optional element. Only applicable if the data are exported to the xml-file. This option activates the validation of the exported file against a XML schema.

...

Id of IdMap to be used for parameterId and locationId mapping

unitConversionsId

externalLocationNameFunction (since Delft-FEWS 2023.2)

For export functions that can write location names along side location ID's, one can choose the location attribute that should be parsed to the location name field. It requires mentioning the attribute between @ signs; e.g.: <externalLocationNameFunction>@externalLocationName@</externalLocationNameFunction>


unitConversionsId

Id of UnitConversions to be Id of UnitConversions to be used for unit mapping

flagConversionsId

...

If set to true records with missing values are not exported

exportLastValue

If set to true only the last value will be exported

precision

Available since 2018.02. Optional element to set the number of decimals all values should be displayed with. If set, additional zeros will be appended and/or values will be rounded when necessary. 

...

If used, only manual changed to the data will be exported. Unless the manualDBChangeViewPeriod is used, the relativeViewPeriod from the associated timeSeriesSet is used.
Image Removedis used. Note:  the view period is calculated relative to the dispatch time and not T0
Image Added

exportChanges

If configured,  any  changes to the data in the configured period will be exported. Unless the dbChangeViewPeriod is configured, the relativeViewPeriod from the associated timeSeriesSet is used . Note:  the view period is calculated relative to the dispatch time and not T0

An example:

Code Block
<general>
    <exportType>PI</exportType>
    <folder>$EXPORT_FOLDER$</folder>    
    <exportFileName>
        <name>exportedTimeSeries.xml</name>
    </exportFileName>
    <exportChanges>
         <dbChangeViewPeriod unit="day" multiplier="2"/> 
    </exportChanges>
</general>



columnSeparator and decimalSeparator

...

Optional metadata that is written in the exported file. The options netcdfMapDPhase and alertMapDPhase are deprecated (do not use these). For the other options it is possible to use the following tags:
%TIME_ZERO% the T0 of this time series export run.
%CURRENT_TIME% the current time.
%COLD_STATE_TIME% the cold state time.
%FORECAST_END_TIME% the forecast time set by the forecast length estimator or the forecast length option in the manual forecast dialog
%MODULE_INSTANCE_ID% the id of this module instance.
%MODULE_INSTANCE_NAME% the name of this module instance.
%MODULE_INSTANCE_DESCRIPTION% the configured description of this module instance.

%MODULE_INSTANCE_ATTRIBUTE(attributeId, moduleInstanceId)% moduleInstanceId is optional. When not specified the module instance of the module itself is used, like for the %MODULE_INSTANCE_ID% tag.
%WORKFLOW_ID% the id of the workflow in which this export runs.
%WORKFLOW_NAME% the name of the workflow in which this export runs.
%WORKFLOW_DESCRIPTION% the configured description of the workflow in which this export runs.

...

%COLD_STATE_TIME(yyyy/MM/dd HH:mm:ss z)% - the cold state start time. If data is unavailable it will be filled as "Unknown".


Since 2022.02 location/parameter/qualifier/moduleInstance attributes between @ are also recognized.

Configuration example of metadata:

Code Block
<metadata>
	<title>title</title>
	<institution>  institution  </institution>
	<source>source</source>
	<history>Exported at time zero = %TIME_ZERO(yyyy/MM/dd HH:mm:ss z)% in module instance %MODULE_INSTANCE_ID% as part of workflow %WORKFLOW_NAME% by user %USER_ID%.</history>
	<references>references</references>
	<comment>The actual time of writing was %CURRENT_TIME(yyyy-MM-dd HH:mm:ss z)%</comment>
	<summary>A summary of the data<data for @ATTRIBUTEID@</summary>
	<keyword>keyword1</keyword>
	<keyword>  keyword  with  lots  of  spaces  </keyword>
	<keyword>keyword 3</keyword>
	<customAttributes>
		<string key="emptyAttribute" value="    "/>
		<int key="  custom2  " value="123456"/>
		<string key="custom_3" value="This is a custom attribute with 'quotes' in it."/>
		<string key="    " value="attribute with empty key specified is not written"/>
		<float key="just_another_float" value="3.5"/>
		<bool key="truth" value="true"/>
	</customAttributes>
</metadata>

...