GroveStreams
jlv private msg quote post Address this user
I am using the SmartThings integration to add data for a number of sensors (temperatures). I renamed the devices in SmartThings, and found that now I have new streams with the new names. Is there any way I can combine or merge the old data into the new stream (permanently)?
Post 1 IP   flag post
MikeMills private msg quote post Address this user
You'll have to use derivation.

1) Right click on the component and Edit it
2) Select the original stream and then the Derivation tab
3) Set the effective date to an early time
4) Set the derivation variable to be the new stream
5) Set the derivation expression to be var1
6) Save the component and wait a couple of minutes for all of the data from the new stream to be appended to the old stream
7) Edit the component again and select the old stream. Set derivation to None and set it's ID to the new new name on the General tab (the ID is used to determine which stream the data goes into). Delete the new stream and then save the component.
Post 2 IP   flag post
jlv private msg quote post Address this user
Thank you!

I went through that and that makes lots of sense. I didn't realize I could do such things.

However, what I originally wrote was incorrect: When I said I got new streams, I meant I got new components. E.g., my sensor was named "Iris Motion Sensor", which turned into a component named "Iris Motion Sensor" with a stream named "temperature". When I renamed the sensor, I got a new component with the new name, containing a new stream "temperature".

It looks like your instructions will let set the derivation variable to be the same named stream in the new component, though.
Post 3 IP   flag post
MikeMills private msg quote post Address this user
The feed from SmartThings will place the data into the component and stream with the passed in component and stream IDs. GS will set the name to the ID initially. You can rename things and it will not impact the feed since it is using the IDs.
Post 4 IP   flag post
2968 4 4
Log in or sign up to compose a reply.