apache pig - Use parameter values in Pig foreach -


is possible use parameter values in pig foreach generate?

maybe this:

*%default todays_date `date  +%y/%m/%d`; 

a = foreach lines generate line2, id, $todays_date line2, id, today;*

or have create udf append current date schema instead?

this should work. $value substituted whatever value supply using -param.

e.g.

pig -param todays_date=value myscript.pig 

Comments

Popular posts from this blog

c# - DetailsView in ASP.Net - How to add another column on the side/add a control in each row? -

javascript - firefox memory leak -

Trying to import CSV file to a SQL Server database using asp.net and c# - can't find what I'm missing -