databasesnowflake-cloud-data-platformrowid

ROWID equivalent in Snowflake to delete duplicate lines


I have a database with duplicate lines. I usally use the rowid, but it doesn't exist in Snowflake. How can I remove duplicate lines in Snowflake without this ? I try severals solution for the moment but without sucess ! Tanks


Solution

  • It seems that there is no equivalent to the ROWID in Snowflake.A Workaround is to do a select distinct and then insert the result in the same table.

    insert overwrite into some_table
    select distinct * from some_table;