Customer Portal

Trouble with Joining

Comments 3

  • Avatar
    imriskal
    0
    Comment actions Permalink
    Hi takejerax,

    You forgot to attach the graph. And please try to describe your issue in more details. I am not sure about where the issue lies. It seems like your post ends in the middle of the sentence.

    Kind regards,
  • Avatar
    takejerax
    0
    Comment actions Permalink
    Thanks for the response. Let me try to post again.

    Here is the original microsoft excel file i'm using as input. => (XLSDATA_READER)
    https://www.dropbox.com/s/ip3azvap5hpwz ... _2013.xlsx
    It has 7 "sheets" . I'm interested in only the following 2 sheets
    1) Companies
    2) Investments

    Companies sheet has a list of just - companies : with the primary key field being "permalink"
    Investments sheet has a list of investments in these companies : it has a key : "investor_permalink" and a foreign key -> "company_permalink"

    Each of the companies above can have many investors. Similarly each investor can invest in many companies.
    (essentially a one->many relationship for either "key")

    What i'm trying to do is generate a json output with the following structure:
    https://www.dropbox.com/s/3ffpw8xtry9ov ... anies.json

    I have tried to do this in a bunch of ways and it produces the incorrect output.
    Following are 2 methods i used to try and do this.
    Method 1 : https://www.dropbox.com/s/6ntjwml1odc2c3a/Test.grf

    Method 2: https://www.dropbox.com/s/vjm1snf21hnps ... ments2.grf

    After the ExtHashJoin
    for each company (key:permalink, foreignkey:company_permalink)
    i need to fold in all investor_permalinks into a json array called "company_investors" as shown in the link to companies.json above.


    We would be really grateful for your help. I've tried searching through google and the forums extensively and haven't been able to get an answer. Thanks in advance.
  • Avatar
    imriskal
    0
    Comment actions Permalink
    I have prepared an example graph for you. You should get the main idea from it and then you should be able to modify it according to your needs.
    JSONWriter.grf
    It is not necessary to use any of the join components. Joining can be done directly in JSONWriter, using binding and key + parentKey properties.

    If you had any questions, please let me know.

    Kind regards,

Please sign in to leave a comment.