Options
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
03-09-2023 05:01 PM
Thank you Kearon for taking time to answer.
I tried implementing the change suggested but seeing a different error now.
Error :
org.apache.spark.sql.AnalysisException: Unsupported SQL statement for table 'SCD2_SILVER': Missing query is not supported.
Modified Code:
CREATE OR REFRESH STREAMING LIVE TABLE SCD2_RAW
AS select current_timestamp() load_time, right(input_file_name(),13) source_file, * from json.`dbfs:/FileStore/tables/J_File_1.json`;
CREATE OR REFRESH LIVE TABLE SCD2_SILVER;
APPLY CHANGES INTO LIVE.SCD2_SILVER
FROM STREAM(LIVE.SCD2_RAW)
KEYS (userid)
SEQUENCE BY load_time
COLUMNS * EXCEPT (load_time, source_file);
Thanks