Hitachi Vantara Pentaho Community Forums
Results 1 to 10 of 10

Thread: Problem while saving a transformation to the repository

  1. #1

    Default Problem while saving a transformation to the repository

    Hi ,

    Was trying to build a common component, and while saving this to database i get the following exception


    Error saving transformation to repository!
    Error updating batch
    ORA-00001: unique constraint (DV_REP_4DEV.IDX_STEP_ATTRIBUTE_LOOKUP) violated

    Can some 1 help me with this?

    Regards,
    Raju

    transformation is very simple transformation.

    <?xml version="1.0" encoding="UTF-8"?>
    <transformation-steps>
    <steps>
    <step>
    <name>Error input specification</name>
    <type>MappingInput</type>
    <description/>
    <distribute>Y</distribute>
    <copies>1</copies>
    <partitioning>
    <method>none</method>
    <schema_name/>
    </partitioning>
    <fields>
    <field>
    <name>incmg_err_cd</name>
    <type>String</type>
    <length>-1</length>
    <precision>-1</precision>
    </field>
    <field>
    <name>field_value</name>
    <type>String</type>
    <length>-1</length>
    <precision>-1</precision>
    </field>
    <field>
    <name>ref_type</name>
    <type>String</type>
    <length>-1</length>
    <precision>-1</precision>
    </field>
    <field>
    <name>ref_id</name>
    <type>String</type>
    <length>-1</length>
    <precision>-1</precision>
    </field>
    <field>
    <name>input_nm</name>
    <type>String</type>
    <length>-1</length>
    <precision>-1</precision>
    </field>
    <field>
    <name>record_num</name>
    <type>String</type>
    <length>-1</length>
    <precision>-1</precision>
    </field>
    <select_unspecified>N</select_unspecified>
    </fields>
    <cluster_schema/>
    <remotesteps> <input> </input> <output> </output> </remotesteps> <GUI>
    <xloc>138</xloc>
    <yloc>159</yloc>
    <draw>Y</draw>
    </GUI>
    </step>
    <step>
    <name>Error output specification</name>
    <type>MappingOutput</type>
    <description/>
    <distribute>Y</distribute>
    <copies>1</copies>
    <partitioning>
    <method>none</method>
    <schema_name/>
    </partitioning>
    <fields>
    <field>
    <name>incmg_err_cd</name>
    <type>String</type>
    <length>-1</length>
    <precision>-1</precision>
    <added>N</added>
    </field>
    <field>
    <name>field_value</name>
    <type>String</type>
    <length>-1</length>
    <precision>-1</precision>
    <added>N</added>
    </field>
    <field>
    <name>ref_type</name>
    <type>String</type>
    <length>-1</length>
    <precision>-1</precision>
    <added>N</added>
    </field>
    <field>
    <name>ref_id</name>
    <type>String</type>
    <length>-1</length>
    <precision>-1</precision>
    <added>N</added>
    </field>
    <field>
    <name>input_nm</name>
    <type>String</type>
    <length>-1</length>
    <precision>-1</precision>
    <added>N</added>
    </field>
    <field>
    <name>record_num</name>
    <type>String</type>
    <length>-1</length>
    <precision>-1</precision>
    <added>N</added>
    </field>
    </fields>
    <cluster_schema/>
    <remotesteps> <input> </input> <output> </output> </remotesteps> <GUI>
    <xloc>538</xloc>
    <yloc>160</yloc>
    <draw>Y</draw>
    </GUI>
    </step>
    <step>
    <name>Modified Java Script Value</name>
    <type>ScriptValueMod</type>
    <description/>
    <distribute>Y</distribute>
    <copies>1</copies>
    <partitioning>
    <method>none</method>
    <schema_name/>
    </partitioning>
    <compatible>Y</compatible>
    <jsScripts> <jsScript> <jsScript_type>0</jsScript_type>
    <jsScript_name>Script 1</jsScript_name>
    <jsScript_script>&#47;&#47;Script here
    </jsScript_script>
    </jsScript> </jsScripts> <fields> </fields> <cluster_schema/>
    <remotesteps> <input> </input> <output> </output> </remotesteps> <GUI>
    <xloc>349</xloc>
    <yloc>160</yloc>
    <draw>Y</draw>
    </GUI>
    </step>
    </steps>
    <order>
    <hop> <from>Error input specification</from><to>Modified Java Script Value</to><enabled>Y</enabled> </hop>
    <hop> <from>Modified Java Script Value</from><to>Error output specification</to><enabled>Y</enabled> </hop>
    </order>
    <notepads>
    </notepads>
    </transformation-steps>

  2. #2

    Default

    I Think this is a bug.
    How and where do i post this issue? and for now is it ok to remove the unique index and create a non unique index on the same table with the same columns?

    ----Details------

    Iam trying to create a subtransform, defining mapping input specification. Once i enter one attribute and try saving it to repository, system throws an exception. With the following details.


    Error saving transformation to repository!
    Error updating batch
    ORA-00001: unique constraint (DV_REP_4DEV.IDX_STEP_ATTRIBUTE_LOOKUP) violated

    This is on table R_STEP_ATTRIBUTE, there is a unique index on step_id,NR and CODE. Not sure what "NR" means, every time iam saving the transformation it stores NR as "0" and the step_ID will be the same for all the attrbiutes that iam creating in the mapping input specification component. Also the code can repeat, because of which it is giving this unique constraint error.



    Regards,
    Raju

  3. #3
    Join Date
    May 2006
    Posts
    4,882

    Default

    Bug reports at http://jira.pentaho.org/browse/PDI

    I would not start messing around with constraints... keep your jobs/transformations as XML files for the moment.

    Regards,
    Sven

  4. #4

    Default

    Thanks Sven, As suggested have posted the issue in JIRA.

    Regards,
    Raju

  5. #5
    Join Date
    Aug 2008
    Posts
    9

    Default

    Hi,

    I have been fiddling with the saveRep and readRep methods for last 2 days. I have been having problem too with saving transformation to repository. I keep getting this error
    "Error saving transformation to repository! Unique constraint violated"

    So I created a simple transformation with text input and file output and it is not able to save the info in the repository.

    I have been creating some custom plugin, so I thought may be it is because of that BUT it should be able to save the transformation with GUI input/output option.

    Any insight on this will be much appreciated.
    Thanks
    Tuni

  6. #6
    Join Date
    May 2006
    Posts
    4,882

    Default

    You forgot an "i" somewhere ... it's hard to tell things if people write their own plugins. Saving/loading still works for me so it's your changes that break stuff.

    Start with a fresh PDI and see whether you still have it... if you don't you know where to search

    Regards.
    Sven

  7. #7
    Join Date
    Aug 2008
    Posts
    9

    Default

    Hi,

    I checked and I am not missing any "i"'s this time . This is not even a custom plugin. I am not able to even save a simple Input row to file outpu into the repository now. I tried creating a new transformation from scratch.

    Thanks

  8. #8
    Join Date
    May 2006
    Posts
    4,882

    Default

    Post the transformation (after removing all passwords)

  9. #9
    Join Date
    Aug 2008
    Posts
    9

    Default

    Here it is.
    Attached Files Attached Files

  10. #10
    Join Date
    May 2006
    Posts
    4,882

    Default

    Works for me so probably with all your testing your repository is corrupt. try making a new repository (using a different user) and try again.

    Regards,
    Sven

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.