You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
* Deleting specific rows - Query for the rows you want to delete and call syn.delete on the results
201
+
* Deleting specific rows - Query for the rows you want to delete and call delete_rows on the results
202
202
203
203
```python
204
204
table.delete_rows(query=f"SELECT * FROM {table.id} WHERE Strand = '+'")
205
205
```
206
206
207
+
* Or deleting rows based on a dataframe, where the ROW_IDandROW_VERSION columns specify the rows to be deleted from the table. In this example, rows 2and3 are deleted. See this document that describes the expected columns of the dataframe: <https://rest-docs.synapse.org/rest/org/sagebionetworks/repo/model/table/Row.html>. Note: The ROW_VERSION begins at 1 upon row creation and increases by one with every subsequent update.
df: A pandas dataframe that contains the rows to delete. The dataframe must at least contain the `ROW_ID` and `ROW_VERSION` columns.
4073
+
If the entity is one of the following: `EntityView`, `Dataset`, `DatasetCollection`, or `SubmissionView` then the dataframe must also contain the `ROW_ETAG` column.
4074
+
See this document that describes the expected columns of the dataframe:
0 commit comments