Problem Table relation/Flowfield

Marcos
Marcos Member Posts: 55
Hello,


I have a problem with an home made table, maby someone can help me out.

I'f made a table lets call it A, in this table i want to show the order details from table C.
Do get this information i have to relate C and A, so id made a flowfield in table C refers to table B to get the Try-out No. (relation C->B = OFF no.,B->A = TR no.)
So the relation is done now i have the corespondending numbers in table C (TR numbers).
But when i make a relation between C and A using the TR numbers the order details dont apair.
Is it because the TR number fields in the tables C and B a flowfields ??
Do i have to sovle this problem with code ?

This figure is an example of the structure.
http://album.partyflock.nl/7570599.jpg

Many thanx in forward,

Marcos

Comments

  • kine
    kine Member Posts: 12,562
    I am lost in your descirption and the image didn't help me. Try to describe it all without using Try-Out names and use A, B, C because everything is Try-Out for me and when I try to sort it out... :|
    Kamil Sacek
    MVP - Dynamics NAV
    My BLOG
    NAVERTICA a.s.
  • Marcos
    Marcos Member Posts: 55
    Hope its clear now, its a hard problem to write out....
  • lubost
    lubost Member Posts: 633
    I don't know it exactly but I think that you can't create relation to flowfield, because it is not calculated in time you need it. System isn't able to check validity of inserted value.
  • Marcos
    Marcos Member Posts: 55
    lubost wrote:
    I don't know it exactly but I think that you can't create relation to flowfield, because it is not calculated in time you need it. System isn't able to check validity of inserted value.

    Sounds clear, but how can i backdoor this problem, probably using CAL code to copy flowfield data to a new field or using find rec code ??
  • lubost
    lubost Member Posts: 633
    You haven't create flowfields only for creating relation between tables. Better way is to create relation by setting the property (if is it possible) or create relation by code using OnValidate and OnLookup triggers.
  • kine
    kine Member Posts: 12,562
    Yes, you cannot do the relation on CalcFields. You need to create correct relational structure of your tables.

    If I understand correctly the structure is (without FlowFields):

    A -> "TRXXXX" -> B <- "OFFXXXX" <- C

    and you now needs to show data from C in A?

    It is impossible, because now you have N:N connection and you cannot be sure that you will get just one record from C for the record from A and it means no lookup possible.
    Kamil Sacek
    MVP - Dynamics NAV
    My BLOG
    NAVERTICA a.s.
  • kine
    kine Member Posts: 12,562
    But you can do the lookups to have the data from C in B and for each A show all records from B with the data.
    Kamil Sacek
    MVP - Dynamics NAV
    My BLOG
    NAVERTICA a.s.
  • Marcos
    Marcos Member Posts: 55
    C = TRXXXX
    B = OFXXXX - [TRXXXX (flowfield to A)]
    A = [OFXXXX (flowfield to B)] - [TRXXXX (Flowfield to B)]

    In the URL figure A and C are confused, damn....

    i need the order details from C in A....
  • kine
    kine Member Posts: 12,562
    Marcos wrote:
    C = TRXXXX
    B = OFXXXX - [TRXXXX (flowfield to A)]
    A = [OFXXXX (flowfield to B)] - [TRXXXX (Flowfield to B)]

    In the URL figure A and C are confused, damn....

    i need the order details from C in A....

    And how is connected A to B if both fields are FlowField :?: :?: :?:
    Kamil Sacek
    MVP - Dynamics NAV
    My BLOG
    NAVERTICA a.s.
  • Marcos
    Marcos Member Posts: 55
    Its a table relation field
  • Marcos
    Marcos Member Posts: 55
    Isnt there a way to copy values in a flowfield column to a new column in the table ?
  • kine
    kine Member Posts: 12,562
    Marcos wrote:
    Its a table relation field

    But through which field? On which field you set the table relation? In which table? Still it is not clear for me.
    Kamil Sacek
    MVP - Dynamics NAV
    My BLOG
    NAVERTICA a.s.
  • Marcos
    Marcos Member Posts: 55
    IN A OFXXXX is an table relation field to B.......
  • kine
    kine Member Posts: 12,562
    Marcos wrote:
    IN A OFXXXX is an table relation field to B.......

    it means that it is not
    C = TRXXXX
    B = OFXXXX - [TRXXXX (flowfield to A)]
    A = [OFXXXX (flowfield to B)] - [TRXXXX (Flowfield to B)]

    but
    C = TRXXXX
    B = OFXXXX - [TRXXXX (flowfield to A)]
    A = [OFXXXX (table relation to B)] - [TRXXXX (Flowfield to B)]
    :?:
    Kamil Sacek
    MVP - Dynamics NAV
    My BLOG
    NAVERTICA a.s.
  • Marcos
    Marcos Member Posts: 55
    Ola,


    I was busy with 10 things in the same time yesterday, thats why i made some mistakes in my question..
    This is the situation....


    C = TRXXXX
    B = OFXXXX - [TRXXXX (flowfield to C)]
    A = [OFXXXX (table relation to B)] - [TRXXXX (Flowfield to B)]