Hi,
I'm relatively new to OrientDB and I am trying to learn more about how use
the ETL module to load data to a database and I have two unrelated
questions.
1. is it possible to upload data using the ETL to a database implementing
record level security ?
2. when using the merge option in the transformer block it fails with
"cannot be cast to orientdb" error, what is wrong with the code ?
here is the code :
{ "config": {
"log":"info",
"fileName":"/home/jenica/data/gjb2pyX.csv",
"haltOnError":true,
"databasePath":"/home/jenica/programs/orientdb-community-2.1.0/databases/",
"databaseName":"testing9c",
"className":"variant_L1_new"
},
"begin":[
{"let":{"name":"$database","value":"plocal:/home/jenica/programs/orientdb-community-2.1.0/databases/testing9c"}}
],
"source": { "file": { "path": "$fileName" } },
"extractor": { "row": {} },
"transformers": [
{ "csv": {"separator":",","nullValue":"NULL","columnsOnFirstLine":true}
},
{ "vertex":{"class":"$className","skipDuplicates":true} },
{"merge":{"joinFieldName":"variantID","lookup":"variant_L1.variantID"}}
],
"loader": {
"orientdb": {
"dbURL": "$database",
"AutoCreate":true,
"dbType": "graph",
"classes": [
{"name": "$className", "extends": "V"}
], "indexes": [
{"class":"variant_L1_new", "fields":["coordinate:string",
"start:integer","chromosome:string"], "type":"NOTUNIQUE" },
]
}
}
}
here is the error :
BEGIN ETL PROCESSOR
Error in Pipeline execution: java.lang.ClassCastException:
com.orientechnologies.orient.core.sql.query.OResultSet cannot be cast to
com.orientechnologies.orient.core.record.impl.ODocument
java.lang.ClassCastException:
com.orientechnologies.orient.core.sql.query.OResultSet cannot be cast to
com.orientechnologies.orient.core.record.impl.ODocument
at
com.orientechnologies.orient.etl.transformer.OMergeTransformer.executeTransform(OMergeTransformer.java:70)
at
com.orientechnologies.orient.etl.transformer.OAbstractTransformer.transform(OAbstractTransformer.java:37)
at
com.orientechnologies.orient.etl.OETLPipeline.execute(OETLPipeline.java:114)
at
com.orientechnologies.orient.etl.OETLProcessor.executeSequentially(OETLProcessor.java:487)
at
com.orientechnologies.orient.etl.OETLProcessor.execute(OETLProcessor.java:291)
at
com.orientechnologies.orient.etl.OETLProcessor.main(OETLProcessor.java:161)
ETL process halted:
com.orientechnologies.orient.etl.OETLProcessHaltedException:
java.lang.ClassCastException:
com.orientechnologies.orient.core.sql.query.OResultSet cannot be cast to
com.orientechnologies.orient.core.record.impl.ODocument
thanks
Jenica
--
---
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.