New issue 188 by kamran.fallah: Wrong query for boolean values in oracle
http://code.google.com/p/dblinq2007/issues/detail?id=188
What steps will reproduce the problem?
1.generate db in oracle, create a table which contain a ISENABLED column of
type NUMBER(1)
2. generate linqToSql using DbMetal (the field type must be boolean)
3.run the following code:
var context= ...;
context.Log = Console.Out;
var query = (from x in context.Items where !x.ISENABLED).ToArray();
What is the expected output? What do you see instead?
The expected output would be the list of items that are not enabled.
you'll receive an OracleException.
What version of the product are you using? On what operating system?
DbLinq 0.19 on XP
Please provide any additional information below.
the generated query is "SELECT * FROM ITEM WHERE NOT ITEM.ISENABLED" which
is correct in MS SQL but not in Oracle as we do not have real boolean type
in Oracle.
the suggestion is to generate query "SELECT * FROM ITEM WHERE
(ITEM.ISENABLED = 0)
--
You received this message because you are listed in the owner
or CC fields of this issue, or because you starred this issue.
You may adjust your issue notification preferences at:
http://code.google.com/hosting/settings
Issue 189 has been merged into this issue.
Comment #2 on issue 188 by jonmpryor: Wrong query for boolean values in
oracle
http://code.google.com/p/dblinq2007/issues/detail?id=188
(No comment was entered for this change.)