using oetl to import table from mysql

78 views
Skip to first unread message

Sam

unread,
Aug 15, 2015, 10:21:56 AM8/15/15
to OrientDB
orientdb is saving integer field in source mysqldb tale as string during import using oetl...any idea why it is doing this and what can be done to prevent it?


alessand...@gmail.com

unread,
Aug 17, 2015, 3:23:06 AM8/17/15
to OrientDB
Hi Sam,
in the file .json you can define the type of your fields as follows

{ "csv": { "separator": ",", 
      "columns":[ "date:datetime", 
       "type:string", 
 "phone:string", 
 "old_token:string", 
 "new_token:string"] 
    } 
},

Regards,
Alessandro

Saurabh Jain

unread,
Aug 17, 2015, 10:01:28 AM8/17/15
to orient-...@googlegroups.com
Alessandro...it is strange today it worked ok for one table....is there a bug in the etl library that sometimes it works and sometimes it does not?
Also..the table is imported but I am unable to see its properties in the studio....why is that so? I am able to see properties of other tables that are created in orientdb in the studio. How can I prevent that?

Thanks
Saurabh

--

---
You received this message because you are subscribed to a topic in the Google Groups "OrientDB" group.
To unsubscribe from this topic, visit https://groups.google.com/d/topic/orient-database/LHZeDtoYqxQ/unsubscribe.
To unsubscribe from this group and all its topics, send an email to orient-databa...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.

Giulia Brignoli

unread,
Aug 18, 2015, 6:07:53 AM8/18/15
to OrientDB
Hi Sam.

you don't see any properties after the import, because etl process import the schema in modality schema-less. So this means that the properties do exist, but they aren't represented in the schema.

Regards, 
Giulia

Saurabh Jain

unread,
Aug 18, 2015, 6:32:38 AM8/18/15
to orient-...@googlegroups.com
Can this be changed so that we get the properties also?

--

Giulia Brignoli

unread,
Aug 18, 2015, 6:43:41 AM8/18/15
to OrientDB
the only way I know to convert a schema from schema-less to schema-full is to add the properties in the class from Visual Studio. 
I honestly don't think it's a perfect solution, especially if you have many properties, but unfortunately I can't think of other solutions.

Regards,
Giulia

Saurabh Jain

unread,
Aug 26, 2015, 5:02:45 AM8/26/15
to orient-...@googlegroups.com
Can you have this fixed in your next release. Issue is that the datatype should be matched. If it is bigint in source it should be long in orientdb, integer should be integer, varchar/string should be string and so on...right now it is buggy
also, the column names in source should come up as property names in orientdb...

--
Reply all
Reply to author
Forward
0 new messages