Hitachi Vantara Pentaho Community Forums
Results 1 to 6 of 6

Thread: Error: IndexOutOfBoundsException

  1. #1

    Default Error: IndexOutOfBoundsException

    I'm receiving the following error during my Kettle transformation:
    TRIM.0 - java.lang.IndexOutOfBoundsException: Index: 0, Size: 0

    I have a datafile that only contains 108 rows but has 855 characters in each.
    I noticed that when I view my datafile in Notepad it looks normal but when reading it through TEXT FILE INPUT it shows a blank row between each record.
    Would this cause the exception/error above ?
    If so how can I specify the proper end-of-line in my TEXT FILE INPUT ?

    Another note....every time I launch the transformation it gives me a different record count in my TEXT FILE.

    Dave

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

    Default

    Transformation and a piece of anonymized input text?

    Regards,
    Sven

  3. #3

    Default files attached

    Change fielname ADM.txt to ADM.dat or change name in Kettle transformation.
    Attached Files Attached Files

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

    Default

    And version of Kettle? 2.5? If I run it in 3.1(to be M1) I get:
    -TRIM.0 - java.lang.IllegalStateException: Calling Context.exit without previous Context.enter
    at org.mozilla.javascript.Context.exit(Context.java:419)
    at org.mozilla.javascript.Context.exit(Context.java:411)
    at org.pentaho.di.trans.steps.scriptvalues_mod.ScriptValuesMod.dispose(ScriptValuesMod.java:799)
    at org.pentaho.di.trans.step.BaseStep.runStepThread(BaseStep.java:2419)
    at org.pentaho.di.trans.steps.scriptvalues_mod.ScriptValuesMod.run(ScriptValuesMod.java:812)

    I guess it has something to do with how you use the variables in the javascript step. It's pretty unconventional... I'll check tomorrow, it's getting late here... for fun try the trimcut step at http://wiki.pentaho.org/display/EAI/...ation+Plug-Ins

    Regards,
    Sven

  5. #5

    Default modified with same error

    Using Kettle 2.5

    I removed the JavaScript for trimming and specified the trim in the Text File Input step (didn't see that function there initially), hopefully this is more conventional

    I basically still get the same error (see attached doc).

    Should I upgrade to 3.0 ?
    Attached Files Attached Files

  6. #6

    Default Upgraded to 3.0.1

    Problem went away after upgrading to 3.0.1........life is good !

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.