Community Tip - Have a PTC product question you need answered fast? Chances are someone has asked it before. Learn about the community search. X
I have a Thing and valuestream associated to that. Have made properties of that thing logged and persistent so that I can use valuestream for time series. I'm able to get the same in a mashup.
If I wanted to write a service which will perform the same function as an export widget in a mashup, I would be able to invoke service every x mins to export the property history to csv
Thanks in advance
Solved! Go to Solution.
Or else you can try using the service "WriteCSVFile" from available snippet .It is like this -
var params = {
path: undefined /* STRING */,
data: undefined /* INFOTABLE */,
fileRepository: undefined /* THINGNAME */,
withHeader: undefined /* BOOLEAN */
};
// no return
Resources["CSVParserFunctions"].WriteCSVFile(params);
It takes data as an infotable which will be coming from the "QueryPropertyHistory" so you can pass that infotable to this service and write this to CSV in repository .
Hello, I think you could use the service in Data Export Extension, the entity it includes have service to help infotable exported as CSV file.
Or else you can try using the service "WriteCSVFile" from available snippet .It is like this -
var params = {
path: undefined /* STRING */,
data: undefined /* INFOTABLE */,
fileRepository: undefined /* THINGNAME */,
withHeader: undefined /* BOOLEAN */
};
// no return
Resources["CSVParserFunctions"].WriteCSVFile(params);
It takes data as an infotable which will be coming from the "QueryPropertyHistory" so you can pass that infotable to this service and write this to CSV in repository .
Thank you. This worked
Arvind