Skip to main content
19-Tanzanite
November 30, 2016
Question

Get specific data from Value stream

  • November 30, 2016
  • 8 replies
  • 5639 views

Hi,

I have created a thing with 4 property S1 , S2, S3 & TC from hardware device. Am logging the data to my value stream. Now I have to extract particular data using timestamp.

For Ex: S1 S2 S3 and TC are Count of a product per day. In mashup when I select date using widget, Count for that particular date should be displayed in using ValueDisplay/ LED widget. Help me with this.

Regards,

Vel

8 replies

5-Regular Member
November 30, 2016

If you look under "Snippets" in the Services Editor, you can find one called "Create query for Stream". Select the stream name, and then add a timestamp filter. Pass the timestamp in as a parameter, import this service into a mashup, and bind everything as needed. Hope this helps!

1-Visitor
October 17, 2017

Hi Tori,

I was trying to implement similar but I can't find my ValueStream in stream name list. What else I should do to achieve the same ?

Regards,

Neety

5-Regular Member
October 17, 2017

valuestream and stream are 2 different entity types.. while valuestream stores timeseries data, stream gives you capability to create your own data structure...

for your case all you have to do is look at the basetype of your defined property (ex:NUMBER, STRING etc) and then use the corresponding Queryservice available on your Thing (or ThingTemplate) depending on what your mashup needs... for instance if the basetype is Number then there is a service called QueryNumberPropertyHistory... you just have to pass property name and timestamp and it will return the required values...

Velkumar19-TanzaniteAuthor
19-Tanzanite
December 3, 2016

Hi Tori,

I tried to do that, the problem in that snippet I need to select thing but I cant find my thing.

5-Regular Member
December 5, 2016

Are you able to find the thing using the spotlight search field?

5-Regular Member
January 17, 2018

do you still need help with this or the answer I gave above in the thread solves your problem ?