Dear Wiki user,

You have subscribed to a wiki page or wiki category on "Pig Wiki" for change 
notification.

The following page has been changed by CorinneC:
http://wiki.apache.org/pig/PigFaq

------------------------------------------------------------------------------
- 1. I'm using PigStorage to parse my input files. Can I make it use control 
characters as delimiters?
+ ===== 1. I'm using PigStorage to parse my input files. Can I make it use 
control characters as delimiters? ===== 
  
  Ans. Yes. The first parameter to PigStorage is the dataset name, the second 
is a regular expression to describe the delimiter. We used String.split(regex, 
-1) to extract fields from lines. See 
http://java.sun.com/j2se/1.5.0/docs/api/java/util/regex/Pattern.html for more 
information on the way to use special characters in regex. For example "load 
'input.dat' using PigStorage('\u0001');" will use ^A as a delimiter.
  

Reply via email to