EcoStruxure Geo SCADA Expert Forum
Schneider Electric support forum about installation, configuration, integration and troubleshooting of EcoStruxure Geo SCADA Expert (ClearSCADA, ViewX, WebX).
Link copied. Please paste this link to share this article on your social media post.
Posted: 2019-12-16 06:57 AM . Last Modified: 2023-05-03 12:19 AM
Please how do i export HISTORICAL DATA from clearscada to a CSV file. I want it to be in form of a button, when the user wants to export he can click the button and inputs the period for which he wants to export the historical data. Please is this possible?
Link copied. Please paste this link to share this article on your social media post.
Posted: 2019-12-16 03:03 PM . Last Modified: 2019-12-16 03:05 PM
Link copied. Please paste this link to share this article on your social media post.
Posted: 2019-12-16 03:03 PM . Last Modified: 2019-12-16 03:05 PM
Sure, lots of ways, the best way really depends what you want to do with the CSV file afterwards
* Use the CSV Export driver, but may not be as flexible that you need
* Use logic, use VAR INPUT to define the time and %S to query the data from CDBHistoric, then use and FILE_WRITE() functions. This will store the file on the server and has the advantage that it can be both scheduled and manually triggered, but again lose some flexibility on defining the source point
* Use scripting on mimics. Use the Form object or similar to prompt for date inputs, Server.Query to get the data from CDBHistoric and create a COM object to fso to write files to the local workstation's disk. Probably lots more flexibility with this one but more coding required
Link copied. Please paste this link to share this article on your social media post.
Link copied. Please paste this link to share this article on your social media post.
Posted: 2019-12-19 02:19 AM
The issue about parameters - noted!
Filenames - you can use trip characters to add parts of the date/time stamp, e.g. %Ddd MMM yyyy% %THH:mm:ss%
Link copied. Please paste this link to share this article on your social media post.
Posted: 2019-12-16 03:03 PM . Last Modified: 2019-12-16 03:05 PM
Link copied. Please paste this link to share this article on your social media post.
Posted: 2019-12-16 03:03 PM . Last Modified: 2019-12-16 03:05 PM
Sure, lots of ways, the best way really depends what you want to do with the CSV file afterwards
* Use the CSV Export driver, but may not be as flexible that you need
* Use logic, use VAR INPUT to define the time and %S to query the data from CDBHistoric, then use and FILE_WRITE() functions. This will store the file on the server and has the advantage that it can be both scheduled and manually triggered, but again lose some flexibility on defining the source point
* Use scripting on mimics. Use the Form object or similar to prompt for date inputs, Server.Query to get the data from CDBHistoric and create a COM object to fso to write files to the local workstation's disk. Probably lots more flexibility with this one but more coding required
Link copied. Please paste this link to share this article on your social media post.
Link copied. Please paste this link to share this article on your social media post.
Posted: 2019-12-17 01:19 AM
I am new to clearscada, but i'm gonna try your 3rd option , i think it would work. Thanks!
Link copied. Please paste this link to share this article on your social media post.
Link copied. Please paste this link to share this article on your social media post.
Posted: 2019-12-19 01:28 AM . Last Modified: 2019-12-19 01:28 AM
The first option - the facility is called 'SQL Expert' - find the object in the Create ... New ... Other menu.
Any SQL can be written which exports that data in CSV (or tab) into a file. This can be scheduled or triggered from the client.
Note that option 1 may or may not work on WebX, and on Virtual ViewX will write a file on the web server.
(This thread should be in the Geo SCADA forum, but I don't see an option to move a thread. 🙂 )
Link copied. Please paste this link to share this article on your social media post.
Link copied. Please paste this link to share this article on your social media post.
Posted: 2019-12-19 01:58 AM
Yeah i have tried the SQL export, but its not as flexible as i want, the Client cannot specify the date range in which he wants to export the historical data and also, it doesnt save each export in a new CSV file, it overwrites the old one.
Link copied. Please paste this link to share this article on your social media post.
Link copied. Please paste this link to share this article on your social media post.
Posted: 2019-12-19 02:19 AM
The issue about parameters - noted!
Filenames - you can use trip characters to add parts of the date/time stamp, e.g. %Ddd MMM yyyy% %THH:mm:ss%
Link copied. Please paste this link to share this article on your social media post.
Link copied. Please paste this link to share this article on your social media post.
Posted: 2019-12-19 02:53 AM . Last Modified: 2019-12-19 02:58 AM
When i do this, does it export in a new csv file with the new time specification? Although i tried this format"%Ddd MMM yyyy% %THH:mm:ss%" and it kept giving me "Invalid OPC relative time for trip sequence", this was the format that worked e.g D-2D or H
Link copied. Please paste this link to share this article on your social media post.
Link copied. Please paste this link to share this article on your social media post.
Posted: 2019-12-19 02:55 AM
Yes, it creates a new file, leaving the old file in place.
You can use the time/date sequences in both file and folder names.
Link copied. Please paste this link to share this article on your social media post.
Link copied. Please paste this link to share this article on your social media post.
Posted: 2019-12-19 03:18 AM . Last Modified: 2019-12-19 03:22 AM
It worked!, so i used the %THH mm ss% format in the Output filename. It creates a new file now. Thanks! Prolly try to figure out how the client can specify the Date range he/she wants.
Link copied. Please paste this link to share this article on your social media post.
Link copied. Please paste this link to share this article on your social media post.
Posted: 2020-06-29 11:16 PM . Last Modified: 2020-06-29 11:17 PM
Hi, does this topic relate to https://www.se.com/ww/en/faqs/FA312272/
Also, does a .HRD / .csv file contain historic data relating to all points with historic data? I have not seen one of these files structure just yet.
(I notice, by week, yes?)
Thanks,
Link copied. Please paste this link to share this article on your social media post.
Link copied. Please paste this link to share this article on your social media post.
Posted: 2020-06-30 12:52 AM
While using the raw historic files is possible, I don't recommend this method for an application, just for diagnostic purposes.
Link copied. Please paste this link to share this article on your social media post.
Link copied. Please paste this link to share this article on your social media post.
Posted: 2020-12-05 09:38 AM
Hello Experts,
Can anyone share a sample SQL query for pulling out data from the database for two tags for a a time period .
I am kind of stuck at this portion.
Kindly share a sample code
Link copied. Please paste this link to share this article on your social media post.
Link copied. Please paste this link to share this article on your social media post.
Posted: 2020-12-05 04:47 PM
I won't give you the exact SQL Query... because learning to fish will be more rewarding.
If you find one of the points that you are interested in, and right click to bring up the context menu, there is an option called 'Display Historic List'. This will provide you with a List Window which will have the SQL Query to display the historical data for that point.
This is a good leap-pad into SQL queries in particular. There is also an entire 'Queries' pane available from the View Ribbon that is worthwhile looking at for any future queries that you might be interested in. You will almost always want to customise them in some way, but you can right click in the List Window (once you've selected a query) and select 'Edit Query' to see exactly what the SQL is. Then if you edit it and select OK the window will update with your new query expression shown.
Link copied. Please paste this link to share this article on your social media post.
Link copied. Please paste this link to share this article on your social media post.
Posted: 2020-12-05 04:48 PM
PS: In forums, unless you have extra information to add to a particular thread (i.e. a solution, or additional context to the problem the original poster encountered etc), you should be creating a new thread with your new problem / question to ask.
Link copied. Please paste this link to share this article on your social media post.
Link copied. Please paste this link to share this article on your social media post.
Posted: 2021-01-29 09:53 AM
Thank you for the lead.
I finally made it using the method mentioned.
Created from and to date picker and finally exported it as CSV.
Link copied. Please paste this link to share this article on your social media post.
Link copied. Please paste this link to share this article on your social media post.
Posted: 2021-02-05 03:03 AM
Please can you share your steps/procedure with me, i am still having issues on this. Thank you
Link copied. Please paste this link to share this article on your social media post.
Link copied. Please paste this link to share this article on your social media post.
Posted: 2021-10-21 10:58 PM
hi, how about this topic, did you have solved your problem ? i have same problem here. thank you if you can share step by step how to export to CSV
Link copied. Please paste this link to share this article on your social media post.
Link copied. Please paste this link to share this article on your social media post.
Posted: 2021-10-22 01:43 PM
You should post this as a new thread/topic, and detail what you have tried already.
If you search in the Geo SCADA Expert online help for "export CSV" then you should get some hits to follow up on learning more about.
As Geo SCADA Expert provides numerous ways to perform such requirements, you would need to consider which is the most suited for your needs, and research more on it.
Link copied. Please paste this link to share this article on your social media post.
Link copied. Please paste this link to share this article on your social media post.
Posted: 2021-11-18 02:26 AM
Hi Please, can you share a sample program on how you did this?
Link copied. Please paste this link to share this article on your social media post.
Create your free account or log in to subscribe to the board - and gain access to more than 10,000+ support articles along with insights from experts and peers.