I have a query that is running very slow so I started looking into the Execution Plan.
TRY_CAST is a safe way of finding out if the data can be cast to a type. And there is a warning in the plan regarding
Type conversion in expression try_cast may affect "CardinalityEstimate" in query plan choice
Please note that I am not a DBA but a coder. Treat me as a novice when I comes to database stuff.
What should be best approach to improve the speed of the query (based on the warning in the title of this question)? Is there anything other than
TRY_CAST that might help speed up the query, for example,
CAST on its own is prone to exceptions and the only way to safe cast that I know of is