Posts

Showing posts with the label Data Cleansing

S ) string_replace example

Image
      1A- id   1A- id   1|2| 3  replace to 1||2||3     Reformat     begin   Out.id : : String_replace (in.id ,”| ” ,”| |””);   End   Or   Reformat     begin   Out.id : : string_join ( string_split_no_empty (in.id ,”| ”) ,”| |”);   E nd   1B   In the 2 nd example input file1 to input7 contain one one letter like (1----7) if you are gathering all the input file using reformat and pass the  select condition next_in_sequence () <5 then what will  be the out put .   Ans --4      

S) Header trailer scenario using reformat & lookup

Image
          FBE   Next_in_sequence ==1;   Reformat   output_index_ out : : output_index (in) =   begin     output_index_ out : : if ( next_in_sequence () == lookup_count ( " hh " ) ) 1 else 0;   end ;