The reference documentation (https://www.toshiba-sol.co.jp/en/pro/griddb/docs-en/v4_5/GridDB_SQL_Reference.html?utm_source=chatgpt.com#over) states: Multiple use of the WINDOW function/OVER clause in the same SELECT clause, and ...are not allowed.
Your second approach is the right way