I am updating remote MySQL database by comparing row by row from local MSSQL one. Idea was to do update in 3 steps:
1: select all ID's from local and execute following query on remote:
delete from REMOTE_DATABASE.TABLE where ID not in
( list of LOCAL_DATABASE.TABLE ID's linked by OR condition )
2: select ID's from LOCAL_DATABASE.TABLE that are not exist on remote and insert
3: update rows that have both tables.
My question is regarding first step: I have 50000+ products. I am working in C# and I could join all ID's in string but I was wondering can query with 50000 ID's linked by OR condition be executed? Is it a wrong approach?