How to mass import

10 years ago
What is the easiest way to import a lot of products and categories ? I'd be moving over a store that has three levels of categories: Category -> Brand -> Model -> Accessories for that model. When all is said and done we have 1000s of Models and 100000+ accessories that match up with all of the models.

I am a decent C# and SQL developer so if I need to I can write an importer. But I'd like to see if someone else has invented that wheel first.

Thanks.
10 years ago
In current version of nopCommerce there is a way to import products in the database

Go to admin section >  Catalog > Products > Manage Products

But the limitation is in any version of nopCommerce you can only import / export product not related categories.

In all the versions of nopCommerce you can import products but you have to do category mapping manually (one by one)

You have to modify code in Export.cs and Import.cs and you can add category mapping functionality in the import feature

or there is another way to accomplish it by writing some SQL Stored Procedures

Hope it helps
10 years ago
what are the field names for the mass import? are they the same as the database?
10 years ago
beefydog wrote:
what are the field names for the mass import? are they the same as the database?


Just Export products to excel and you will download import template
10 years ago
wheel0513 wrote:


Just Export products to excel and you will download import template
10 years ago
wheel0513 wrote:


Just Export products to excel and you will download import template


Sorry about the redundant quote... probably shouldn't drink and think at the same time.

This was a really logical response to getting the template and we appreciate it.  Unfortunately I am getting an error when I try this...

"The Microsoft Jet database engine cannot open the file ''. It is already opened exclusively by another user, or you need permission to view its data. "

I am a .NET developer but only hours new to this program, so please be kind!
10 years ago
Hi,

nop needs to be running in full trust  -  sounds like maybe you are running it in medium trust.

contact your hosting provider and ask them to set the trust level to 'full'
10 years ago
hrdfsique wrote:
wheel0513 wrote:


Just Export products to excel and you will download import template


Sorry about the redundant quote... probably shouldn't drink and think at the same time.

This was a really logical response to getting the template and we appreciate it.  Unfortunately I am getting an error when I try this...

"The Microsoft Jet database engine cannot open the file ''. It is already opened exclusively by another user, or you need permission to view its data. "

I am a .NET developer but only hours new to this program, so please be kind!


I got the same error with Softsys Hosting. They said, nopCommerce had to run in 32-bit dedicated application pool in full trust mode and after they moved my site, the error dissappeared.

Now I can import from Excel but when I try to edit a product, I get:

[SecurityException: Request for the permission of type 'System.Security.Permissions.ReflectionPermission, mscorlib, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089' failed.]
   System.Security.CodeAccessSecurityEngine.ThrowSecurityException(Assembly asm, PermissionSet granted, PermissionSet refused, RuntimeMethodHandle rmh, SecurityAction action, Object demand, IPermission permThatFailed) +150
   System.Security.CodeAccessSecurityEngine.ThrowSecurityException(Object assemblyOrString, PermissionSet granted, PermissionSet refused, RuntimeMethodHandle rmh, SecurityAction action, Object demand, IPermission permThatFailed) +100
   System.Security.CodeAccessSecurityEngine.CheckSetHelper(PermissionSet grants, PermissionSet refused, PermissionSet demands, RuntimeMethodHandle rmh, Object assemblyOrString, SecurityAction action, Boolean throwException) +283
   System.Security.PermissionSetTriple.CheckSetDemand(PermissionSet demandSet, PermissionSet& alteredDemandset, RuntimeMethodHandle rmh) +69
   System.Security.PermissionListSet.CheckSetDemand(PermissionSet pset, RuntimeMethodHandle rmh) +150
   System.Security.PermissionListSet.DemandFlagsOrGrantSet(Int32 flags, PermissionSet grantSet) +30
   System.Threading.CompressedStack.DemandFlagsOrGrantSet(Int32 flags, PermissionSet grantSet) +40
   System.Security.CodeAccessSecurityEngine.ReflectionTargetDemandHelper(Int32 permission, PermissionSet targetGrant, CompressedStack securityContext) +123
   System.Security.CodeAccessSecurityEngine.ReflectionTargetDemandHelper(Int32 permission, PermissionSet targetGrant) +54

Anybody any ideas?

Cheers - Helger
10 years ago
Solved my problem:
  <trust level="Full" /> was missing in web.config.
Restarted my website and hey presto!!!

Cheers - Helger
10 years ago
How do we mass import atribute info for a product?  Like the size/color combinations, it exports to XML, but not to excel.

Am I missing something?  v. 1.80