Skip to main content

Ever wanted to include data from external sources in your TrendMiner analysis?

The Tag Builder Data Import functionality allows you to do just that! This post will equip you with some helpful tips and tricks to ensure a smooth data import experience.

Getting Started

  • Supported File Format: Only CSV (comma-separated values) files are supported for data import. Make sure your data is formatted correctly before proceeding.
  • File Requirements:
    • File Extension: Ensure your file has the proper .csv extension.
    • Encoding: Use UTF-8 encoding for your CSV file.
    • File Size: The maximum file size supported is 45 MB.

Data Formatting

  • First Row: List the tag names you want to appear in TrendMiner in this row (Column 2 onwards). These names must be unique.
  • Second Row: Descriptions for each tag can be added in this row, but are optional (Column 2 onwards).
  • Third Row: Specify the units of measurement for each tag in this row, but are optional (Column 2 onwards).
  • Fourth Row: Define the tag type (analog, discrete, or string) in this row (Column 2 onwards).
    • Analog: Used for numerical values with linear interpolation.
    • Discrete: Used for numerical values with stepped interpolation.
    • String: Used for text values with stepped interpolation.
  • First Column: This column contains timestamps for your data points. The timestamps should be formatted as YYYY-MM-DDTHH:MM:SS±timezone (e.g., 2022-01-01T15:05:00+01:00). TrendMiner uses UTC by default if no timezone is specified.
  • Data Column (Second Column onwards): This column contains the actual data points for your tags. You can leave certain entries blank; TrendMiner interpolates only the timestamps with values.
Figure 1: Example of csv file format

Additional Tips

  • Example file: You can download a template csv file here.
  • Using the right format: Depending on your language setting a csv file will either use a comma “,” or a semicolon “;” as delimiter. It is important that you use a comma as delimiter and a point “.” as decimal seperator.

 

Do you have any questions or further tips to share about using Tag Builder Data Import? Leave a comment below!

Quick addition that addresses a common issue when importing:

If you ever get an error saying "No tags imported: tag name cannot be empty", while your file looks completely fine, you most likely have an empty column in your file. If you would open the file in a text editor (as opposed to a spreadsheet application), you would see your rows ending with a double comma.

I found the most robust and least frustrating way of getting rid of these empty columns is to simply copy the actual columns over to a new file, and then to import that new file.

 


It would be beneficial to be able to append new data to an existing tag or set of tags via the CSV uploader in order to extend the already existing data of a tag or the set of tags. Currently the tag’s data gets overwritten each time one performs a CSV upload.


Hi Emil,
Thank you for the reply, it is possible at the moment to append new data to an existing tag if you also append your original CSV file. However I also agree with you that it would be a great feature to be able to extend existing imported tag without extending the original csv file. Feel free to post it as a feature request here on the community.


Reply