tJavaRow : null pointer exception with length() method
Hi , I built the job tFileInputExcel ------> tJavaRow ----> tLogRow I am testing length of the column in the tJavaRow component with String chaine = input_row.Column1 then lg = chaine.length() but this latter is generating a null pointer exception. Here enclosed 3 screenshots (job , tJavaRow code and null pointer exception error)
Hi , I did this test as well but it fails as well. A s soon as I manage input_row.Column1 with length() method or != null the result is null pointer exception. Best regards, Yves.
This will prevent even if that column have blank space. if(input_row.Column1!=null && input_row.Column1.trim().length()>0){ String a = input_row.Column1.length(); }
Hi , I experienced the following if (!Relational.ISNULL(input_row.Column1)) suggested by lijolawrance and it works fine. Thank you veru much. Best regards, Yves.