Qlik Community

QlikView Scripting

Discussion Board for collaboration on QlikView Scripting.

agigliotti
Honored Contributor II

Qlikview circular loop - how to avoid it

Hello,

Attached is a sample qvw file with sample data and the circular loop.

What could be done in data model to avoid it ?

Could someone guide me in the right direction ?

Many thanks in advance.

Best Regards

Andrea

Tags (1)
9 Replies
aronwilliamson
Contributor

Re: Qlikview circular loop - how to avoid it

Hi Andrea,

Remove the table:

/*[Sales network-Item category]:

LOAD * INLINE [

    Sales network, Item category,

    I, PC

    I, SC

    F, PC

    H, SC

];

*/

as it is a linking table but all the table are already linked without it.

Highlighted
agigliotti
Honored Contributor II

Re: Qlikview circular loop - how to avoid it

Aron,

I need that table because a sales network can sell only items of categories linked.

antoniotiman
Honored Contributor III

Re: Qlikview circular loop - how to avoid it

What about this Data Model ?

agigliotti
Honored Contributor II

Re: Qlikview circular loop - how to avoid it

did you merge four tables into one?

I don't think it's could works for my requirements.

specially because the end user has an input date (MM/DD/YYY) to submit and should be able to see what happened at that date, to what sales network and item category the sales agent belonged to.

Re: Qlikview circular loop - how to avoid it

You say 'the end user has an input date (MM/DD/YYY) to submit and should be able to see what happened at that date'

  • How do anticipate they will submit this date ?

  • Then what selection do you expect will happen ?

I somehow suspect you'll need to create a SCD [Slowly Changing Dimension] table quite likely by exploiting IntervalMatch().

Are there any other requirements not mentioned in your original question ?

satheshreddy
Contributor III

Re: Qlikview circular loop - how to avoid it

Hi Andrea,

if you want all tables with association better to cut association between two tables it will go out loops.

Regards

Sathish

agigliotti
Honored Contributor II

Re: Qlikview circular loop - how to avoid it

Thanks to all for your quickly reply.

Finally I decided to rename the field "Item category" of table "Sales network-Item category" to "Network category".

In this way I can show in UI both dimensions in order to check if the sales agent sold items that he should not.

BR

Andrea

Employee
Employee

Re: Qlikview circular loop - how to avoid it

If you want some reading on circular references and how to solve them, take a look at Circular References.

HIC

vvvvvvizard
Contributor III

Re: Qlikview circular loop - how to avoid it

Comment out any one of the same field name that is appearing in two different tables which is causing the circular refeence