hadoop - How to pass Columns itself as parameter in PIG scripts -


in pig script want pass column position parameter, please let me know how can achieve that

a = load '$path' using pigstorage(''); b = group $countcolpos; c = foreach b generate group,count(a); d =  order c $0; store d  '$tempcountdir'; 

here how can pass value $countcolpos, using -p option comma

this works me:

$ pig -p \$0 script.pig

you need escape dollar sign shell doesn't treat environmental variable.


Comments

Popular posts from this blog

javascript - Jquery show_hide, what to add in order to make the page scroll to the bottom of the hidden field once button is clicked -

javascript - Highcharts multi-color line -

javascript - Enter key does not work in search box -