Do not input private or sensitive data. View Qlik Privacy & Cookie Policy.
Skip to main content

Announcements
Join us to spark ideas for how to put the latest capabilities into action. Register here!
cancel
Showing results for 
Search instead for 
Did you mean: 
Anonymous
Not applicable

[resolved] Building star scheme cube

Hi How can i build mondrian cube in talend?
i tried, but i didn't get anything.
i want something like this link " http://type-exit.org/adventures-with-open-source-bi/2010/07/a-basic-mondrian-cube-introducing-the-st..."
Thanks in advance for help.
Labels (2)
1 Solution

Accepted Solutions
Anonymous
Not applicable
Author

Hi
Using a tOracleInput to execute the below statement instead of tMysqlLastInsertedId in the above example for Oracle database.
tFixedFlowInput_1--main--tMap---out1--tOracleOutput_1--oncomponentok--tOracleInput--main--tJavaRow_1
on tOracleInput:
"select max(PK_column_name) from tableName"
Shong

View solution in original post

3 Replies
Anonymous
Not applicable
Author

Hi
You can do the same thing in Talend with the following job design:
parent job:
tFileInputExcel--main--tFlowToIterate--iterate--tRunJob
on tRunJob, pass each row read from tFileInputExcel to child job, see this KB article on Talend Help Center to know how to pass a value from parent job to child job.
child job:
tFixedFlowInput_1--main--tMap---out1--tMysqlOutput_1--main--tMysqlLastInertedID_1--main--tJavaRow_1
--out2---tMysqlOutput_2--main--tMysqlLastInertedID_2--main--tJavaRow_2
--out3---tMysqlOutput_3--main--tMysqlLastInertedID_3--main--tJavaRow_3
--out4---tMysqlOutput_4--main--tMysqlLastInertedID_4--main--tJavaRow_4
|
onsubjobok
|
tFixedFlowInput_2----main--tMysqlOutput_5
on tFixedFlowInput_1: generate the current data flow came from the parent job.
on tMysqlOutput_1: insert data into one of dimension table, for example, dim_assignee table, tMysqlLastInertedID_1 get the last inserted primary key of dim_assignee table, tJavaRow_1 store the last inserted id to a global vairable for used later, for example: globalMap.put("dim_assignee_key", input_row.last_insert_id);
...
on tFixedFlowInput_2, generate the current record with the global variables which store the primary key of dimension tables, and insert it into fact table (on tMysqlOutput_5).
Shong
Anonymous
Not applicable
Author

Hi Shong,
Thanks for your valuable solution.
but i have a problem, every time if there is new value i need to do max(ID)+1 in dimension table before insert.
with below scenario how it is possible?
how i can achieve tMysqlLastInsertedID in oracle?
can you please help me on it.
Thanks and Regards,
Chiranjeevi.
Anonymous
Not applicable
Author

Hi
Using a tOracleInput to execute the below statement instead of tMysqlLastInsertedId in the above example for Oracle database.
tFixedFlowInput_1--main--tMap---out1--tOracleOutput_1--oncomponentok--tOracleInput--main--tJavaRow_1
on tOracleInput:
"select max(PK_column_name) from tableName"
Shong