Behavior Expected: Dynamic Tag History Binding behaves differently than Direct Tag History Binding
Expectations: While in designer, the Dynamic Tag History Binding on Perspective Time Series chart showed proper historically queried data in both the dataset returned and the visual.
However, when published to the client, the data would show all '0' with a flat-lined trend. This was all verified with console prints on the dataset and verification of the object datatypes, etc.
Creating a direct tag history query on the same time series chart as a separate data series returned valid data and timestamps relative to the gateway time.
Ultimately the issue boiled down to the historical timestamps - the data is pulled from individual OPC-UA servers and because the tags were using the 'on change' historical setting, it was saved to the database using the source opc-ua timestamp.
Solution / Fix: Per this post: How to set the Timestamp Source to Value on a tag - #3 by Jan - we changed the tags to Tag Group to utilize the 'server' timestamp which fixed the issue above, dynamic queries will now return data aligned with server timestamp.
Regardless, there is a backend issue where direct queries are querying data differently than dynamic queries.