I am trying to extract data directly from Oracle to OrientDB using JDBC
with ETL transformation. I have 2 tables alert and other is userRead table
joined by a key column (alert_id). I am not successful in getting edges
created though vertices, indexes are successfully created with data from
source.
//alert:{
"config": {
// "log": "debug",
"parallel": true
},
"extractor" : {
"jdbc": { "driver": "oracle.jdbc.driver.OracleDriver",
"url": "jdbc:oracle:thin:@hostname:port/dbname",
"userName": "schema1",
"userPassword": "password",
"query": "select * from MC_ALERT$" }
},
"transformers" : [
{ "vertex": { "class":"MC_ALERT"} }
],"loader": {
"orientdb": {
"dbURL":
"plocal:/Users/dbadmin/workspace/orientdbEnprise2.1.8/databases/messaging",
"dbType": "graph",
"dbUser": "admin",
"dbPassword": "admin",
"dbAutoCreate": true,
"batchCommit": 1000,
"indexes": [
{
"class": "MC_ALERT",
"fields": [ "alert_uuid:string" ],
"type": "UNIQUE"
}
]
}
}}
//userRead:
{
"config": {
"parallel": true
},
"extractor" : {
"jdbc": { "driver": "oracle.jdbc.driver.OracleDriver",
"url": "jdbc:oracle:thin:@hostname:port/dbname",
"userName": "schema1",
"userPassword": "password",
"query": "select a.* from MC_ALERT_USER_READ$ a, MC_ALERT$ b
where a.alert_id = b.alert_uuid" }
},
"transformers" : [
{ "vertex": { "class":"MC_ALERT_USER_READ"} },
{ "edge": { "class": "HAS_ALERT_READ",
"joinFieldName": "ALERT_ID",
"lookup": "MC_ALERT.ALERT_UUID",
"direction": "in"
}
}
],"loader": {
"orientdb": {
"dbURL":
"plocal:/Users/dbadmin/workspace/orientdbEnprise2.1.8/databases/messaging",
"dbType": "graph",
"dbUser": "admin",
"dbPassword": "admin",
"dbAutoCreate": true,
"batchCommit": 1000,
"classes": [
{"name": "MC_ALERT","extends": "V"},
{"name": "MC_ALERT_USER_READ", "extends": "V"},
{"name": "HAS_ALERT_READ", "extends": "E"}
],
"indexes": [
{
"class": "MC_ALERT_USER_READ",
"fields": [ "client_oid:string","user_oid:string","alert_id:string"],
//"fields": [ "alert_id:string"],
"type": "UNIQUE"
}
]
}
}}
I need to create edges to establish relationship between alert and userRead
through alert_id.
--
---
You received this message because you are subscribed to the Google Groups
"OrientDB" group.
To unsubscribe from this group and stop receiving emails from it, send an email
to [email protected].
For more options, visit https://groups.google.com/d/optout.