Another Product Import Issue

A forum where issues related to the DataPort utility can be discussed.
Post Reply
VoShay
Ensign (ENS)
Ensign (ENS)
Posts: 19
Joined: Wed Aug 12, 2009 11:07 am

Another Product Import Issue

Post by VoShay » Thu Aug 20, 2009 2:38 pm

Here's my latest foul-up-
Exception has been thrown by the target of an invocation.
ImportOrUpdate unsuccessful for Product
ProductId = 0
Name = 1.3mm to 2.1mm DC Power Plug Adaptor
Error message: Exception has been thrown by the target of an invocation.

at System.RuntimeMethodHandle._InvokeMethodFast(Object target, Object[] arguments, SignatureStruct& sig, MethodAttributes methodAttributes, RuntimeTypeHandle typeOwner)
at System.RuntimeMethodHandle.InvokeMethodFast(Object target, Object[] arguments, Signature sig, MethodAttributes methodAttributes, RuntimeTypeHandle typeOwner)
at System.Reflection.RuntimeMethodInfo.Invoke(Object obj, BindingFlags invokeAttr, Binder binder, Object[] parameters, CultureInfo culture, Boolean skipVisibilityChecks)
at System.Reflection.RuntimeMethodInfo.Invoke(Object obj, BindingFlags invokeAttr, Binder binder, Object[] parameters, CultureInfo culture)
at System.Reflection.MethodBase.Invoke(Object obj, Object[] parameters)
at CommerceBuilder.DataClient.Api.ObjectHandlers.ImportHandler.<.ctor>b__36(Object& acObject)
at CommerceBuilder.DataClient.Api.ObjectHandlers.ImportHandler.ImportChildObjectsArray(Array schemaObjectsArray, Type acType, String objName, String idFieldName, String displayNamePropertyName, Object parentId, TryLoadExistingObject tryLoadExistingObject, TranslateObjectAssociatedIds translateObjectAssociatedIds, SaveACObject saveACObject, ImportObjectChildsAndAssociations importObjectChildsAndAssociations, String csvFields)

User avatar
Naveed
Rear Admiral (RADM)
Rear Admiral (RADM)
Posts: 611
Joined: Thu Apr 03, 2008 4:48 am

Re: Another Product Import Issue

Post by Naveed » Sun Aug 30, 2009 9:11 pm

I am unable to reproduce the case with the provided data.

You have not provided the complete stack trace in you exception details, but I think you are getting some SQL truncation error , if so, then please revise the CSV data and see if data for product (for which you are getting an error ) is not exceeding the max field length limits.

VoShay
Ensign (ENS)
Ensign (ENS)
Posts: 19
Joined: Wed Aug 12, 2009 11:07 am

Re: Another Product Import Issue

Post by VoShay » Wed Sep 02, 2009 4:59 pm

Here's my error data for my two lines that won't upload.

User avatar
Naveed
Rear Admiral (RADM)
Rear Admiral (RADM)
Posts: 611
Joined: Thu Apr 03, 2008 4:48 am

Re: Another Product Import Issue

Post by Naveed » Sun Sep 13, 2009 11:03 pm

I have reviewed the provided log files and found that all logged errors or the same type, similar this one:
ImportOrUpdate unsuccessful for Product
ProductId = 0
Name = Right angle coax power plug.2.1mm I.D.,5.5mm O.D. with solder terminals .22in x .1in cable opening.
Error message: Exception has been thrown by the target of an invocation.
Base Exception: String or binary data would be truncated.
It indicates a SQL exception when inserting data in to database. The truncation error occurs when some string type data exceeds the respective database field length. You have to manually review your data for failed products and for lengthy field the data should be trimmed before import.

VoShay
Ensign (ENS)
Ensign (ENS)
Posts: 19
Joined: Wed Aug 12, 2009 11:07 am

Re: Another Product Import Issue

Post by VoShay » Wed Sep 16, 2009 4:33 pm

Managed to fix it all up and find the the problems. Everything is importing fine now. Thanks for the assistance again Naveed.

Post Reply