Database filter - Forum - Corticon - Progress Community

Database filter

 Forum

Database filter

This question is answered

I have a rulesheet in which I liked to use a database filter.

The attribute on which the filter takes place is a "boolean" in Corticon.

In the database this is a "bit" attribute.

When I select the database filter option I get this error: "filter expression cannot be processed by database".

 

The mapping is not giving any errors, and I cannot find a work around.

Has anyone found a solution to this problem?

 

 

Extra:
Same problem in SQL 2012

Verified Answer
  •  
    Instead of your current filter
    Corticon does accept this
    Since CC.CC_Test is Boolean you don’t actually need to say =T
    However when I ran a test I got this error:
     
    But that appears to be invalid SQL:
    SQL is happy with this syntax
    But that’s not what Corticon appears to be creating..
    Subsequently I found this in the docs:
    So it appears you cannot do what you want to.
    Most likely you will need to change the datatype.
    Mike
     
All Replies
  • What database are you using?
     

    James Arsenault  |  Product Development  |  Progress Software
    email: james.arsenault@progress.com |  direct: 781-280-4934

  • Hi James,

    Thomas is using SQL Server 2014. And yes, it's not officially supported by Corticon EDC 5.5. So the question should perhaps be: Is this typical behaviour for Corticon 5.5 and SQL Server 2014? In other words: Will this filter-issue not occur with SQL Server 2012 (and earlier)?

    Thank you,

    Gertjan

  • Was this a database that was previously using an earlier version of SQL Server? If so we ran into some issues similar to this, the fix was to clear the database metadata and re-import it. I would suggest doing this and seeing if the problem persists.

  • Tried to clear the metadata and re-imported it, sadly no change. Same error on database filter

  • CC_Test.zip

    Uploaded database backup and project zip in one zip file

  •  
    Instead of your current filter
    Corticon does accept this
    Since CC.CC_Test is Boolean you don’t actually need to say =T
    However when I ran a test I got this error:
     
    But that appears to be invalid SQL:
    SQL is happy with this syntax
    But that’s not what Corticon appears to be creating..
    Subsequently I found this in the docs:
    So it appears you cannot do what you want to.
    Most likely you will need to change the datatype.
    Mike
     
  • Mike,

    Thanks for answering.

    Not really the answer is was hoping for.

    Change the datatype in this production enviroment will lead to many problems. so I will have to look for a different solution.

    @progress, will this change in the future. Will boolean datatype be supported by query filters?

  • Would it be possible to implement the field in your vocab as a custom data type whereby the labels are Yes/No (so used in rule modelling) and the value refer to an integer value as in your DB (0/1)?
     
    Best regards,
    Harold
     +31 654 217 073
     
  • Hello Harold-Jan,

    Problem then is that Corticon identifies the datatype from database as a bit and the custom dataype as an integer.

    Leading to this warning:  

    "Attribute data type integer cannot be mapped to database type bit. Supported database types: {int, smallint, tinyint, bigint, etc}"