Data Seeding via Canary Sender API
Is it possible to use the API to seed historical data from another historian? Following best practice, the API would write a different dataset but I have found when trying to use the Write API it will put the files in the current date, not the historical date. So if I use the create new file call Canary will also create a value with the current date so you are unable to write any previous dates. i.e. if I call storeData for 2017-08-16 in a file with that date, the historian will then create a single tag value on 2024-04-10 preventing me from storing data with the date 2017-08-17.
6 replies
-
Hi hmatuse ,
Unless the tag already has history and you're doing inserts, the Write API does not have the ability to seed data. It stores it in the current file like you said.
-
Hi hmatuse ,
I apologize. I need to retract my words. After discussing this with development, you can create historical files with the Sender API and you would use the /createNewFile function. I think the piece you are missing is the Roll-Over option within the historian. This is what is causing that current file to get created. If you go into the Historian>Configuration screen and select the dataset you are writing to, you want to turn the Roll-Over option to "Never". Essentially, you are going to now control when new files are created and when they are rolled over. You would need to use /createNewFile to start, then you would use /fileRollOver thereafter.
Sorry for the confusion.