Unneeded FLOOR in automated query
Posted: Sun 14 Mar 2010 12:56
Hi,
I'm using an Oracle DB with Entity Framework.
I have a Table with a column named "Type" (can be a number 1-200). I put a condition on what value it sets. I looked at the ToTraceString() When using linq for a simple query and actually in every query it generates:
and so on with all the possible types.
How can I tune it so It won't do that?
Thank you.
I'm using an Oracle DB with Entity Framework.
I have a Table with a column named "Type" (can be a number 1-200). I put a condition on what value it sets. I looked at the ToTraceString() When using linq for a simple query and actually in every query it generates:
Code: Select all
select... "Extent1".TYPE AS TYPE....
from ....
where ("Extent1".TYPE = (FLOOR(CAST('1' AS NUMBER)))) OR
("Extent1".TYPE = (FLOOR(CAST('2' AS NUMBER)))) OR
("Extent1".TYPE = (FLOOR(CAST('3' AS NUMBER)))) OR .....
How can I tune it so It won't do that?
Thank you.