Customer Portal

NullPointerException in CodeParser

Comments 2

  • Avatar
    daveybob
    0
    Comment actions Permalink
    The only way I could find to post the actual graph was to get rid of the '<' and '>' chars. I replaced the '<' with '@' and the '>' with '%'. Here it is:

    @?xml version="1.0" encoding="UTF-8"?%
    @Graph created="Wed Oct 01 08:53:22 EDT 2008" guiVersion="1.10" id="1222865602462" licenseType="Evaluation license." modified="Wed Oct 01 13:30:20 EDT 2008" name="RefreshCluster" revision="1.11"%
    @Global%
    @Metadata fileURL="meta/Cluster.fmt" id="Metadata0"/%
    @Connection dbConfig="conn/AuthStarDB.cfg" id="Connection0" type="JDBC"/%
    @Connection dbConfig="conn/Reporting.cfg" id="Connection1" type="JDBC"/%
    @Property fileURL="workspace.prm" id="GraphParameter0"/%
    @/Global%
    @Phase number="0"%
    @Node dbConnection="Connection1" enabled="enabled" guiHeight="0" guiName="DBJoin" guiWidth="0" guiX="312" guiY="307" id="DBJOIN0" joinKey="CLUSTERID" sqlQuery="select CLUSTERID, CLUSTERNAME from CLUSTER" type="DBJOIN"%
    @attr name="transform"%@![CDATA[${out.0.CLUSTERID} = ${in.0.CLUSTERID};
    ${out.0.CLUSTERNAME} = ${in.0.CLUSTERNAME};
    ]]%@/attr%
    @/Node%
    @Node dbConnection="Connection0" enabled="enabled" guiHeight="0" guiName="DB Input Table" guiWidth="0" guiX="55" guiY="200" id="DB_INPUT_TABLE0" sqlQuery="select ID, CLUSTERNAME from Cluster" type="DB_INPUT_TABLE"/%
    @Node enabled="enabled" fileURL="c:/dev/clover/etl/data-out/cluster.txt" guiHeight="0" guiName="Structured Data Writer" guiWidth="0" guiX="285" guiY="174" id="STRUCTURE_WRITER0" mask="&lt;Cluster&gt; &lt;CLUSTERID=$CLUSTERID/&gt; &lt;CLUSTERNAME=$CLUSTERNAME/&gt; &lt;Cluster/&gt; " type="STRUCTURE_WRITER"/%
    @Node enabled="enabled" fileURL="c:/dev/clover/etl/data-out/matchedclusters.txt" guiHeight="0" guiName="Structured Data Writer" guiWidth="0" guiX="510" guiY="289" id="STRUCTURE_WRITER1" mask="&lt;Cluster&gt; &lt;CLUSTERID=$CLUSTERID/&gt; &lt;CLUSTERNAME=$CLUSTERNAME/&gt; &lt;Cluster/&gt; " type="STRUCTURE_WRITER"/%
    @Node enabled="enabled" fileURL="c:/dev/clover/etl/data-out/unmatchedclusters.txt" guiHeight="0" guiName="Structured Data Writer" guiWidth="0" guiX="519" guiY="389" id="STRUCTURE_WRITER2" mask="&lt;Cluster&gt; &lt;CLUSTERID=$CLUSTERID/&gt; &lt;CLUSTERNAME=$CLUSTERNAME/&gt; &lt;Cluster/&gt; " type="STRUCTURE_WRITER"/%
    @Edge fromNode="DBJOIN0:0" guiBendpoints="" id="Edge2" inPort="Port 0 (Body port)" metadata="Metadata0" outPort="Port 0 (joined records)" toNode="STRUCTURE_WRITER1:0"/%
    @Edge fromNode="DBJOIN0:1" guiBendpoints="" id="Edge3" inPort="Port 0 (Body port)" metadata="Metadata0" outPort="Port 1 (skipped records)" toNode="STRUCTURE_WRITER2:0"/%
    @Edge fromNode="DB_INPUT_TABLE0:0" guiBendpoints="" id="Edge0" inPort="Port 0 (Body port)" metadata="Metadata0" outPort="Port 0 (out)" toNode="STRUCTURE_WRITER0:0"/%
    @Edge fromNode="DB_INPUT_TABLE0:1" guiBendpoints="" id="Edge5" inPort="Port 0 (in)" metadata="Metadata0" outPort="Port 1 (out)" toNode="DBJOIN0:0"/%
    @/Phase%
    @/Graph%
  • Avatar
    avackova
    0
    Comment actions Permalink
    Hello,
    it's really Clover.ETL bug. In time being you have to write transformation in java, eg. for populating input records:
    import org.jetel.component.DataRecordTransform;
    import org.jetel.data.DataRecord;
    import org.jetel.exception.TransformException;


    public class MyTransform extends DataRecordTransform {

    public boolean transform(DataRecord[] arg0, DataRecord[] arg1)
    throws TransformException {
    arg1[0].copyFrom(arg0[0]);
    return true;
    }

    }

    By the way it's strange, that graph without transformation code throws an exception.

Please sign in to leave a comment.