Skip to content. | Skip to navigation

You are here: Home Setting Up and Maintaining Your Organization Weather Station Administration Importing Weather Data from Other Sources

Importing Weather Data from Other Sources

It is also possible to import weather data using the channel data importer.   Data formats are very flexible.  Here’s an example of an Excel file format:

 

 

interval_sample.jpg

 

Column A. Weather Station Import ID– this value must appear in Weather Station Properties – Specific – Import ID.

 

wthr22.jpg

 

Column B. Date
Column C. Time (11:00 am is a reasonable default value)
Column D. Mean daily temperature
NOTE: Either separate columns for Date and Time (as in this example), or a single column for a Timestamp (ie – 2006-11-14 11:00), can be used.
To import:
  1. From the Weather Station Manager, select File > Import. The Open window will appear.
  2. Browse to the data file and click to select it. Then click Open.. The Import Wizard window will open.
    import1a.jpg
  3. Follow the Wizard prompts to create a new import profile. Or select an existing profile previously created for that file and data type.

import1.jpg

Column 1 (DEVICE) is the Weather Station three-letter ID. Column 2 is the DATE, in MM/dd/yyyy format. Column 3 is the TIME in HH:mm format. Column 4 is the DATA value.
import2.jpg

Importing Weather Data using an external task

It is also possible to import weather data using the Import Task [imptsk] function from the command line. Here is an example and explanation of each element:

The usage is:

imptsk -d [dsn] -u [user] -p [pwd] -c [converter] -f [path] -x -a [path] -l [path] -s [section] -v [verbose messages] -remote -t [traceID]

Where:

  • -d [dsn] is the ODBC data source name
  • -u [user] is the system user id
  • -p [pwd] is the system password
  • -c [converter] is the name of the converter
  • -f [path] is the file to be imported
  • -x will delete the input file after importing the data
  • -a [path] will archive the data to the path specified
  • -l [path] is the log file
  • -s [section] is the profile section name
  • -v [message text] when used, will add additional detail to the import log file.
  • -remote is the command to connect to the HTTP data provider (use in conjunction with the -d switch, which identifies the Datasource from the Catalog Server (as displayed in the EnergyCAP Login window)
  • -t [traceID] is the SQL server trace to initiate during verification

 

EXAMPLE: "c:\Program Files\EnergyCAP Enterprise\imptsk.exe" -d retailer -u kvs -p kvs -c STANDARD:SIMPLE_TEXT -f "c:\b-test\*.csv" -l "log.txt" -s MY_CHANNEL_PROFILE_NAME

  • "c:\Program Files\EnergyCAP Enterprise\imptsk.exe” – This is the file path for the importer program, imptsk.exe. It is typically located in your Energy CAP Enterprise program folder. Be sure to enclose the file path in quotation marks. IMPORTANT - You must execute the command from the EnergyCAP program folder, i.e. log onto this folder before executing the imptsk.exe file. Simply pointing to the program folder from another location may cause the imptsk.exe program to be unable to run required supporting DLL files.
  • -d retailer - This is the name of the database into which you wish to import the data.
  • -u kvs – This is the User ID with which you wish to import the data. The User ID is the username you use to login to EnergyCAP Enterprise. Be sure adequate permissions exist to create the records.
  • -p kvs - This is the password associated with User ID you are using to import the data.
  • -c STANDARD:SIMPLE_TEXT – If you follow the format for the weather data in this technical bulletin, this is the converter you will use.
  • -f "c:\b-test\*.csv" – This is the file path for the .csv document which you wish to import into EnergyCAP Enterprise.
  • -l "log.txt" – The Importer creates a log file that tracks the changes made to EnergyCAP Enterprise. This is the file path to the location where that file will be saved.
  • -s "MY_CHANNEL_PROFILE_NAME" - This is the name for the weather profile you have created.
Add comment
(Required)
Tell us your name.
(Required)
(Required)
(Required)
Enter the word