State_Trail From Database. Is Combine Similar States Irrelevant or am I making some mistake? (Solved)

The Output of the State-trail generated by a query from MySQL data base, is not giving From and To Time considering the Combine Similar States. My input is series of timestamp of one minute interval and states true or false . I have made the combine similar states active, and Graph Appears well on dashboard, (without any small lines). but when i click a segment, the output is always of one minute interval.. does the combine similar states not work if not done in real time update ?

image

image

Can I have a bit of sample data to investigate?

I am afraid, i dont know how to share sample data ? Would a CSV file do ?

image

i have put the output of the SQL Query node into a function node and pasted here, would that work ?

[
    {
        "id": "f438e6e387cf3b83",
        "type": "function",
        "z": "d61efe6293a02ec4",
        "name": "",
        "func": "[{ \"state\": \"FALSE\", \"timestamp\": 1637224151000 }, { \"state\": \"FALSE\", \"timestamp\": 1637224090000 }, { \"state\": \"FALSE\", \"timestamp\": 1637224030000 }, { \"state\": \"FALSE\", \"timestamp\": 1637223970000 }, { \"state\": \"FALSE\", \"timestamp\": 1637223910000 }, { \"state\": \"FALSE\", \"timestamp\": 1637223850000 }, { \"state\": \"FALSE\", \"timestamp\": 1637223790000 }, { \"state\": \"FALSE\", \"timestamp\": 1637223730000 }, { \"state\": \"FALSE\", \"timestamp\": 1637223370000 }, { \"state\": \"FALSE\", \"timestamp\": 1637223310000 }, { \"state\": \"FALSE\", \"timestamp\": 1637223250000 }, { \"state\": \"FALSE\", \"timestamp\": 1637223190000 }, { \"state\": \"FALSE\", \"timestamp\": 1637223130000 }, { \"state\": \"FALSE\", \"timestamp\": 1637223070000 }, { \"state\": \"FALSE\", \"timestamp\": 1637223010000 }, { \"state\": \"FALSE\", \"timestamp\": 1637222950000 }, { \"state\": \"FALSE\", \"timestamp\": 1637222890000 }, { \"state\": \"FALSE\", \"timestamp\": 1637222830000 }, { \"state\": \"FALSE\", \"timestamp\": 1637222590000 }, { \"state\": \"FALSE\", \"timestamp\": 1637222530000 }, { \"state\": \"FALSE\", \"timestamp\": 1637222470000 }, { \"state\": \"FALSE\", \"timestamp\": 1637222410000 }, { \"state\": \"FALSE\", \"timestamp\": 1637222350000 }, { \"state\": \"FALSE\", \"timestamp\": 1637222290000 }, { \"state\": \"FALSE\", \"timestamp\": 1637222230000 }, { \"state\": \"FALSE\", \"timestamp\": 1637222170000 }, { \"state\": \"FALSE\", \"timestamp\": 1637222110000 }, { \"state\": \"FALSE\", \"timestamp\": 1637222050000 }, { \"state\": \"FALSE\", \"timestamp\": 1637221990000 }, { \"state\": \"FALSE\", \"timestamp\": 1637221930000 }, { \"state\": \"FALSE\", \"timestamp\": 1637221870000 }, { \"state\": \"FALSE\", \"timestamp\": 1637221810000 }, { \"state\": \"FALSE\", \"timestamp\": 1637221750000 }, { \"state\": \"FALSE\", \"timestamp\": 1637221690000 }, { \"state\": \"FALSE\", \"timestamp\": 1637221630000 }, { \"state\": \"FALSE\", \"timestamp\": 1637221570000 }, { \"state\": \"FALSE\", \"timestamp\": 1637221510000 }, { \"state\": \"FALSE\", \"timestamp\": 1637221450000 }, { \"state\": \"FALSE\", \"timestamp\": 1637221390000 }, { \"state\": \"FALSE\", \"timestamp\": 1637221330000 }, { \"state\": \"FALSE\", \"timestamp\": 1637221270000 }, { \"state\": \"FALSE\", \"timestamp\": 1637221210000 }, { \"state\": \"FALSE\", \"timestamp\": 1637221150000 }, { \"state\": \"FALSE\", \"timestamp\": 1637221090000 }, { \"state\": \"FALSE\", \"timestamp\": 1637221030000 }, { \"state\": \"FALSE\", \"timestamp\": 1637220970000 }, { \"state\": \"FALSE\", \"timestamp\": 1637220910000 }, { \"state\": \"FALSE\", \"timestamp\": 1637220852000 }, { \"state\": \"FALSE\", \"timestamp\": 1637220790000 }, { \"state\": \"FALSE\", \"timestamp\": 1637220730000 }, { \"state\": \"FALSE\", \"timestamp\": 1637220670000 }, { \"state\": \"FALSE\", \"timestamp\": 1637220610000 }, { \"state\": \"FALSE\", \"timestamp\": 1637220550000 }, { \"state\": \"FALSE\", \"timestamp\": 1637220490000 }, { \"state\": \"FALSE\", \"timestamp\": 1637220430000 }, { \"state\": \"FALSE\", \"timestamp\": 1637220370000 }, { \"state\": \"FALSE\", \"timestamp\": 1637220310000 }, { \"state\": \"FALSE\", \"timestamp\": 1637220251000 }, { \"state\": \"FALSE\", \"timestamp\": 1637220190000 }, { \"state\": \"FALSE\", \"timestamp\": 1637220130000 }, { \"state\": \"TRUE\", \"timestamp\": 1637220070000 }, { \"state\": \"TRUE\", \"timestamp\": 1637220010000 }, { \"state\": \"TRUE\", \"timestamp\": 1637219950000 }, { \"state\": \"FALSE\", \"timestamp\": 1637219891000 }, { \"state\": \"FALSE\", \"timestamp\": 1637219830000 }, { \"state\": \"FALSE\", \"timestamp\": 1637219770000 }, { \"state\": \"FALSE\", \"timestamp\": 1637219710000 }, { \"state\": \"FALSE\", \"timestamp\": 1637219650000 }, { \"state\": \"FALSE\", \"timestamp\": 1637219590000 }, { \"state\": \"FALSE\", \"timestamp\": 1637219530000 }, { \"state\": \"FALSE\", \"timestamp\": 1637219470000 }, { \"state\": \"FALSE\", \"timestamp\": 1637219410000 }, { \"state\": \"FALSE\", \"timestamp\": 1637219350000 }, { \"state\": \"FALSE\", \"timestamp\": 1637219290000 }, { \"state\": \"FALSE\", \"timestamp\": 1637219230000 }, { \"state\": \"FALSE\", \"timestamp\": 1637219170000 }, { \"state\": \"FALSE\", \"timestamp\": 1637219110000 }, { \"state\": \"FALSE\", \"timestamp\": 1637219050000 }, { \"state\": \"FALSE\", \"timestamp\": 1637218990000 }, { \"state\": \"FALSE\", \"timestamp\": 1637218930000 }, { \"state\": \"FALSE\", \"timestamp\": 1637218870000 }, { \"state\": \"FALSE\", \"timestamp\": 1637218810000 }, { \"state\": \"FALSE\", \"timestamp\": 1637218750000 }, { \"state\": \"FALSE\", \"timestamp\": 1637218690000 }, { \"state\": \"FALSE\", \"timestamp\": 1637218630000 }, { \"state\": \"FALSE\", \"timestamp\": 1637218570000 }, { \"state\": \"FALSE\", \"timestamp\": 1637218510000 }, { \"state\": \"FALSE\", \"timestamp\": 1637218450000 }, { \"state\": \"FALSE\", \"timestamp\": 1637218150000 }, { \"state\": \"FALSE\", \"timestamp\": 1637218090000 }, { \"state\": \"FALSE\", \"timestamp\": 1637218030000 }, { \"state\": \"FALSE\", \"timestamp\": 1637217970000 }, { \"state\": \"FALSE\", \"timestamp\": 1637217910000 }, { \"state\": \"FALSE\", \"timestamp\": 1637217850000 }, { \"state\": \"TRUE\", \"timestamp\": 1637217790000 }, { \"state\": \"TRUE\", \"timestamp\": 1637217730000 }, { \"state\": \"TRUE\", \"timestamp\": 1637217670000 }, { \"state\": \"TRUE\", \"timestamp\": 1637217610000 }, { \"state\": \"TRUE\", \"timestamp\": 1637217550000 }, { \"state\": \"TRUE\", \"timestamp\": 1637217490000 }, { \"state\": \"FALSE\", \"timestamp\": 1637217432000 }, { \"state\": \"FALSE\", \"timestamp\": 1637217370000 }, { \"state\": \"FALSE\", \"timestamp\": 1637217311000 }, { \"state\": \"FALSE\", \"timestamp\": 1637217250000 }, { \"state\": \"FALSE\", \"timestamp\": 1637217190000 }, { \"state\": \"FALSE\", \"timestamp\": 1637217130000 }, { \"state\": \"FALSE\", \"timestamp\": 1637217070000 }, { \"state\": \"FALSE\", \"timestamp\": 1637217010000 }, { \"state\": \"FALSE\", \"timestamp\": 1637216950000 }, { \"state\": \"FALSE\", \"timestamp\": 1637216890000 }, { \"state\": \"FALSE\", \"timestamp\": 1637216830000 }, { \"state\": \"FALSE\", \"timestamp\": 1637216770000 }, { \"state\": \"FALSE\", \"timestamp\": 1637216710000 }, { \"state\": \"FALSE\", \"timestamp\": 1637216650000 }, { \"state\": \"FALSE\", \"timestamp\": 1637216590000 }, { \"state\": \"FALSE\", \"timestamp\": 1637216530000 }, { \"state\": \"FALSE\", \"timestamp\": 1637216470000 }, { \"state\": \"FALSE\", \"timestamp\": 1637216410000 }, { \"state\": \"FALSE\", \"timestamp\": 1637216350000 }, { \"state\": \"FALSE\", \"timestamp\": 1637216290000 }, { \"state\": \"FALSE\", \"timestamp\": 1637216231000 }, { \"state\": \"FALSE\", \"timestamp\": 1637216171000 }, { \"state\": \"FALSE\", \"timestamp\": 1637216110000 }, { \"state\": \"FALSE\", \"timestamp\": 1637216050000 }, { \"state\": \"FALSE\", \"timestamp\": 1637215990000 }, { \"state\": \"FALSE\", \"timestamp\": 1637215930000 }, { \"state\": \"FALSE\", \"timestamp\": 1637215870000 }, { \"state\": \"FALSE\", \"timestamp\": 1637215810000 }, { \"state\": \"FALSE\", \"timestamp\": 1637215750000 }, { \"state\": \"FALSE\", \"timestamp\": 1637215690000 }, { \"state\": \"FALSE\", \"timestamp\": 1637215630000 }, { \"state\": \"FALSE\", \"timestamp\": 1637215570000 }, { \"state\": \"FALSE\", \"timestamp\": 1637215510000 }, { \"state\": \"FALSE\", \"timestamp\": 1637215451000 }, { \"state\": \"FALSE\", \"timestamp\": 1637215390000 }, { \"state\": \"FALSE\", \"timestamp\": 1637215330000 }, { \"state\": \"FALSE\", \"timestamp\": 1637215270000 }, { \"state\": \"FALSE\", \"timestamp\": 1637215210000 }, { \"state\": \"FALSE\", \"timestamp\": 1637215150000 }, { \"state\": \"FALSE\", \"timestamp\": 1637215090000 }, { \"state\": \"FALSE\", \"timestamp\": 1637215030000 }, { \"state\": \"FALSE\", \"timestamp\": 1637214970000 }, { \"state\": \"FALSE\", \"timestamp\": 1637214910000 }, { \"state\": \"FALSE\", \"timestamp\": 1637214851000 }, { \"state\": \"FALSE\", \"timestamp\": 1637214791000 }, { \"state\": \"FALSE\", \"timestamp\": 1637214731000 }, { \"state\": \"FALSE\", \"timestamp\": 1637214670000 }, { \"state\": \"FALSE\", \"timestamp\": 1637214610000 }, { \"state\": \"FALSE\", \"timestamp\": 1637214551000 }, { \"state\": \"FALSE\", \"timestamp\": 1637214490000 }, { \"state\": \"FALSE\", \"timestamp\": 1637214430000 }, { \"state\": \"FALSE\", \"timestamp\": 1637214370000 }, { \"state\": \"FALSE\", \"timestamp\": 1637214311000 }, { \"state\": \"FALSE\", \"timestamp\": 1637214250000 }, { \"state\": \"FALSE\", \"timestamp\": 1637214191000 }, { \"state\": \"FALSE\", \"timestamp\": 1637214130000 }, { \"state\": \"FALSE\", \"timestamp\": 1637214070000 }, { \"state\": \"FALSE\", \"timestamp\": 1637214010000 }, { \"state\": \"FALSE\", \"timestamp\": 1637213950000 }, { \"state\": \"FALSE\", \"timestamp\": 1637213890000 }, { \"state\": \"FALSE\", \"timestamp\": 1637213830000 }, { \"state\": \"FALSE\", \"timestamp\": 1637213770000 }, { \"state\": \"FALSE\", \"timestamp\": 1637213710000 }, { \"state\": \"FALSE\", \"timestamp\": 1637213650000 }, { \"state\": \"FALSE\", \"timestamp\": 1637213590000 }, { \"state\": \"FALSE\", \"timestamp\": 1637213530000 }, { \"state\": \"FALSE\", \"timestamp\": 1637213470000 }, { \"state\": \"FALSE\", \"timestamp\": 1637213410000 }, { \"state\": \"FALSE\", \"timestamp\": 1637213350000 }, { \"state\": \"FALSE\", \"timestamp\": 1637213290000 }, { \"state\": \"FALSE\", \"timestamp\": 1637213230000 }, { \"state\": \"FALSE\", \"timestamp\": 1637213170000 }, { \"state\": \"FALSE\", \"timestamp\": 1637213110000 }, { \"state\": \"FALSE\", \"timestamp\": 1637213050000 }, { \"state\": \"FALSE\", \"timestamp\": 1637212990000 }, { \"state\": \"FALSE\", \"timestamp\": 1637212930000 }, { \"state\": \"FALSE\", \"timestamp\": 1637212870000 }, { \"state\": \"FALSE\", \"timestamp\": 1637212810000 }, { \"state\": \"FALSE\", \"timestamp\": 1637212750000 }, { \"state\": \"FALSE\", \"timestamp\": 1637212690000 }, { \"state\": \"FALSE\", \"timestamp\": 1637212630000 }, { \"state\": \"FALSE\", \"timestamp\": 1637212570000 }, { \"state\": \"FALSE\", \"timestamp\": 1637212510000 }, { \"state\": \"FALSE\", \"timestamp\": 1637212450000 }, { \"state\": \"FALSE\", \"timestamp\": 1637212390000 }, { \"state\": \"FALSE\", \"timestamp\": 1637212330000 }, { \"state\": \"FALSE\", \"timestamp\": 1637212270000 }, { \"state\": \"FALSE\", \"timestamp\": 1637212210000 }, { \"state\": \"FALSE\", \"timestamp\": 1637212150000 }, { \"state\": \"FALSE\", \"timestamp\": 1637212090000 }, { \"state\": \"FALSE\", \"timestamp\": 1637212030000 }, { \"state\": \"FALSE\", \"timestamp\": 1637211970000 }, { \"state\": \"FALSE\", \"timestamp\": 1637211910000 }, { \"state\": \"FALSE\", \"timestamp\": 1637211850000 }, { \"state\": \"FALSE\", \"timestamp\": 1637211790000 }, { \"state\": \"FALSE\", \"timestamp\": 1637211730000 }, { \"state\": \"FALSE\", \"timestamp\": 1637211670000 }, { \"state\": \"FALSE\", \"timestamp\": 1637211610000 }, { \"state\": \"FALSE\", \"timestamp\": 1637211550000 }, { \"state\": \"FALSE\", \"timestamp\": 1637211490000 }, { \"state\": \"FALSE\", \"timestamp\": 1637211430000 }, { \"state\": \"FALSE\", \"timestamp\": 1637211370000 }, { \"state\": \"FALSE\", \"timestamp\": 1637211310000 }, { \"state\": \"FALSE\", \"timestamp\": 1637211250000 }, { \"state\": \"FALSE\", \"timestamp\": 1637211190000 }, { \"state\": \"FALSE\", \"timestamp\": 1637211130000 }, { \"state\": \"FALSE\", \"timestamp\": 1637211070000 }, { \"state\": \"FALSE\", \"timestamp\": 1637211010000 }, { \"state\": \"FALSE\", \"timestamp\": 1637210950000 }, { \"state\": \"FALSE\", \"timestamp\": 1637210890000 }, { \"state\": \"FALSE\", \"timestamp\": 1637210830000 }, { \"state\": \"FALSE\", \"timestamp\": 1637210770000 }, { \"state\": \"FALSE\", \"timestamp\": 1637210710000 }, { \"state\": \"FALSE\", \"timestamp\": 1637210650000 }, { \"state\": \"FALSE\", \"timestamp\": 1637210590000 }, { \"state\": \"FALSE\", \"timestamp\": 1637210530000 }, { \"state\": \"FALSE\", \"timestamp\": 1637210470000 }, { \"state\": \"FALSE\", \"timestamp\": 1637210410000 }, { \"state\": \"FALSE\", \"timestamp\": 1637210350000 }, { \"state\": \"FALSE\", \"timestamp\": 1637210290000 }, { \"state\": \"FALSE\", \"timestamp\": 1637210230000 }, { \"state\": \"FALSE\", \"timestamp\": 1637210170000 }, { \"state\": \"FALSE\", \"timestamp\": 1637210110000 }, { \"state\": \"FALSE\", \"timestamp\": 1637210050000 }, { \"state\": \"FALSE\", \"timestamp\": 1637209990000 }, { \"state\": \"FALSE\", \"timestamp\": 1637209930000 }, { \"state\": \"FALSE\", \"timestamp\": 1637209870000 }, { \"state\": \"FALSE\", \"timestamp\": 1637209810000 }, { \"state\": \"FALSE\", \"timestamp\": 1637209750000 }, { \"state\": \"FALSE\", \"timestamp\": 1637209690000 }, { \"state\": \"FALSE\", \"timestamp\": 1637209630000 }, { \"state\": \"FALSE\", \"timestamp\": 1637209570000 }, { \"state\": \"FALSE\", \"timestamp\": 1637209510000 }, { \"state\": \"FALSE\", \"timestamp\": 1637209450000 }, { \"state\": \"FALSE\", \"timestamp\": 1637209390000 }, { \"state\": \"FALSE\", \"timestamp\": 1637209330000 }, { \"state\": \"FALSE\", \"timestamp\": 1637209270000 }, { \"state\": \"FALSE\", \"timestamp\": 1637209210000 }, { \"state\": \"FALSE\", \"timestamp\": 1637209151000 }, { \"state\": \"FALSE\", \"timestamp\": 1637209092000 }, { \"state\": \"FALSE\", \"timestamp\": 1637209031000 }, { \"state\": \"FALSE\", \"timestamp\": 1637208970000 }, { \"state\": \"FALSE\", \"timestamp\": 1637208911000 }, { \"state\": \"FALSE\", \"timestamp\": 1637208850000 }, { \"state\": \"FALSE\", \"timestamp\": 1637208790000 }, { \"state\": \"FALSE\", \"timestamp\": 1637208730000 }, { \"state\": \"FALSE\", \"timestamp\": 1637208670000 }, { \"state\": \"FALSE\", \"timestamp\": 1637208610000 }, { \"state\": \"FALSE\", \"timestamp\": 1637208550000 }, { \"state\": \"FALSE\", \"timestamp\": 1637208490000 }, { \"state\": \"FALSE\", \"timestamp\": 1637208430000 }, { \"state\": \"FALSE\", \"timestamp\": 1637208370000 }, { \"state\": \"FALSE\", \"timestamp\": 1637208310000 }, { \"state\": \"FALSE\", \"timestamp\": 1637208250000 }, { \"state\": \"FALSE\", \"timestamp\": 1637208190000 }, { \"state\": \"FALSE\", \"timestamp\": 1637208130000 }, { \"state\": \"FALSE\", \"timestamp\": 1637208070000 }, { \"state\": \"FALSE\", \"timestamp\": 1637208010000 }, { \"state\": \"FALSE\", \"timestamp\": 1637207950000 }, { \"state\": \"FALSE\", \"timestamp\": 1637207890000 }, { \"state\": \"FALSE\", \"timestamp\": 1637207830000 }, { \"state\": \"FALSE\", \"timestamp\": 1637207770000 }, { \"state\": \"FALSE\", \"timestamp\": 1637207710000 }, { \"state\": \"FALSE\", \"timestamp\": 1637207650000 }, { \"state\": \"FALSE\", \"timestamp\": 1637207590000 }, { \"state\": \"FALSE\", \"timestamp\": 1637207531000 }, { \"state\": \"FALSE\", \"timestamp\": 1637207471000 }, { \"state\": \"FALSE\", \"timestamp\": 1637207411000 }, { \"state\": \"FALSE\", \"timestamp\": 1637207351000 }, { \"state\": \"FALSE\", \"timestamp\": 1637207290000 }, { \"state\": \"FALSE\", \"timestamp\": 1637207230000 }, { \"state\": \"FALSE\", \"timestamp\": 1637207170000 }, { \"state\": \"FALSE\", \"timestamp\": 1637207110000 }, { \"state\": \"FALSE\", \"timestamp\": 1637207050000 }, { \"state\": \"FALSE\", \"timestamp\": 1637206990000 }, { \"state\": \"FALSE\", \"timestamp\": 1637206930000 }, { \"state\": \"FALSE\", \"timestamp\": 1637206870000 }, { \"state\": \"FALSE\", \"timestamp\": 1637206810000 }, { \"state\": \"FALSE\", \"timestamp\": 1637206750000 }, { \"state\": \"FALSE\", \"timestamp\": 1637206690000 }, { \"state\": \"FALSE\", \"timestamp\": 1637206630000 }, { \"state\": \"FALSE\", \"timestamp\": 1637206570000 }, { \"state\": \"FALSE\", \"timestamp\": 1637206510000 }, { \"state\": \"FALSE\", \"timestamp\": 1637206450000 }, { \"state\": \"FALSE\", \"timestamp\": 1637206390000 }, { \"state\": \"FALSE\", \"timestamp\": 1637206330000 }, { \"state\": \"FALSE\", \"timestamp\": 1637206271000 }, { \"state\": \"FALSE\", \"timestamp\": 1637206211000 }, { \"state\": \"FALSE\", \"timestamp\": 1637206151000 }, { \"state\": \"FALSE\", \"timestamp\": 1637206090000 }, { \"state\": \"FALSE\", \"timestamp\": 1637206030000 }, { \"state\": \"FALSE\", \"timestamp\": 1637205970000 }, { \"state\": \"FALSE\", \"timestamp\": 1637205911000 }, { \"state\": \"FALSE\", \"timestamp\": 1637205851000 }, { \"state\": \"FALSE\", \"timestamp\": 1637205790000 }, { \"state\": \"FALSE\", \"timestamp\": 1637205730000 }, { \"state\": \"FALSE\", \"timestamp\": 1637205670000 }, { \"state\": \"FALSE\", \"timestamp\": 1637205611000 }, { \"state\": \"FALSE\", \"timestamp\": 1637205550000 }, { \"state\": \"FALSE\", \"timestamp\": 1637205490000 }, { \"state\": \"FALSE\", \"timestamp\": 1637205430000 }, { \"state\": \"FALSE\", \"timestamp\": 1637205370000 }, { \"state\": \"FALSE\", \"timestamp\": 1637205311000 }, { \"state\": \"FALSE\", \"timestamp\": 1637205250000 }, { \"state\": \"FALSE\", \"timestamp\": 1637205190000 }, { \"state\": \"FALSE\", \"timestamp\": 1637205131000 }, { \"state\": \"FALSE\", \"timestamp\": 1637205070000 }, { \"state\": \"FALSE\", \"timestamp\": 1637205010000 }, { \"state\": \"FALSE\", \"timestamp\": 1637204950000 }, { \"state\": \"TRUE\", \"timestamp\": 1637204890000 }, { \"state\": \"TRUE\", \"timestamp\": 1637204830000 }, { \"state\": \"TRUE\", \"timestamp\": 1637204770000 }, { \"state\": \"TRUE\", \"timestamp\": 1637204710000 }, { \"state\": \"TRUE\", \"timestamp\": 1637204650000 }, { \"state\": \"TRUE\", \"timestamp\": 1637204590000 }, { \"state\": \"TRUE\", \"timestamp\": 1637204530000 }, { \"state\": \"TRUE\", \"timestamp\": 1637204470000 }, { \"state\": \"FALSE\", \"timestamp\": 1637204410000 }, { \"state\": \"FALSE\", \"timestamp\": 1637204350000 }, { \"state\": \"FALSE\", \"timestamp\": 1637204290000 }, { \"state\": \"FALSE\", \"timestamp\": 1637204230000 }, { \"state\": \"FALSE\", \"timestamp\": 1637204170000 }, { \"state\": \"FALSE\", \"timestamp\": 1637204110000 }, { \"state\": \"FALSE\", \"timestamp\": 1637204051000 }, { \"state\": \"FALSE\", \"timestamp\": 1637203990000 }, { \"state\": \"FALSE\", \"timestamp\": 1637203930000 }, { \"state\": \"FALSE\", \"timestamp\": 1637203870000 }, { \"state\": \"FALSE\", \"timestamp\": 1637203810000 }, { \"state\": \"FALSE\", \"timestamp\": 1637203750000 }, { \"state\": \"FALSE\", \"timestamp\": 1637203690000 }, { \"state\": \"FALSE\", \"timestamp\": 1637203630000 }, { \"state\": \"TRUE\", \"timestamp\": 1637203570000 }, { \"state\": \"FALSE\", \"timestamp\": 1637203510000 }, { \"state\": \"TRUE\", \"timestamp\": 1637203450000 }, { \"state\": \"TRUE\", \"timestamp\": 1637203390000 }, { \"state\": \"TRUE\", \"timestamp\": 1637203331000 }, { \"state\": \"TRUE\", \"timestamp\": 1637203270000 }, { \"state\": \"TRUE\", \"timestamp\": 1637203210000 }, { \"state\": \"TRUE\", \"timestamp\": 1637203150000 }, { \"state\": \"TRUE\", \"timestamp\": 1637203091000 }, { \"state\": \"TRUE\", \"timestamp\": 1637203030000 }, { \"state\": \"TRUE\", \"timestamp\": 1637202970000 }, { \"state\": \"TRUE\", \"timestamp\": 1637202910000 }, { \"state\": \"TRUE\", \"timestamp\": 1637202850000 }, { \"state\": \"TRUE\", \"timestamp\": 1637202790000 }, { \"state\": \"TRUE\", \"timestamp\": 1637202730000 }, { \"state\": \"TRUE\", \"timestamp\": 1637202671000 }, { \"state\": \"TRUE\", \"timestamp\": 1637202610000 }, { \"state\": \"TRUE\", \"timestamp\": 1637202550000 }, { \"state\": \"FALSE\", \"timestamp\": 1637202491000 }, { \"state\": \"FALSE\", \"timestamp\": 1637202430000 }, { \"state\": \"FALSE\", \"timestamp\": 1637202370000 }, { \"state\": \"FALSE\", \"timestamp\": 1637202310000 }, { \"state\": \"TRUE\", \"timestamp\": 1637202250000 }, { \"state\": \"TRUE\", \"timestamp\": 1637202190000 }, { \"state\": \"TRUE\", \"timestamp\": 1637202131000 }, { \"state\": \"TRUE\", \"timestamp\": 1637202070000 }, { \"state\": \"TRUE\", \"timestamp\": 1637202010000 }, { \"state\": \"TRUE\", \"timestamp\": 1637201950000 }, { \"state\": \"FALSE\", \"timestamp\": 1637201890000 }, { \"state\": \"FALSE\", \"timestamp\": 1637201830000 }, { \"state\": \"FALSE\", \"timestamp\": 1637201770000 }, { \"state\": \"FALSE\", \"timestamp\": 1637201710000 }, { \"state\": \"FALSE\", \"timestamp\": 1637201650000 }, { \"state\": \"FALSE\", \"timestamp\": 1637201590000 }, { \"state\": \"FALSE\", \"timestamp\": 1637201530000 }, { \"state\": \"FALSE\", \"timestamp\": 1637201470000 }, { \"state\": \"FALSE\", \"timestamp\": 1637201410000 }, { \"state\": \"TRUE\", \"timestamp\": 1637201350000 }, { \"state\": \"TRUE\", \"timestamp\": 1637201290000 }, { \"state\": \"TRUE\", \"timestamp\": 1637201230000 }, { \"state\": \"TRUE\", \"timestamp\": 1637201170000 }, { \"state\": \"TRUE\", \"timestamp\": 1637201110000 }, { \"state\": \"TRUE\", \"timestamp\": 1637201050000 }, { \"state\": \"TRUE\", \"timestamp\": 1637200990000 }, { \"state\": \"TRUE\", \"timestamp\": 1637200930000 }, { \"state\": \"TRUE\", \"timestamp\": 1637200870000 }, { \"state\": \"TRUE\", \"timestamp\": 1637200810000 }, { \"state\": \"TRUE\", \"timestamp\": 1637200750000 }, { \"state\": \"TRUE\", \"timestamp\": 1637200692000 }, { \"state\": \"TRUE\", \"timestamp\": 1637200630000 }, { \"state\": \"TRUE\", \"timestamp\": 1637200570000 }, { \"state\": \"TRUE\", \"timestamp\": 1637200510000 }, { \"state\": \"TRUE\", \"timestamp\": 1637200450000 }, { \"state\": \"TRUE\", \"timestamp\": 1637200390000 }, { \"state\": \"TRUE\", \"timestamp\": 1637200330000 }, { \"state\": \"TRUE\", \"timestamp\": 1637200270000 }, { \"state\": \"TRUE\", \"timestamp\": 1637200211000 }, { \"state\": \"FALSE\", \"timestamp\": 1637200150000 }, { \"state\": \"FALSE\", \"timestamp\": 1637200090000 }, { \"state\": \"FALSE\", \"timestamp\": 1637200030000 }, { \"state\": \"FALSE\", \"timestamp\": 1637199970000 }, { \"state\": \"FALSE\", \"timestamp\": 1637199910000 }, { \"state\": \"TRUE\", \"timestamp\": 1637199850000 }, { \"state\": \"TRUE\", \"timestamp\": 1637199790000 }, { \"state\": \"TRUE\", \"timestamp\": 1637199730000 }, { \"state\": \"TRUE\", \"timestamp\": 1637199670000 }, { \"state\": \"TRUE\", \"timestamp\": 1637199610000 }, { \"state\": \"TRUE\", \"timestamp\": 1637199550000 }, { \"state\": \"TRUE\", \"timestamp\": 1637199490000 }, { \"state\": \"TRUE\", \"timestamp\": 1637199430000 }, { \"state\": \"TRUE\", \"timestamp\": 1637199370000 }, { \"state\": \"TRUE\", \"timestamp\": 1637199310000 }, { \"state\": \"TRUE\", \"timestamp\": 1637199250000 }, { \"state\": \"TRUE\", \"timestamp\": 1637199190000 }, { \"state\": \"TRUE\", \"timestamp\": 1637199130000 }, { \"state\": \"TRUE\", \"timestamp\": 1637199070000 }, { \"state\": \"TRUE\", \"timestamp\": 1637199010000 }, { \"state\": \"TRUE\", \"timestamp\": 1637198950000 }, { \"state\": \"TRUE\", \"timestamp\": 1637198890000 }, { \"state\": \"TRUE\", \"timestamp\": 1637198830000 }, { \"state\": \"TRUE\", \"timestamp\": 1637198770000 }, { \"state\": \"TRUE\", \"timestamp\": 1637198710000 }, { \"state\": \"FALSE\", \"timestamp\": 1637198650000 }, { \"state\": \"FALSE\", \"timestamp\": 1637198590000 }, { \"state\": \"FALSE\", \"timestamp\": 1637198530000 }, { \"state\": \"FALSE\", \"timestamp\": 1637198470000 }, { \"state\": \"FALSE\", \"timestamp\": 1637198410000 }, { \"state\": \"FALSE\", \"timestamp\": 1637198350000 }, { \"state\": \"FALSE\", \"timestamp\": 1637198290000 }, { \"state\": \"FALSE\", \"timestamp\": 1637198230000 }, { \"state\": \"TRUE\", \"timestamp\": 1637198170000 }, { \"state\": \"TRUE\", \"timestamp\": 1637198110000 }, { \"state\": \"TRUE\", \"timestamp\": 1637198050000 }, { \"state\": \"TRUE\", \"timestamp\": 1637197990000 }, { \"state\": \"TRUE\", \"timestamp\": 1637197930000 }, { \"state\": \"TRUE\", \"timestamp\": 1637197870000 }, { \"state\": \"TRUE\", \"timestamp\": 1637197810000 }, { \"state\": \"FALSE\", \"timestamp\": 1637197750000 }, { \"state\": \"FALSE\", \"timestamp\": 1637197690000 }, { \"state\": \"FALSE\", \"timestamp\": 1637197630000 }, { \"state\": \"FALSE\", \"timestamp\": 1637197570000 }, { \"state\": \"FALSE\", \"timestamp\": 1637197510000 }, { \"state\": \"FALSE\", \"timestamp\": 1637197450000 }, { \"state\": \"TRUE\", \"timestamp\": 1637197390000 }, { \"state\": \"TRUE\", \"timestamp\": 1637197330000 }, { \"state\": \"TRUE\", \"timestamp\": 1637197270000 }, { \"state\": \"TRUE\", \"timestamp\": 1637197210000 }, { \"state\": \"TRUE\", \"timestamp\": 1637197150000 }, { \"state\": \"TRUE\", \"timestamp\": 1637197090000 }, { \"state\": \"TRUE\", \"timestamp\": 1637197030000 }, { \"state\": \"TRUE\", \"timestamp\": 1637196970000 }, { \"state\": \"TRUE\", \"timestamp\": 1637196910000 }, { \"state\": \"TRUE\", \"timestamp\": 1637196850000 }, { \"state\": \"TRUE\", \"timestamp\": 1637196790000 }, { \"state\": \"TRUE\", \"timestamp\": 1637196730000 }, { \"state\": \"TRUE\", \"timestamp\": 1637196670000 }, { \"state\": \"TRUE\", \"timestamp\": 1637196610000 }, { \"state\": \"TRUE\", \"timestamp\": 1637196550000 }, { \"state\": \"FALSE\", \"timestamp\": 1637196490000 }, { \"state\": \"FALSE\", \"timestamp\": 1637196430000 }, { \"state\": \"FALSE\", \"timestamp\": 1637196370000 }, { \"state\": \"FALSE\", \"timestamp\": 1637196310000 }, { \"state\": \"FALSE\", \"timestamp\": 1637196250000 }, { \"state\": \"FALSE\", \"timestamp\": 1637196190000 }, { \"state\": \"FALSE\", \"timestamp\": 1637196131000 }, { \"state\": \"FALSE\", \"timestamp\": 1637196070000 }, { \"state\": \"FALSE\", \"timestamp\": 1637196010000 }, { \"state\": \"TRUE\", \"timestamp\": 1637195950000 }, { \"state\": \"TRUE\", \"timestamp\": 1637195890000 }, { \"state\": \"FALSE\", \"timestamp\": 1637195830000 }, { \"state\": \"FALSE\", \"timestamp\": 1637195770000 }, { \"state\": \"FALSE\", \"timestamp\": 1637195710000 }, { \"state\": \"FALSE\", \"timestamp\": 1637195650000 }, { \"state\": \"FALSE\", \"timestamp\": 1637195591000 }, { \"state\": \"FALSE\", \"timestamp\": 1637195531000 }, { \"state\": \"FALSE\", \"timestamp\": 1637195470000 }, { \"state\": \"FALSE\", \"timestamp\": 1637195410000 }]\nreturn msg;",
        "outputs": 1,
        "noerr": 0,
        "initialize": "",
        "finalize": "",
        "libs": [],
        "x": 4650,
        "y": 2410,
        "wires": [
            []
        ]
    }
]

That will do. Trying to investigate as soon as possible.

The time flows backwards in your array.

first element  1637224151000
last element   1637195410000

The widget does manipulate the data when the internal storage is created (that goes one by one) so the result is always in timed order but it does not check the array in prior the adding.
Adding one by one but in wrong order does not let them to be combined.

May be it is reasonable to add that check so it doesn't care the incoming order.

Mean time - the quick fix will be if you have that array in msg.payload juist reverse it.

msg.payload = msg.payload.reverse()

1 Like

Working!
Instead of using msg.payload.reverse() i just changed my SQL Query to return timeline in opposite order.

Thanks for your time!

1 Like