I've run into another issue. I'm not quite sure what is even happening here - but it looks like the result columns of a single query are being re-used somehow in the same query.
Here's a full set of SQL commands to reproduce this:
Create dummy tables, insert sample data, and load the table:
select
lag(high, -1) over (order by date) - lag(close, 1) over (order by date),
lag(high, -1) over (order by date) - lag(high, 1) over (order by date),
lag(high, -1) over (order by date) - lag(high, 1) over (order by date),
lag(high, -1) over (order by date) - lag(high, 1) over (order by date)
from sample_table;
Both should give the same results, but I'm seeing a reducing row count for each column in the IMCS version and the numbers are also wrong compared to the PG query. Here's the output for IMCS:
Output for PG:
I'm not sure what is happening here, but the docs don't mention anything about computed columns being re-used in the same query.
Hi,
I've run into another issue. I'm not quite sure what is even happening here - but it looks like the result columns of a single query are being re-used somehow in the same query.
Here's a full set of SQL commands to reproduce this:
Create dummy tables, insert sample data, and load the table:
Testing the shifts:
IMCS version: (Note: I have used project just to improve the readability of the output)
PG12 version:
Both should give the same results, but I'm seeing a reducing row count for each column in the IMCS version and the numbers are also wrong compared to the PG query. Here's the output for IMCS: Output for PG:
I'm not sure what is happening here, but the docs don't mention anything about computed columns being re-used in the same query.