Copied to clipboard

Flag this post as spam?

This post will be reported to the moderators as potential spam to be looked at


  • Chris Foot 61 posts 93 karma points
    Mar 30, 2016 @ 13:12
    Chris Foot
    0

    Multiple imports with same SQL IDs clashing

    I am having an issue with the latest version of CMSImport. I have two unrelated imports set up, one for articles another for products. Unfortunately I am having some issues with them clashing. They are both using the same sql data source and have issues if they share ids. For example:

    If I have an article with ID 1 and I run the import, all is fine. If I then run the products import and one of my products has the same ID (1) it will refuse to import. Additionally, if I select the delete old items option, it will delete any items from the other import which don't appear with an ID in this import.

    If it helps, I have noticed that the CMSImportRelations table stores all of the imported items with the data source key "Sql serverIDx" so it is clearly not able to work out which import each thing is for. I suspect I can get around this by using SQL to rename the ID field but it's a little annoying!

    Thanks

    Chris

  • Richard Soeteman 4046 posts 12899 karma points MVP 2x
    Mar 31, 2016 @ 05:06
    Richard Soeteman
    0

    Hi Chris,

    This is by design. A relation is created based on [Data provider alias][Primary key name][Primary key value] so make sure primary key field is unique in your sql.

    Best,

    Richard

  • Robert J. Bullock 386 posts 405 karma points
    Jun 02, 2016 @ 16:28
    Robert J. Bullock
    0

    Richard, that is not super intuitive and I don't believe CMS Import warns you about it. My ID's clashed and now my data is in a bit of a mess.

  • Robert J. Bullock 386 posts 405 karma points
    Jun 02, 2016 @ 17:02
    Robert J. Bullock
    0

    Actually cost me half a day figuring this out.

  • Richard Soeteman 4046 posts 12899 karma points MVP 2x
    Jun 02, 2016 @ 17:31
    Richard Soeteman
    0

    Sorry to hear Robert,

    With bulkmanager free version you can delete old records when needed.

    Best,

    Richard

  • Robert J. Bullock 386 posts 405 karma points
    Jun 02, 2016 @ 18:21
    Robert J. Bullock
    0

    That's okay, I figured it out but it was pretty frustrating. It seems it'd be an easy fix to include some extra meta data in the import log to eliminate this problem.

Please Sign in or register to post replies

Write your reply to:

Draft