I work on SQL server 2012 I face issue when using ( OR && IS NULL ) on where statement
to Delete data it will be very slow
so How to replace ( OR AND IS NULL ) by any thing can do same thing ?
DELETE f
FROM Parts.ChemicalProfiles f
INNER JOIN #TempPC t
ON t.ChemicalID = f.ChemicalID
WHERE t.[status]='Not Found in Chemical Master' OR t.[status] IS NULL
I need to replace line below on where
WHERE t.[status]='Not Found in Chemical Master' OR t.[status] IS NULL
by any thing can do same job of (OR t.[status] IS NULL) because it very slow running
so I need to rewrite statement below to enhance performance and very quickly
WHERE t.[status]='Not Found in Chemical Master' OR t.[status] IS NULL