Jump to content
  • Checkout
  • Login
  • Get in touch

osCommerce

The e-commerce.

Easy Populate & Products Attributes


VJ

Recommended Posts

that was the latest update to the contrib: http://www.oscommerce.com/community/contributions,500

 

 

Nat:

 

I just installed OSC this AM..testing for a possible move from Zencart.

 

I have a bone stock database and install, and I thought I would try that ID hack.

 

The index hack went in fine, and I installed easypopulate3 without any issues..now I get this error when I try to download the stock products listings:

 

1146 - Table 'gemohler_osc.TABLE_PRODUCTS_STOCK' doesn't exist

 

select products_stock_quantity from TABLE_PRODUCTS_STOCK where products_id = '1' and products_stock_attributes = '3-5'

 

[TEP STOP]

 

I _really_ wanna see OSC work better than ZC, just gotta get EP to work fast(er) than it will otherwise..which can take me a day to upload things.

 

Thanks!

Link to comment
Share on other sites

Hi, sorry but can't really help you - it's not my hack I was just posting the location as someone asked. Perhaps try and PM the person who posted it, user 'UGLi'.

 

I haven't even tried it myself yet.

 

Good luck!

 

Nat:

 

I just installed OSC this AM..testing for a possible move from Zencart.

 

I have a bone stock database and install, and I thought I would try that ID hack.

 

The index hack went in fine, and I installed easypopulate3 without any issues..now I get this error when I try to download the stock products listings:

 

1146 - Table 'gemohler_osc.TABLE_PRODUCTS_STOCK' doesn't exist

 

select products_stock_quantity from TABLE_PRODUCTS_STOCK where products_id = '1' and products_stock_attributes = '3-5'

 

[TEP STOP]

 

I _really_ wanna see OSC work better than ZC, just gotta get EP to work fast(er) than it will otherwise..which can take me a day to upload things.

 

Thanks!

Edited by nat8100
Link to comment
Share on other sites

Hi, sorry but can't really help you - it's not my hack I was just posting the location as someone asked. Perhaps try and PM the person who posted it, user 'UGLi'.

 

I haven't even tried it myself yet.

 

Good luck!

 

ya..I did. Hes never posted as far as the system can tell, so we'll see.

Link to comment
Share on other sites

This fix is a smart move...an index, by definition, is unique...

 

Hugh, I'm glad you like my fix. I'm afraid I have to point out that while an index can be unique, that is only the case if you explicitly define it to be. An index can use the optional flags UNIQUE, FULLTEXT, or SPATIAL. The whole point of a MySQL index is to prevent a search from reading the entire row. It's like creating a compressed version of the table with only one column. Since the products table contains a lot of columns (and I've added a few on my custom install), I really don't see any down side to indexing the model column. The speed increase for Easy Populate should go up logarithmically for every column it doesn't have to read when searching to see if a product already exists.

 

Tim

Link to comment
Share on other sites

...I installed easypopulate3 without any issues..now I get this error when I try to download the stock products listings:

1146 - Table 'gemohler_osc.TABLE_PRODUCTS_STOCK' doesn't exist

 

Jeff, stock osCommerce doesn't have a "products_stock" table, and stock Easy Popluate doesn't look for that table either. If the code is looking for this table, something must have been modified. Are you running a Linux or Windows server? On Linux I would suggest running a 'grep -l -r "TABLE_PRODUCTS_STOCK" *' command to find out where that table is defined, and which pages are looking for it.

 

You also mentioned that you're running version 3 of Easy Populate, which has been "disowned" by the author himself. I would suggest using an older version (between 2.8 and 2.9) that stores the configuration variables in the database like most other user friendly contribs.

 

Tim

 

By the way, I have a HUGE inventory, and to import and update 100,000 products using a heavily modified Easy Populate (it updates a lot more columns in the database, automatically updates pricing according to a table defined through the admin section, updates inventory hourly and checks for new products weekly through cron), it only takes SIX MINUTES to update every field!

Link to comment
Share on other sites

Hugh, I'm glad you like my fix. I'm afraid I have to point out that while an index can be unique, that is only the case if you explicitly define it to be. An index can use the optional flags UNIQUE, FULLTEXT, or SPATIAL. The whole point of a MySQL index is to prevent a search from reading the entire row. It's like creating a compressed version of the table with only one column. Since the products table contains a lot of columns (and I've added a few on my custom install), I really don't see any down side to indexing the model column. The speed increase for Easy Populate should go up logarithmically for every column it doesn't have to read when searching to see if a product already exists.

 

Tim

 

Hi Tim

 

Thanks for the clarification:-) on this. I'm still wondering why EP does not run on product ID instead: it might help to handle the products extra fields pouplation in a separate upload. or maybe I'm missing something. My dream would have to get all the extra fields generated like the categories - even with a 6 or 8 limit -

Link to comment
Share on other sites

Try: Look for $products_attributes_stock = true; in your easypopulate.php file. Change 'true' to 'false.'

 

Nat:

 

I just installed OSC this AM..testing for a possible move from Zencart.

 

I have a bone stock database and install, and I thought I would try that ID hack.

 

The index hack went in fine, and I installed easypopulate3 without any issues..now I get this error when I try to download the stock products listings:

 

1146 - Table 'gemohler_osc.TABLE_PRODUCTS_STOCK' doesn't exist

 

select products_stock_quantity from TABLE_PRODUCTS_STOCK where products_id = '1' and products_stock_attributes = '3-5'

 

[TEP STOP]

 

I _really_ wanna see OSC work better than ZC, just gotta get EP to work fast(er) than it will otherwise..which can take me a day to upload things.

 

Thanks!

Link to comment
Share on other sites

Jeff, stock osCommerce doesn't have a "products_stock" table, and stock Easy Popluate doesn't look for that table either. If the code is looking for this table, something must have been modified. Are you running a Linux or Windows server? On Linux I would suggest running a 'grep -l -r "TABLE_PRODUCTS_STOCK" *' command to find out where that table is defined, and which pages are looking for it.

 

You also mentioned that you're running version 3 of Easy Populate, which has been "disowned" by the author himself. I would suggest using an older version (between 2.8 and 2.9) that stores the configuration variables in the database like most other user friendly contribs.

 

Tim

 

By the way, I have a HUGE inventory, and to import and update 100,000 products using a heavily modified Easy Populate (it updates a lot more columns in the database, automatically updates pricing according to a table defined through the admin section, updates inventory hourly and checks for new products weekly through cron), it only takes SIX MINUTES to update every field!

 

..and early in the evening on the third day, God created grep..

 

Results:

 

-jailshell-2.05b$ grep -l -r "TABLE_PRODUCTS_STOCK" *

EasyPopulate 3.00/catalog/admin/easypopulate.php

admin/easypopulate.php

 

 

Soooooo..offto install an earlier version, if adjusting the current one doesnt pan out.

 

thanks to ya both

Edited by gemohler
Link to comment
Share on other sites

You also mentioned that you're running version 3 of Easy Populate, which has been "disowned" by the author himself. I would suggest using an older version (between 2.8 and 2.9) that stores the configuration variables in the database like most other user friendly contribs.

 

Still having issues..Im seeing other issues in

 

I installed the what appears to be complete 2.9 version..and I get this when I try to make a file to download:

 

1054 - Unknown column 'p.products_price1_qty' in 'field list'

 

SELECT p.products_id as v_products_id, p.products_model as v_products_model, p.products_image as v_products_image, p.products_price as v_products_price, p.products_price1_qty as v_products_price1_qty, p.products_price1 as v_products_price1, p.products_price2_qty as v_products_price2_qty, p.products_price2 as v_products_price2, p.products_price3_qty as v_products_price3_qty, p.products_price3 as v_products_price3, p.products_price4_qty as v_products_price4_qty, p.products_price4 as v_products_price4, p.products_price5_qty as v_products_price5_qty, p.products_price5 as v_products_price5, p.products_price6_qty as v_products_price6_qty, p.products_price6 as v_products_price6, p.products_price7_qty as v_products_price7_qty, p.products_price7 as v_products_price7, p.products_price8_qty as v_products_price8_qty, p.products_price8 as v_products_price8, p.products_qty_blocks as v_products_qty_blocks, p.products_weight as v_products_weight, p.products_date_available as v_date_avail, p.products_date_added as v_date_added, p.products_tax_class_id as v_tax_class_id, p.products_quantity as v_products_quantity, p.manufacturers_id as v_manufacturers_id, subc.categories_id as v_categories_id, p.products_status as v_status FROM products as p, categories as subc, products_to_categories as ptoc WHERE p.products_id = ptoc.products_id AND ptoc.categories_id = subc.categories_id

 

[TEP STOP]

 

 

So..I have a busted EP in zencart, and in a stockish OSC.

 

I know..the common element is me, but I dont -mess- with databases..I just report errors FROM them.

Link to comment
Share on other sites

...I'm still wondering why EP does not run on product ID instead: it might help to handle the products extra fields pouplation in a separate upload. or maybe I'm missing something. My dream would have to get all the extra fields generated like the categories - even with a 6 or 8 limit -

 

The products_id is generated by MySQL as an auto-increment field. Its purpose is to tie multiple osCommerce tables together, but outside osCommerce is has no usefulness as there's no way to tie it to a product.

 

I looked at products extra fields, and while it does make adding more detailed product information nice and easy, it's fairly inefficient. I ended up just adding columns to the products table and everything works out much better. If you have a product detail you'd like to add with a small number of values that are common to many products, you could duplicate the functionality of the manufacturers and manufacturers_info tables.

 

Tim

Link to comment
Share on other sites

I There:

 

I have been using the complete file for Easypopulate successfully for about two weeks.

Only now I had the need to use the Product Attributes and I ran into a problem:

When I add a product option in the Product attributes I can still download the complete file but when I go one step further and add a product option value I can no longer download the complete file.

I get the following error:

 

 

1146 - Table 'loja_menasboutique_com.TABLE_PRODUCTS_STOCK' doesn't exist

 

select products_stock_quantity from TABLE_PRODUCTS_STOCK where products_id = '28' and products_stock_attributes = '1-1'

 

 

I guess I must uncomment something in the file but I can not find where. Please some one help.

Link to comment
Share on other sites

there is a fix for php5, some of the later versions probably dont include this, it is discussed in the thread and older versions.

Link to comment
Share on other sites

I looked at products extra fields, and while it does make adding more detailed product information nice and easy, it's fairly inefficient. I ended up just adding columns to the products table and everything works out much better. If you have a product detail you'd like to add with a small number of values that are common to many products, you could duplicate the functionality of the manufacturers and manufacturers_info tables.

Tim

 

That's what I did first (add new fields to the product table) but when my need to add more fields as my business inventory diversified, I found the MOD that installs extra fields in a separate table much more elegant, until I found that EP doesn't directly take care of that, and that these fields are not duplicated when copying a product (I'm working on this)

Link to comment
Share on other sites

Hi mates,

I've searched in the forum but I did not find the answer. I'm running EP 2.79b MS2 and everything's fine except when I download an excel file to my computer, each

"

are replaced with

& # 3 4 (I have to put space between each characters else the code is interpreted!!

Have you a trick for me to correct it ?

The "Replace quotes" option in the admin is FALSE. If I put True, the result is the same.

 

Hopefully When I upload an ep file to the db the quotes are still corrects.

Any idea ?

thanks.

Seb

Edited by concorde44

Osc 2.2 MS2

Link to comment
Share on other sites

I'm not sure. Have you looked at the option in your easypopulate.php file?

 

// **** Quote -> Escape character conversion ****
// If you have extensive html in your descriptions and it's getting mangled on upload, turn this off
// set to 1 = replace quotes with escape characters
// set to 0 = no quote replacement
global $replace_quotes;
$replace_quotes = true;

 

You could try a different setting there.

 

 

Hi mates,

I've searched in the forum but I did not find the answer. I'm running EP 2.79b MS2 and everything's fine except when I download an excel file to my computer, each

"

are replaced with

& # 3 4 (I have to put space between each characters else the code is interpreted!!

Have you a trick for me to correct it ?

The "Replace quotes" option in the admin is FALSE. If I put True, the result is the same.

 

Hopefully When I upload an ep file to the db the quotes are still corrects.

Any idea ?

thanks.

Seb

Link to comment
Share on other sites

Hi all

 

I have just opened a new store using easy populate 2.9 and have managed to get products uploaded.....

 

However when i come to downloading in any setting eg. complete,froogle etc all i get is the heading line! Any ideas? pleases!!!!

Link to comment
Share on other sites

I There:

 

I have been using the complete file for Easypopulate successfully for about two weeks.

Only now I had the need to use the Product Attributes and I ran into a problem:

When I add a product option in the Product attributes I can still download the complete file but when I go one step further and add a product option value I can no longer download the complete file.

I get the following error:

 

 

1146 - Table 'loja_menasboutique_com.TABLE_PRODUCTS_STOCK' doesn't exist

 

select products_stock_quantity from TABLE_PRODUCTS_STOCK where products_id = '28' and products_stock_attributes = '1-1'

 

This only happens when I add a value to the product option. I have downloaded over 2000 products up to now but in oder to continue I have to delete the value.Once I do that It works again. Any ideas?????

Link to comment
Share on other sites

Hi is there anyway that I could change EP so that it could read the text file that I recieve, the text file contains data on stock availability, but it has different headings to that used in OSC.

 

here is an example of the text file:

 

**START

IB 0702026174

BI hardback

AU EVANS, WILLIAM CHARLES

BC MMG

CO UK

EI 15REV ED

IU 275ILLS

PD 20011213

NP 600

RP 62.99

RI 62.99

RE 62.99

DI 286 x 229

PU ELSEVIER HEALTH SCIENCES

YP 2001

RC Y

RS ACADEMIC/SPECIALIST

TI TREASE AND EVANS PHARMACOGNOSY

DE Serves as the encyclopaedic reference work on pharmacognosy, the study of those natural substances, principally plants, that find a use in medicine. This book balances between classical and modern aspects of this branch of science, and covers the importance of complementary medicines, including herbal, homeopathic and aromatherapy.

EA 9780702026171

RF R

WE 1780

SG 1

GC O00

**

IB 0862726921

BI paperback

AU BURTON, JOHN

BC PSVW7

CO UK

IL OLIVER, WILLIAM

IU ILLUSTRATIONS, COLOUR PHOTOS

PD 19911130

NP 192

RP 10.99

RI 10.99

RE 10.99

DI 225 x 123

PU KINGFISHER BOOKS LTD

YP 1991

RC G

RS GENERAL

SR FIELD GUIDES

TI FIELD GUIDE TO THE MAMMALS OF BRITAIN AND EUROPE

DE A guide to over 160 species of mammals from Britain and Europe. Concise descriptions summarize the key physical features, behaviour and range of each main animal, as well as distinguishing similar species. Also included is information on life cycles and conservation status.

EA 9780862726928

RF R

WE 378

SG 3

GC C05

**

 

As you can see it is set out differently from the normal EP file and it has different headings. Each book is seperated by the **

 

Any ideas ?

 

Iain

Link to comment
Share on other sites

Hi,

 

Is anyone usign QT Pro with EP? I know they are compatible (later verisons anyway).. I originally posted in the QT Pro forum but not having much luck with responses..

 

Just want to know how QT Pro works. Can you assign a unique model number to each product-attribute combination.. i.e. 'product A small' has model number 3984 and 'product A medium' has model number 02844.

I need to be able to assign these model numbers myself as my supplier assigns seperate model numbers in the same way.

 

Thanks,

Natalie

Link to comment
Share on other sites

I have a strange problem with importing some html codes in my product description with easypopulate latest version

 

All my " is converted to "
Which destroys the html layout. f.ex.  COLSPAN="2" to COLSPAN=Ŗ"

Any way to fix this?...

 

Please help I'm waiting to enter many product descriptions using easypopulate

 

Thanks alot friends

Edited by shaytaan

?,???`???,?? God must love stupid people, he made so many ??,???`???,?

Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Unfortunately, your content contains terms that we do not allow. Please edit your content to remove the highlighted words below.
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...