{"action":"created","issue":{"url":"https://api.github.com/repos/keeps/db-preservation-toolkit/issues/183","repository_url":"https://api.github.com/repos/keeps/db-preservation-toolkit","labels_url":"https://api.github.com/repos/keeps/db-preservation-toolkit/issues/183/labels{/name}","comments_url":"https://api.github.com/repos/keeps/db-preservation-toolkit/issues/183/comments","events_url":"https://api.github.com/repos/keeps/db-preservation-toolkit/issues/183/events","html_url":"https://github.com/keeps/db-preservation-toolkit/issues/183","id":149727159,"number":183,"title":"Primary key name is lost when converting SIARD2 to MySQL","user":{"login":"chalkos","id":98429,"avatar_url":"https://avatars.githubusercontent.com/u/98429?v=3","gravatar_id":"","url":"https://api.github.com/users/chalkos","html_url":"https://github.com/chalkos","followers_url":"https://api.github.com/users/chalkos/followers","following_url":"https://api.github.com/users/chalkos/following{/other_user}","gists_url":"https://api.github.com/users/chalkos/gists{/gist_id}","starred_url":"https://api.github.com/users/chalkos/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/chalkos/subscriptions","organizations_url":"https://api.github.com/users/chalkos/orgs","repos_url":"https://api.github.com/users/chalkos/repos","events_url":"https://api.github.com/users/chalkos/events{/privacy}","received_events_url":"https://api.github.com/users/chalkos/received_events","type":"User","site_admin":false},"labels":[{"url":"https://api.github.com/repos/keeps/db-preservation-toolkit/labels/data%20loss","name":"data loss","color":"f1c40f"},{"url":"https://api.github.com/repos/keeps/db-preservation-toolkit/labels/MySQL","name":"MySQL","color":"207de5"}],"state":"open","locked":false,"assignee":{"login":"chalkos","id":98429,"avatar_url":"https://avatars.githubusercontent.com/u/98429?v=3","gravatar_id":"","url":"https://api.github.com/users/chalkos","html_url":"https://github.com/chalkos","followers_url":"https://api.github.com/users/chalkos/followers","following_url":"https://api.github.com/users/chalkos/following{/other_user}","gists_url":"https://api.github.com/users/chalkos/gists{/gist_id}","starred_url":"https://api.github.com/users/chalkos/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/chalkos/subscriptions","organizations_url":"https://api.github.com/users/chalkos/orgs","repos_url":"https://api.github.com/users/chalkos/repos","events_url":"https://api.github.com/users/chalkos/events{/privacy}","received_events_url":"https://api.github.com/users/chalkos/received_events","type":"User","site_admin":false},"milestone":{"url":"https://api.github.com/repos/keeps/db-preservation-toolkit/milestones/1","html_url":"https://github.com/keeps/db-preservation-toolkit/milestones/v2.0.0","labels_url":"https://api.github.com/repos/keeps/db-preservation-toolkit/milestones/1/labels","id":892729,"number":1,"title":"v2.0.0","description":"Added support for input and ouput into SIARD, a database preservation format created by the Swiss National Archives","creator":{"login":"luis100","id":631728,"avatar_url":"https://avatars.githubusercontent.com/u/631728?v=3","gravatar_id":"","url":"https://api.github.com/users/luis100","html_url":"https://github.com/luis100","followers_url":"https://api.github.com/users/luis100/followers","following_url":"https://api.github.com/users/luis100/following{/other_user}","gists_url":"https://api.github.com/users/luis100/gists{/gist_id}","starred_url":"https://api.github.com/users/luis100/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/luis100/subscriptions","organizations_url":"https://api.github.com/users/luis100/orgs","repos_url":"https://api.github.com/users/luis100/repos","events_url":"https://api.github.com/users/luis100/events{/privacy}","received_events_url":"https://api.github.com/users/luis100/received_events","type":"User","site_admin":false},"open_issues":35,"closed_issues":13,"state":"open","created_at":"2014-12-05T10:08:48Z","updated_at":"2016-04-20T13:10:17Z","due_on":"2016-06-29T23:00:00Z","closed_at":null},"comments":3,"created_at":"2016-04-20T10:23:26Z","updated_at":"2016-04-26T09:46:25Z","closed_at":null,"body":"Reproduced using dbptk-app-2.0.0-beta4.0.jar\r\n\r\n1. I did an export from Postgre to SIARD-2\r\n[metadataPostgre.xml.txt](https://github.com/keeps/db-preservation-toolkit/files/227633/metadataPostgre.xml.txt)\r\n\r\n2. I imported this file to MySQL\r\n3. and then I exported MySQL to SIARD-2\r\n[metadataMySQL.xml.txt](https://github.com/keeps/db-preservation-toolkit/files/227641/metadataMySQL.xml.txt)\r\n\r\n4. I compared the files metadataPostgre.xml and metadataMySQL.xml\r\n\r\nFor example in line 173 Postgre has <name>pk_admin_unit</name> but MySQL has <name>PRIMARY</name>\r\n\r\nOriginally reported by @Laurira"},"comment":{"url":"https://api.github.com/repos/keeps/db-preservation-toolkit/issues/comments/214686596","html_url":"https://github.com/keeps/db-preservation-toolkit/issues/183#issuecomment-214686596","issue_url":"https://api.github.com/repos/keeps/db-preservation-toolkit/issues/183","id":214686596,"user":{"login":"chalkos","id":98429,"avatar_url":"https://avatars.githubusercontent.com/u/98429?v=3","gravatar_id":"","url":"https://api.github.com/users/chalkos","html_url":"https://github.com/chalkos","followers_url":"https://api.github.com/users/chalkos/followers","following_url":"https://api.github.com/users/chalkos/following{/other_user}","gists_url":"https://api.github.com/users/chalkos/gists{/gist_id}","starred_url":"https://api.github.com/users/chalkos/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/chalkos/subscriptions","organizations_url":"https://api.github.com/users/chalkos/orgs","repos_url":"https://api.github.com/users/chalkos/repos","events_url":"https://api.github.com/users/chalkos/events{/privacy}","received_events_url":"https://api.github.com/users/chalkos/received_events","type":"User","site_admin":false},"created_at":"2016-04-26T09:46:24Z","updated_at":"2016-04-26T09:46:24Z","body":"> Seems like the application is losing the action of the foreignKey as well\r\n\r\nThis is not critical information when converting the database (priorities are the data, then structure and only then an attempt is made to save behaviour such as the foreign key actions).\r\n\r\n> Also for mysql the application is not adding the nextval('auvik_keel_id_seq'::regclaas) \r\nOn the second step, the import to MySQL, the default value may be lost (due to reasons I described in my previous comment, https://github.com/keeps/db-preservation-toolkit/issues/183#issuecomment-212370203)\r\n\r\nThe typeOriginal changing to int is because when converting the SIARD to MySQL, the MySQL data type created was INT, when creating a SIARD from MySQL, the INT type is perceived as the original type."}}