Incorrect array length in archive

Find and share HowTos to various installations / configurations!
3 posts • Page 1 of 1
aorange
Posts:147
Joined: Thu Nov 04, 2010 10:07 am

Incorrect array length in archive

Post by aorange »

I have another question for this great community :)

I created a dpType in my project which has a number of DPE's of types dyn_string and dyn_int... there is a scheduled function that writes to these once a day and I need to be able to see what was written yesterday, the day before and so on. Sounds simple but, the problem is that when I retrieve the values from the archive, the array lengths are not consistent with what was in the original value of the datapoint.

For example, yesterday I could observe that all DPEs had an array length of 217 - when I retrieve the values from the archive today however, I can see that some of the arrays have been split where there were empty lines. For example most of the DPEs will have a single value in the archive (with a length of 217) but some will have been split into two or more where there were empty lines in the arrays and archived as separate values.

Is this normal? I can think of a way to work around it by writing at least a couple of characters into the arrays where there are empty spaces but... its just strange. Seems like a bug to me.

leoknipp
Posts:2928
Joined: Tue Aug 24, 2010 7:28 pm

Re: Incorrect array length in archive

Post by leoknipp »

Hello,

I made a test with dyn_string-elements and archiving in the value-archives.
The values have been stored correctly in the archive. When reading the values the correct result was returned.

From your description I cannot identify where the "empty lines" are displayed or how you get information that the dyn-element was split into several entries.

To be able to analyze the problem we need more detailed information. Therefore please open an official support request including the following information:
-- used WinCC OA version
-- installed operating system
-- type of archiving (HDB, RDB)
-- example which values have not been saved correctly: returned result compared to the expected result

Best Regards
Leopold Knipp
Senior Support Specialist

aorange
Posts:147
Joined: Thu Nov 04, 2010 10:07 am

Re: Incorrect array length in archive

Post by aorange »

Thanks Leopold, I will open a support ticket for this... I am seeing the same behaviour on other dyn type DPEs.

The empty lines are in the DPE itself, for example;

A dyn_string containing 7 elements as per below will be archived as two values
[1] abc
[2] def
[3] ghi
[4] jkl
[5]
[6] mno
[7] pqr

a dpGetPeriod() for the DPE will return 2 values, one containing (abc, def, ghi, jkl) and another containing (mno, pqr) as if we had done two separate dpSet()

3 posts • Page 1 of 1