Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

suggestion for bulk delete #100

Open
rabigautam opened this issue Jul 1, 2021 · 3 comments
Open

suggestion for bulk delete #100

rabigautam opened this issue Jul 1, 2021 · 3 comments

Comments

@rabigautam
Copy link

rabigautam commented Jul 1, 2021

Accordingly to document I couldn't find bulk delete (delete row with different ids),Yeah I could perform the task by direct sql query but it would be better if the same pattern is followed as like bulk insert and bulk update

@Valindo
Copy link

Valindo commented Aug 22, 2021

let batchDelete = await data.query(
  `DELETE FROM myTable WHERE id=:id`,
  [
    [{ id: 17 }],
    [{ id:  15 }],
    [{ id:  14 }],
    [{ id:  12 }],
    [{ id:  11 }]
  ]
)

Theoretically this should work

@rabigautam
Copy link
Author

thank you for your suggestion

@Valindo
Copy link

Valindo commented Aug 22, 2021

@rabimatuag if this solves your issue, please close the issue :)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants