Hitachi Vantara Pentaho Community Forums
Results 1 to 8 of 8

Thread: How to use De Normalizer in the right way

  1. #1

    Default How to use De Normalizer in the right way

    Hi all,

    I got a data strem where I have data split in rows.
    I need to group this lines in a single row and report all the data of several lines on a single row one aside the other one .
    The number of lines are unpredictable.

    Please take one eye to attachment files.
    There is a 7 rows sample.
    Many thanks
    Giovannino
    Attached Images Attached Images  
    Attached Files Attached Files

  2. #2
    Join Date
    Jun 2012
    Posts
    5,534

    Default

    Denormalizer step expects a group id (one or more fields), yours is WORKITEM.
    Then you must identify a pair of fields (e.g. FIELDKEY, TEXTVALUE) but you point at a 5-tuple of fields.
    You will have to show the output row you want to see eventually.
    So long, and thanks for all the fish.

  3. #3

    Default

    I need to have a sort of big long row with data taken from different lines

    WORKITEM (line1 --> TEXTVALUE | NAME | DESCRIPTION) (line2--> |TEXTVALUE| NAME |DESCRIPTION|) (line3--> |TEXTVALUE| NAME |DESCRIPTION|) ... (line7--> |TEXTVALUE| NAME |DESCRIPTION|)

    I'm really do not know how get it .
    Thanks

  4. #4
    Join Date
    Jun 2012
    Posts
    5,534

    Default

    CSV is no suitable format for repeatable groups of fields.
    Perhaps you can find a better way to achieve your goal.
    Why do you think you need such a denormalized form of your input data?
    So long, and thanks for all the fish.

  5. #5

    Default

    CSV is only to make a short and easy sample to analize without the needing of all DB data.
    All data come from DB table and have other steps before to reach the denormalizer step.

    I thought it was the suitable solution. If you have alternative way to obtain a single very long row starting from several rows it is wellcome.
    The output of trasformation has to have that kind of format . It's a customer needings not mine.

    WORKITEM_XX |TEXTVALUE | NAME | DESCRIPTION| TEXTVALUE| NAME |DESCRIPTION |TEXTVALUE| NAME |DESCRIPTION| ... n... |TEXTVALUE| NAME |DESCRIPTION|
    WORKITEM_YY |TEXTVALUE | NAME | DESCRIPTION| TEXTVALUE| NAME |DESCRIPTION |TEXTVALUE| NAME |DESCRIPTION| ... n... |TEXTVALUE| NAME |DESCRIPTION|
    WORKITEM_ZZ |TEXTVALUE | NAME | DESCRIPTION| TEXTVALUE| NAME |DESCRIPTION |TEXTVALUE| NAME |DESCRIPTION| ... n... |TEXTVALUE| NAME |DESCRIPTION|

    Kettle makes coffee too !!! ;-) A possible solution has to be somewhere.

  6. #6
    Join Date
    Jun 2012
    Posts
    5,534

    Default

    Well, it's not that complicated, it just isn't professional in my eyes.
    Attached Files Attached Files
    So long, and thanks for all the fish.

  7. #7

    Default

    Hi Marabu,
    thanks so much for sample but using "|" I would mean the separation of different column of a table not a separator char.
    Is it possible to have that kind of table output or is it another trasformation structure ?
    Thanks

  8. #8
    Join Date
    Jun 2012
    Posts
    5,534

    Default

    Since you said the number of 3-tupels is variable, we know that the result is not tabular by definition.
    The row I produced is delimited text, so you can split it into fields.
    You can pretend there is a max number of 3-tupels and have a varying number of null values at the end that way.
    Still I must say, as a consultant I would do a bad job not talking my client out of this scheme.
    I can't imagine a single requirement, that is met by your denormalized data, and that isn't met better by the original normalized data.
    Good luck, anyway.
    So long, and thanks for all the fish.

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  
Privacy Policy | Legal Notices | Safe Harbor Privacy Policy

Copyright © 2005 - 2019 Hitachi Vantara Corporation. All Rights Reserved.