Jump to content

SQL Delete freezing


This topic is 2970 days old. Please don't post here. Open a new topic instead.

Recommended Posts

Hi all

I have a delete SQL command that freezes FM for around 40 seconds, before succesfully executing the command. The table in question has 30,000 records. The command is:

"DELETE FROM Originals WHERE Case_IDF IS NULL AND LOWER (Receive_Subject) LIKE LOWER ('%" & Settings::Case Filter Spark & "%')"

Have I done anything wrong here?

Link to comment
Share on other sites

This is a fairly processing intensive SQL call as you are asking to transform 2 cols of 30,000 rows with LOWER and filtering the result with IS NULL and LIKE.

I would shift the LOWER to FM by making Originals::Receive_Subject and Settings::Case Filter Spark calculations that produce lower as a result.

PS SQL does not always like cols with spaces in the names so i would change Settings::Case Filter Spark to Settings::Case_Filter_Spark.

Edited by Kris M
Link to comment
Share on other sites

This topic is 2970 days old. Please don't post here. Open a new topic instead.

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
×
×
  • Create New...

Important Information

By using this site, you agree to our Terms of Use.