Support Questions

Find answers, ask questions, and share your expertise

Sandbox 2.4 Step 3.4.1 Execute Pig Script - "ERROR 2997: Encountered IOException. File –useHCatalog does not exist"

Contributor

Copied script from tutorial:

a = LOAD 'geolocation' using org.apache.hive.hcatalog.pig.HCatLoader();

b = filter a by event != 'normal'; c = foreach b generate driverid, event, (int) '1' as occurance; d = group c by driverid; e = foreach d generate group as driverid, SUM(c.occurance) as t_occ; g = LOAD 'drivermileage' using org.apache.hive.hcatalog.pig.HCatLoader(); h = join e by driverid, g by driverid; final_data = foreach h generate $0 as driverid, $1 as events, $3 as totmiles, (float) $3/$1 as riskfactor; store final_data into 'riskfactor' using org.apache.hive.hcatalog.pig.HCatStorer();

I have -useHCatalog as "Arguments". Checked to run on TeZ.

No data loaded into the riskfactor table.

1 ACCEPTED SOLUTION
2 REPLIES 2

Contributor

Bingo. I copied "–useHCatalog" instead of "-useHCatalog". The first character was the "long dash" character instead of the "short dash" character. The font in tutorial document should be changed to use the short dash. Or the user should just copy the correct text where it is actually double quoted. 😉

Thanks.

Take a Tour of the Community
Don't have an account?
Your experience may be limited. Sign in to explore more.