View Full Version : getRow question

04-28-2006, 04:14 AM
We have a plugin that takes rows as input and adds a few values to it or if it is used where there are no previous steps, will generate a single row. We were trying to use the getRow method to tell us if there is a previous step (if the first time it is called, no row is returned it must not have any previous steps or no data in them at least)

This doesnt work, line 954 in BaseStep.java is commented out, which would enable it, but with the line commented out it throws and index out of bounds exception.

Is there a better way for our plugin to determine if there were previous steps?



04-28-2006, 05:13 AM

This is not that hard to do actually because we have access to the transformation meta-data:

String previousStepNames[] = getTransMeta().getPrevStepnames(getStepname());

That way you can determine it at initialization time (init method, before you start to run) and you don't have to wait for a row or not.

Hope this helps,


04-28-2006, 05:39 AM
That helps alot. thank you.