Cardinalities generate Incompatible Combination of Objects

XI R2 Designer, Oracle 9i RDBMS

We have two tables: customers and orders, with cardinalities set to indicate a customer places many orders. We have an Order Type object using orders.order_type as the select, and Number of Unique Customers using select(distinct customers.cust_id) as the object select.

In the Designer Query Panel, DeskI and WebI, when a query is defined with Number of Unique customers as a result object and Order Type = ‘ABC’ as a condition, it throws an “Incompatible combination of objects” error. Adding Order Type as a result is OK, but not for our user, plus Oracle can certainly cope with: select count(distinct customers.cust_id) from customers, orders where (customers.cust_id = orders.cust_id) and orders.order_type = ‘ABC’

Switch the cardinalities to 1 to 1, between the two tables in Designer, and it works, just like it used to, in older versions! We don’t want to change the cardinalities as context detection and ‘detect incompatible’ in aggregate navigation won’t work properly when the universe is extended.

FYI: can’t use keys as some of the objects to be defined on the orders table use functions, such as to_char(orders.order_dt,‘YYYY’)

Any known parameters to stop this issue?


JMCabot (BOB member since 2005-12-21)

This may be a stupid question , but could it be anything to do with the join you have setup

select count(distinct customers.cust_id) from customers, orders where customers.cust_id = orders.order_id and orders.order_type = ‘ABC’

shouldn’t it be customers.cust_id = orders.cust_id

or is this just a mistype ?

other than that , I assume you haven’t yet got any aggregate navigation incompatibilities set that might be causing the problem ?


richmona :australia: (BOB member since 2003-04-15)

Thanks for responding.

The join is just: customers.cust_id = orders.cust_id
The condition is: orders.order_type = ‘ABC’

No contexts or aggregate aware incompatibles in this simple universe that isolates the problem. Just two tables, 1 join and a few simple objects.

Thanks


JMCabot (BOB member since 2005-12-21)

I am doing the same type of thing in XI R1 and I do not have your issue. So that is odd. i have never received the incompatible objects without an aggregate navigation issue.

But a possible solution is:
You can add the order type table to your orders table object definitions so it forces the join without selecting the order type.


maverick976 :us: (BOB member since 2004-07-06)

Hi JM,

Thought I would link to my similar topic regarding this join definition bug…

https://bobj-board.org/t/52392

Cheers


Mak 1 :uk: (BOB member since 2005-01-06)

Not being pedantic , but I just thought it strange that you were joining

CUSTOMER_id in one table to ORDER_id in another ??


richmona :australia: (BOB member since 2003-04-15)

where

I know you are not being pedantic, but the above seems fine to me… :wink:

Seems this is more likely to be a bug in XIr2… 8)


Mak 1 :uk: (BOB member since 2005-01-06)

Obviously too many beers over christmas :roll_eyes:


richmona :australia: (BOB member since 2003-04-15)

I know ALL about that one… :mrgreen:


Mak 1 :uk: (BOB member since 2005-01-06)