Press Ctrl / CMD + C to copy this to your clipboard.
This post will be reported to the moderators as potential spam to be looked at
I'm importing data from another CMS and need to populate data types of Umbraco.MultipleMediaPicker and Umbraco.RelatedLinks, can you let me know the format of the object CMSImport needs from a Field Provider for each of these data types.
Also on the MultipleMediaPicker will CMSImport also import the media if setup to do so?
MediaPicker should work. The related links I am not 100% sure of. Did you test?
Media should work fine indeed.
I did try both of these but am not sure what format you're expecting the object returned from the field provider to be in.
It's what Umbraco expects for these values if CMSimport doesn't have a provider for this. Just check the cmsPropertyData table how the value is stored and make sure your fieldprovider returns the same format.
Hope this helps,
I've got this mostly working now. The problems came down to interpreting the Related Links with Media property types I was using on my old Umbraco 4 website.
I can now convert external links correctly but could do with help on the following final issues.
For internal links I have the ID of the node which was linked to on the V4 site but need to get the imported node ID on my new V7 site. Do you have any code which would show me how to query the CMS Import Relation table?
Similarly I have a media (document) ID on my V4 site that I need to get the old media path for so I can provide it back for the normal data provider to perform an import. Again do you have any code which would demonstrate how to query media of the old database?
Many Thanks for the continued help.
I query the UmbracoNode table and the cmsPropertyData table for that info to get the old data from the old database. In the Umbraco Data provider.
It's best to query the CMSImportmediarelation table directly if you have the id since the internal API queries based on filenames.
Think I get that. For the media I'd need to query the old data from the old database as the media may not yet be imported. Is it possible for me to get to the connection string or do you have APIs to query the data?
On the FieldProvider options you should see the importstate which contains the dataprovider. That contains the datasource which is the connection string to your old database.
Hope this helps,
Thanks for that I am there now and have managed to import everything!
Thanks for all your help.
is working on a reply...
Write your reply to:
Image will be uploaded when post is submitted