1.3 Create and Display Many-to-Many Relationships

1.3 Create and Display Many-to-Many Relationships


  while I'm dragging the Order Entity
  into the Aggregate, the Client Entity is not brought with Order Entity  
  what the problem?
  just show submitDate attribute,although i crate relationship  between order entity and client entity in diagram  in      right way.

  I'm sorry my question for the lesson following before ( create and display one-to-Many Relationships) 
 I'm relly sorry.
Hi Rula Moh,

Did you try to drag both entities one by one? That should work.

About the pattern in the video that you were expecting to happen, it is no longer active. Thanks for the heads-up, we will fix it in the video.

António Pereira
Hello, I'm getting this error when I publish the app and I don't understand why... Thank you

Publishing Error
Unable to upgrade database schema. Error trying to create index on database table 'OSUSR_l2m_OrderItem' over fields '[PRODUCTID],[ORDERID]'.
Hi Mara,

When you have errors creating index usually this means that you have data on that table that does not comply with the constraint you are creating, e.g. you have a unique index over a couple of attributes Name, Email but you have duplicate values in the rows of that table John Doe, john.doe@email.com; John Doe, john.doe@email.com.

To overcome this you need to remove the duplicates from the table. In this example you can try to remove the unique index from the entity and on the list screen add a delete button to the table records that deletes that row using the Delete<Entity> entity action. Once you have taken care of the duplicates you can go back to the entity and create the unique index.

ORA-02291: integrity constraint (OSADMIN_TST.OSFRK_OSUSR_GKT_ORDERITE_62323) violated - parent key not found
ORA-06512: at line 1

i need help, what is this error ? 

Hi Rodolfo,

It appears that you are already creating records in the many-to-many table. The next lesson explains how to do it, have you watched it?

Basically, you need to use an Assign node to set the value for the OrderId attribute that is coming from the input parameter.

I hope this helps,
If I wants to add Grand total attribute in "order" Table  (total value of order), then  How can I calculate all "total Price" value in "orderItem"  table? 
Hi Kader,

I think you'll see that later ahead in the training. But, basically, the Aggregate allows you to group data and perform calculations. You can create an aggregate that includes Order and OrderItem, group all the columns of the order you want to show and sum the total of the OrderItem to create the grand total. You can also count the number of items in the order using the count over any order item column.

I hope this helps,

Its help lot,