I want to connect to use pi sdk to pi buffer subsystem.
How do I connect?
How can delete data(pipoint , tag) and snapshot on a pi buffer subsystem?
To enable PI SDK buffering, use About-PISDK and navigate to PI SDK Buffering. Once the PI SDK Buffering Configuration window is opened, you can enabled PI SDK Buffering and select the PI system. You will have to start/restart the PI buffer subsystem for this to take into effect. For more information, you can refer to KB00572. Note that you need PI SDK 1.4 or later and PI Buffer Subsystem 3.4.380 or later.
When you then start your PI SDK application, it should get registered under the PI Buffer Subsystem and data should then be fanned the PI server/collective through PI Buffer Subsystem. You can then check buffering registration by running “pibufss -creg" after navigating to %pihome%\bin in the command prompt to confirm that your application is successfully registered.
Note that certain PI SDK functions (e.g. IPIData.RemoveValues) do not get buffered. If you have a collective, you will have to explicitly open a connection to each member of the collective and delete data.
Thank you for the answer.
But I want to know that is it possible to get and remove data from PI Buffer Subsystem using PI SDK.
If it's possible to do that, please let me know which function of PI SDK should I use?
There is no need to use the PI Buffer Subsystem to get data since its main purpose is to hold data to the PI Data Archive in case the PI Data Archive goes down. To get data using PI SDK, there are several functions that you can use depending on your needs. An example is
RecordedValues Method (PIData object)
if you want to get compressed values for a certain time range. Most of these methods belong to the PIData object. For more information you can refer to the PI SDK reference that is available at %pihome%\help when you install the PI SDK.
To remove data from the PI Data Archive, as Daphne mentioned above, the function IPIData.RemoveValues is not buffered as well.
Therefore, in conclusion, you do not need to use the PI Buffer Subsystem to get or remove data. You need it just to send data to the PI Data Archives.
PI SDK can add, delete, edit values but these actions work for PI Snapshot subsystem or PI Archive Subsystem.
If you use PI SDK Buffering, PI SDK's add and edit events are buffered.
Delete events are not buffered as Dephne described. Please check KB00572.
KB00572 - PI SDK Buffering: Benefits, installation, configuration and other FAQs
The following PI SDK methods are not buffered therefore event deletes are not buffered and event edits are only buffered via the UpdateValue and UpdateValues methods. For more information, please see the UpdateValue and ReplaceValue methods in the PI SDK Help file.
PI Buffer Subsystem is just sending values and if the PI Server does not accept values, PI Buffer Subsystem stocks these values in PI Buffer Subsystem's queue file.
Unfortunately, it is not possible to edit or delete values from queue file.
Normaly we could not delete PI Buffer Subsystems queue file but if you stop pibufss and delete queue file, it deletes queue file's events.
Hi, just to add on, edit events are buffered if sent via UpdateValue. However, it will not be buffered if sent via ReplaceValue. The UpdateValue method compares only timestamps when determining which event to modify. If there are several events with the same timestamp, they are considered identical. With ReplaceValue the caller can select between events with the same timestamp but different values.
Looking at the replies to your question, my feeling is that your question has been answered. Please allow me marking your question as a "assumed answered".
Because we don't like to leave any question "open" and reflecting this with a questions status is extremely helpful. Optimally, please mark the "correct answer" to your question which makes it even easier for other users with the same question to find the correct answer.
Retrieving data ...