Posting in the Magento forums has been disabled pending the implementation of a new and improved forum solution which should better serve the community.

For new questions please post at magento.stackexchange.com, the community-run support site for the Magento community. We will be providing updates on the new forum solution soon. For questions or concerns please email community@magento.com.

Magento Forum

the quest for an efficient product import script
 
dweeves
Enthusiast
 
Total Posts:  877
Joined:  2010-06-26
FRANCE
 

@antomad
use column mapper plugin and map:
associated,config_attributes
then 2 textfield will appear, one for associated, other for config_attributes

associated=>simples_skus
config_attributes=>configurable_attributes

and your configurables will be ok.

 
Magento Community Magento Community
Magento Community
Magento Community
 
dweeves
Enthusiast
 
Total Posts:  877
Joined:  2010-06-26
FRANCE
 

@criollo95

Made an update for image processor (1.0.17) avaiable here as usual.

Fixed processing where no data have to be inserted for image (strange however, since it means in that case that there is no valid target store id for inserting data)

 
Magento Community Magento Community
Magento Community
Magento Community
 
antomad
Jr. Member
 
Total Posts:  7
Joined:  2011-06-16
 

Thanks for you quick reply, but i still cant get it to work :(

i got this trying to import the csv

Running Magmi Product Import Engine v1.2.1 by dweeves
Import Mode:create
CSV Datasource v1.1 - Importing CSV : ../../var/import/importar.csv using separator [ , ] enclosing [ “ ]
Performing Datasouce Lookup…
Found 3 records, took 0.00029993057251 sec
CSV Datasource v1.1 - 20 CSV headers columns found
Column mapper v0.0.3 - Replacing Column associated by simples_skus
Column mapper v0.0.3 - Replacing Column config_attributes by configurable_attributes
Configurable Item processor v1.3.2 - no options_container set, defaulting to :Block after product info
Ajusted processed columns:22

its stuck trying to import the configurable product, any suggestion?

 
Magento Community Magento Community
Magento Community
Magento Community
 
dweeves
Enthusiast
 
Total Posts:  877
Joined:  2010-06-26
FRANCE
 

@antomad
can you PM me your magmi url so that i can check what’s going wrong.

 
Magento Community Magento Community
Magento Community
Magento Community
 
dweeves
Enthusiast
 
Total Posts:  877
Joined:  2010-06-26
FRANCE
 

@All
0.7.12rc1 pre release available here as usual.

This pre release is stable, just not incorporating all the changes i wanted in 0.7.12 but most of them.

I provided it early because latest Configurable 1.3.2 used a new utility function in the core that was not present in 0.7.11.

Thanks antomad for submitting the problem (your setup is already up to date !!!)

So for all those who are using latest configurable plugin, just update to this 0.7.12rc1 pre release, many improvements but will provide changelog this weekend. You’ll find a good surprise in the UI behaviour wink

 
Magento Community Magento Community
Magento Community
Magento Community
 
antomad
Jr. Member
 
Total Posts:  7
Joined:  2011-06-16
 

Thank you dweeves

ITS WORKING NOW what a relief, i’d been stuck for some time with this, but thanks to you i can continue smile

 
Magento Community Magento Community
Magento Community
Magento Community
 
paderEpiktet
Member
 
Avatar
Total Posts:  36
Joined:  2010-11-04
Germany
 

@criollo95

For your SQL-Error during the image import, we had exactly the same point recently. The reason was that for a multistore the name of the store that is displayed in the backend differed from the constant in the table core_store for the store.

MAGMI did not find a storeid in getStoreIdsForStoreScope and therefore

$targetsids=$this->getStoreIdsForStoreScope($item["store"]);

was empty and then the loop

foreach($targetsids as $tsid)
            
{
                $vinserts[]
="(?,?,?,?,".($imglabel==null?"NULL":"?").")";
                
$data=array_merge($data,array($vid,$tsid,$pos,$excluded?1:0));
                if(
$imglabel!=null)
                
{
                    $data[]
=$imglabel;
                
}
            }

was not executed and therefore vinserts[] was empty and that caused the SQL error.

@dweeves

Perhaps one could contemplate about reporting that getStoreIdsForStoreScope did not find a corresponding store to the user. Some users might find this info helpful.  wink

 
Magento Community Magento Community
Magento Community
Magento Community
 
antomad
Jr. Member
 
Total Posts:  7
Joined:  2011-06-16
 

hello @dweeves me again!

youre script runs wonderful but i cant get the configurable product to show on frontend

any suggestion??

 
Magento Community Magento Community
Magento Community
Magento Community
 
dweeves
Enthusiast
 
Total Posts:  877
Joined:  2010-06-26
FRANCE
 

reason is reindexing.
i would suggest you to check “on the fly reindexer” which will do main part of the job. (url_rewrite index & catalog_category_product index)
but not all of it.
you need to use also “Magmi magento reindexer” and check “catalog_product_price”

but alas, your setup on which i tested it cannot run php cli scripts , so magmi magento reindexer plugin cannot call magento indexer cli script :(
so you’ll have to run this last index (catalog_product_price) from magento backend.

 
Magento Community Magento Community
Magento Community
Magento Community
 
dweeves
Enthusiast
 
Total Posts:  877
Joined:  2010-06-26
FRANCE
 

@paderEpitktet

The code to put in store column is the store view code , not the store code.
this is explained in latest wiki
however, you’re right, i could check for it & send an error or warning in case of an invalid store code detected.

 
Magento Community Magento Community
Magento Community
Magento Community
 
antomad
Jr. Member
 
Total Posts:  7
Joined:  2011-06-16
 

Thanks again dweeves!

 
Magento Community Magento Community
Magento Community
Magento Community
 
paderEpiktet
Member
 
Avatar
Total Posts:  36
Joined:  2010-11-04
Germany
 

@dweeves

Thank you for your quick response and help with multiple store import. To be honest, I have not already understood your point.

Within the function getStoreIdsForStoreScope I see the following code:

$cs=$this->tablename("core_store");
$sql="SELECT csmain.store_id from $cs as csmain WHERE csmain.code IN ($qcolstr)";

In Magento 1.5.1.0 the table core_store has the following attributes:

store_id     
    code     
    website_id     
    group_id     
    name     
    sort_order     
    is_active

What we have observed is, that when we used the content of the core_store.code in the column store in the csv-import file,
than the SQL-statement that was build in addImageToGallery in version 1.0.16 of the image processor was okay.

With best regards,

Andreas

 
Magento Community Magento Community
Magento Community
Magento Community
 
dweeves
Enthusiast
 
Total Posts:  877
Joined:  2010-06-26
FRANCE
 

the value to put in store colum is this one (highlited in yellow)

Image Attachments
sv.png
 
Magento Community Magento Community
Magento Community
Magento Community
 
paderEpiktet
Member
 
Avatar
Total Posts:  36
Joined:  2010-11-04
Germany
 

@dweeves

Thank you for your clear and fast explanation!

Yes, that is the code we used (in the end).

With best regards,

Andreas

 
Magento Community Magento Community
Magento Community
Magento Community
 
paderEpiktet
Member
 
Avatar
Total Posts:  36
Joined:  2010-11-04
Germany
 

@dweeves

Thank you again for your support and your great tool.

The import of configurable products and images under 1.5.1.0 worked without problems, the project is online.

With best regards

Andreas

 
Magento Community Magento Community
Magento Community
Magento Community
Magento Community
Magento Community
Back to top