Hello,
I'm having a problem with the tag history and audit features.
What I'm trying to do is to create a view with a simple table and custom filter that will allow the users to visualize every change on the application, that means every tag change from the user or from the OPC tag, audit action,...
I've tried to do that with the native function of Ignition with the Tag History property, by getting all the data with a Tag History binding, but I think there is too much data; the CPU is overwhelmed and I end up restarting the gateway every time.
The table should look like this, with every user action + tag change from users or from OPCtag
Is there a way to get all the data from the native Tag History function so that I could display all the History and Audit data together?
Or maybe, is it possible to store on the Audit every tag change? Included from OPCTag that we receive?
The data are supposed to be stored for 6 months and I need to be capable of filtering from that data on the table view directly, I can't just limit the data on the table if I want to be able to do that
Thanks
How many rows of data are you expecting to be returned? Are you trying to load more data into memory than Ignition has available?
This is an unrealistic expectation. You should substitute a zero-length timespan any time the selected timespan is too large for your system to handle (determined experimentally).
Consider using a short tag history time window of 5 minutes before and after a selected audit event.
On the view in the table component I will have 2500 rows max, but the filtering is supposed to be on all the data from now to 6month maximum. And same thing for the Audit, we must be able to filter up to 6 months max.
I forgot to mention that I have over 21k tags that are historized. I figured this might be the problem but can't found any solution for this case with the native Tag History Fonction
What exactly are you trying to filter on? You can still filter your results on the raw data itself, but you must do this in the query, not using the table's filter. Even pulling in the raw samples for a day of a single tag's history can overwhelm the table component, given the right history logging conditions. You could be pulling in 10s of thousands of results per tag per day. It's completely unfeasible to query for this all at once over 6 months. Logging at 1s per tag, that's 362,880,000 records, add to that your audit log records and the alarm records 
The user will be able to filter from a startDate to an endDate; there will be one textField for each column so that he can search for specific data in this column. Those will be custom filter of course that will query on the table custom props that will get both History and Audit data.
So I guess the tag history binding isn't possible for this case ? I don't see how can I do this
You're going to need to setup your tag history query to requery when the user's selected filters change. As Nick said, trying to table filter that much data is not going to work in the long-term.
And really, if you are looking to handle that much data and do some sort of intensive analysis, you need to be looking at dedicated Data Analytics tools.
These are independent tables. The tag query functions don't query on audit data (or alarm history data for that matter), so you would need to run these queries independently and combine the results yourself.