USB
USB

Reputation: 6139

Dynamic Expressions in MapReduce

Are we able to do Dynamic Expressions in Mapreduce?

Say if I am having a csv file which has 2 columns. The user is giving an expresion

col1  + col2 = col3

And when again the user wants col1 - col2 = col4.

Are we able to do this?

How to do that? Should we do all those operations in 1 Mapreduce Program or whether we need to create MapReduce program for each expressions? (dynamic change of expressions from user)

Upvotes: 2

Views: 140

Answers (1)

Nigel Tufnel
Nigel Tufnel

Reputation: 11534

As Judge Mental said in the comment you should take a look at Hive or Pig.

Using Hive you can launch MapReduce jobs with SQL queries:

SELECT col1, col2, col1 + col2 AS col3, col1 - col2 AS col4
  FROM table

Upvotes: 1

Related Questions