Skip to content

[Feat]: Add Filters to Bulk Insert function #1641

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

Open
BobLouderback opened this issue Apr 16, 2025 · 0 comments
Open

[Feat]: Add Filters to Bulk Insert function #1641

BobLouderback opened this issue Apr 16, 2025 · 0 comments

Comments

@BobLouderback
Copy link

I have a JSON output from a 3rd party API and need to bulk update some rows in my MySQL table. The JSON contains a survey_id and a survey status. The JSON does not provide the primary key, but does provide the survey_id field that can be used ALONG WITH another static field (static for each pull I make with the API) called "survey_type" to identify the unique row in the MySQL table that needs to be updated.

I would like the bulk insert function to have a filter ability, where I can update rows in the MySQL table ONLY if the filter is true. For example, I would pass the JSON to the bulk update function, and then set a filter for the table where table1.survey_type = {{tmp_survey_type}}, or perhaps {{table1.selectedrow.survey_type}}, or even hard coded to "1".

I have tried writing a standard SQL query that takes the JSON and updates the rows, but my version of MySQL does not handle JSON very well (v5.7).

Discussed in discord here: https://discord.com/channels/1096896040159957084/1121839720759046286/threads/1358917770737221653

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

1 participant