Perspective Stacked Bar Chart - TimeSeriesChart

Good morning all,

I am attempting to use the TimeSeriesChart as a stacked bar chart in Ignition Perspective. I have linked my data as a query with a json return and it seems to be picking it up; however, the data is just off of the side. I will attach a picture below:

Seems like it doesn't want to show my data. I only have 2 points of data; one for 4/1 and one for 4/8. My main issue is making it so the bottom row only utilizes dates that are in my database (once a week, a Monday date). Does anyone know how to make this possible?

Thanks in advance for the help,

Please post the chart configuration. See Wiki - how to post code on this forum.

The chart will have a data binding so you'll need to paste the data separately, nicely formatted too.

Just a heads up, the query selecting the data changed so you will see a difference in the value of the output. Didn't affect the issue that already exists.

Chart Config
[
  {
    "type": "ia.chart.timeseries",
    "version": 0,
    "props": {
      "series": [
        {
          "name": "Cleaning Time"
        }
      ],
      "plots": [
        {
          "relativeWeight": 1,
          "trends": [
            {
              "axis": "",
              "baselines": [],
              "breakLine": true,
              "columns": [
                {
                  "color": "#FF4A4A",
                  "key": "S",
                  "styles": {
                    "highlighted": {
                      "fill": {
                        "color": "",
                        "opacity": null
                      },
                      "stroke": {
                        "color": "",
                        "dashArray": null,
                        "opacity": null,
                        "width": null
                      }
                    },
                    "muted": {
                      "fill": {
                        "color": "",
                        "opacity": null
                      },
                      "stroke": {
                        "color": "",
                        "dashArray": null,
                        "opacity": null,
                        "width": null
                      }
                    },
                    "normal": {
                      "fill": {
                        "color": "",
                        "opacity": null
                      },
                      "stroke": {
                        "color": "",
                        "dashArray": null,
                        "opacity": null,
                        "width": null
                      }
                    },
                    "selected": {
                      "fill": {
                        "color": "",
                        "opacity": null
                      },
                      "stroke": {
                        "color": "",
                        "dashArray": null,
                        "opacity": null,
                        "width": null
                      }
                    }
                  }
                },
                {
                  "color": "#9dd55a",
                  "key": "I",
                  "styles": {
                    "highlighted": {
                      "fill": {
                        "color": "",
                        "opacity": null
                      },
                      "stroke": {
                        "color": "",
                        "dashArray": null,
                        "opacity": null,
                        "width": null
                      }
                    },
                    "muted": {
                      "fill": {
                        "color": "",
                        "opacity": null
                      },
                      "stroke": {
                        "color": "",
                        "dashArray": null,
                        "opacity": null,
                        "width": null
                      }
                    },
                    "normal": {
                      "fill": {
                        "color": "",
                        "opacity": null
                      },
                      "stroke": {
                        "color": "",
                        "dashArray": null,
                        "opacity": null,
                        "width": null
                      }
                    },
                    "selected": {
                      "fill": {
                        "color": "",
                        "opacity": null
                      },
                      "stroke": {
                        "color": "",
                        "dashArray": null,
                        "opacity": null,
                        "width": null
                      }
                    }
                  }
                },
                {
                  "color": "#E3FF38",
                  "key": "C",
                  "styles": {
                    "highlighted": {
                      "fill": {
                        "color": "",
                        "opacity": null
                      },
                      "stroke": {
                        "color": "",
                        "dashArray": null,
                        "opacity": null,
                        "width": null
                      }
                    },
                    "muted": {
                      "fill": {
                        "color": "",
                        "opacity": null
                      },
                      "stroke": {
                        "color": "",
                        "dashArray": null,
                        "opacity": null,
                        "width": null
                      }
                    },
                    "normal": {
                      "fill": {
                        "color": "",
                        "opacity": null
                      },
                      "stroke": {
                        "color": "",
                        "dashArray": null,
                        "opacity": null,
                        "width": null
                      }
                    },
                    "selected": {
                      "fill": {
                        "color": "",
                        "opacity": null
                      },
                      "stroke": {
                        "color": "",
                        "dashArray": null,
                        "opacity": null,
                        "width": null
                      }
                    }
                  }
                }
              ],
              "interpolation": "curveLinear",
              "radius": 2,
              "series": "Cleaning Time",
              "stack": true,
              "type": "bar",
              "visible": true
            }
          ],
          "axes": [],
          "markers": []
        }
      ],
      "title": {
        "text": "Time Spent"
      },
      "timeAxis": {
        "tickCount": 2,
        "tick": {
          "label": {
            "angled": true,
            "format": "M-D",
            "font": {
              "size": 12
            }
          }
        }
      },
      "timeRange": {
        "dateFormat": "MMMM Do YYYY",
        "timeFormat": "None"
      },
      "xTrace": {
        "infoBox": {
          "showTime": false,
          "dateFormat": "M-D",
          "timeFormat": "None"
        }
      },
      "defaultStyles": {
        "colorScheme": "RdYlGn"
      }
    },
    "meta": {
      "name": "TimeSeriesChart"
    },
    "position": {
      "x": 0.0178,
      "y": 0.0172,
      "height": 0.4323,
      "width": 0.9461
    },
    "custom": {},
    "propConfig": {
      "props.series[0].data": {
        "binding": {
          "type": "query",
          "config": {
            "returnFormat": "json",
            "queryPath": "Chart Puller",
            "parameters": {
              "Shift": "0",
              "Press": "26"
            }
          }
        }
      }
    }
  }
]
Data
[
  {
    "time": 1711944000000,
    "Inspect": 34,
    "Clean": 25.5,
    "Safety": 60
  },
  {
    "time": 1712548800000,
    "Inspect": 23,
    "Clean": 9.5,
    "Safety": 45
  }
]

Two posts tackling the same vertical bar seem to switch to XY Chart to provide a solution:

(The last line of your Chart Config has ]``` - three extra backticks which means it can't be posted into Designer. You might edit those out in case anyone else wants to try. Nice post, by the way!)

Thanks for that, I made that edit. I will definitely look into these posts - as long as it looks stacked I don't see a problem with it. My only issue as of right now is making those items stacked rather than lie behind one another, should one week S be longer than I and another I be longer than S for example would cause one or the other be hidden.