I haven't been able to find any similar question but I am looking for a way to delete all but 1 of similar rows that have 2 specific columns that contain identical data. For example:
| price | symbol | date |
|---|---|---|
| 13 | RT | 2020-10-1 |
| 80.9 | DX | 2020-10-2 |
| 81 | DX | 2020-10-2 |
| 90 | AP | 2020-10-3 |
| 89.9 | AP | 2020-10-3 |
| 90 | AP | 2020-10-3 |
| 85 | DX | 2020-10-4 |
In this example, I'd like to be able to run a query in the BQ console to find any of the rows with that have both the date AND the symbol as identical and delete one of them (which one gets deleted doesn't matter much.) The query would delete 1 of the DX rows on 2020-10-2 and 2 of the AP rows on 2020-10-3.
I appreciate the help!!
https://stackoverflow.com/questions/65592725/bigquery-how-to-delete-rows-that-have-2-columns-with-identical-data January 06, 2021 at 04:50PM
没有评论:
发表评论