Vote count:
0
how do i access the first element from the results of pig's STRSPLIT function? my pig command looks like the following.
A = FOREACH mydata GENERATE STRSPLIT(myfield,'.',2) as myfield
a value of "myfield" looks like this "john.doe", so STRSPLIT should return ("john","doe"), but i only want the first element ("john" in this case) to be returned as part of the output.
asked 26 secs ago
How do I extract the first element from Pig's STRSPLIT function?
Aucun commentaire:
Enregistrer un commentaire