ScadaClient.GetSlice Forum Home › Forums › Development and Integration › ScadaClient.GetSlice This topic has 7 replies, 2 voices, and was last updated 1 year, 8 months ago by Zeus. Viewing 8 posts - 1 through 8 (of 8 total) Author Posts December 18, 2022 at 8:46 am #11779 ZeusParticipant Hi, I use ScadaClient to get slice data from influxdb ScadaClient.GetSlice(ArchiveBit.Minute, DateTime.UtcNow.AddMinute(-1), new int[] { 101 }) and it returns scadadata undefined stat 0 val 0 December 19, 2022 at 7:25 am #11787 MikhailModerator Hi, Every execution of the above code a client requests different data points. Probably, they don’t exists. Try specifying particular timestamp. January 25, 2023 at 11:11 am #12013 ZeusParticipant Hi, I save data into influxdb per secend. How can i get cnl data an hour ago. January 26, 2023 at 11:19 am #12020 MikhailModerator Hi, Could you clarify the question? January 26, 2023 at 1:39 pm #12021 ZeusParticipant Hi, I use influxdb storage history data. I can use api GetTrend and GetCurrentData get data from influx. When i use getslice ScadaClient.GetSlice(ArchiveBit.Minute, DateTime.UtcNow.AddMinute(-1), new int[] { 101 }) it returns scadadata undefined stat 0 val 0 the influxdb has cnl 101’s data every secend. If i want to get cnl 101’s data at “DateTime.UtcNow.AddMinute(-1)”. how can i make it? January 27, 2023 at 8:46 am #12033 MikhailModerator Hi, To get a slice, you need to specify the exact timestamp. There is a very low chance that data exists exactly at DateTime.UtcNow.AddMinute(-1). To be able to get slices, you should write data with a period. And specify the exact timestamps that fits the writing period. January 27, 2023 at 8:47 am #12034 MikhailModerator May be we should add a method to get values closest to the specified timestamp. January 28, 2023 at 5:17 am #12039 ZeusParticipant OK I will try Author Posts Viewing 8 posts - 1 through 8 (of 8 total) You must be logged in to reply to this topic. Log In Username: Password: Keep me signed in Log In