View previous topic :: View next topic |
Author |
Message |
seema patni Beginner
Joined: 04 Nov 2003 Posts: 8 Topics: 5
|
Posted: Thu Apr 01, 2004 6:25 am Post subject: Comparing where clauses |
|
|
Hi ,
First of all i would like to thank the team members for the quick response .
Please tell me if it is possible to have the solution of the below mentioned problem using any database feature provided.
Problem:
I've two conditions which will be used in where clause of two queries.
I want to find out that there should not be any conflict between these two conditions . It means these should be compatible to each other .
Example :
There is a table with following fields :
Customer number
Customer Type
Transaction Type
Term
.
.
.
I condition : Cust_type = '2' and term between 12 to 60
II condition : Cust_type not= '2' and cust_num = '2222222'
III condition : Term in (24, 58) and cust_type = '2'
IV condition : Not ( cust_num = '2222222' and term = 12 )
Now in the above case following are the conclusions :
I and II are not compatible
I and III are compatible
I and IV are not compatible
III and IV are compatible
.
.
.
.
This is our requirement to find out whether the conditions are compatible or not . We dont have any data to operate upon . We just have conditions to be compared .
Thanks in advance
Seema |
|
Back to top |
|
|
CZerfas Intermediate
Joined: 31 Jan 2003 Posts: 211 Topics: 8
|
Posted: Thu Apr 01, 2004 6:48 am Post subject: |
|
|
Hello Seema,
since you are talking about the semantics of data (what meanings do certain values in columns have) there is no way for a formal comparison. The only chance I see would be document all the semantics, that data has in your shop. I cannot imagine how you would achieve that.
Therefore, you have to supply real data to proof, that different where clauses lead to the same answer set.
regards
Christian |
|
Back to top |
|
|
|
|