Re: EasyPopulate 4.0 Support Thread
Quote:
Originally Posted by
mc12345678
Well, the copy that came through to me had your admin directory throughout the post. At any rate, the last message of the log indicates that you are using a version that is not fully compatible with Zahn cart 1.5.8. There are two ways to at least get really close.
Either, make the two edits described over the last 15 pages or so (pretty much at least once on each page) or use the github.com version referenced within the last two pages or so.
I've been trying to get a little time to update the files associated with installing the software for the case of the temporary directory not yet existing; however, keep getting interrupted with other things. Generally speaking the updated version should work.
Unfortunately I must also figure out what the best instructions are because the new version also works as a zc_install style plugin even though there is an Ajax related file that appears must be loaded to the catalog even though the zc_install process seems to ignore catalog related code. Don't have to have the added feature, but helps those that care about attributes.
Quote:
Originally Posted by
Fenomenal7
ok great, I will use use the github.com version you referenced and let ya'll know how it went. Thank you!
For information, the github.com site was updated about 22 hours ago to correct the other issue that was recently identified. About an error logged when debugging is on (default) and the directory not yet existing.
Besides possibly the addition of additional notifier s, in all working on a change in the way of establishing default values. Feedback, good or bad, is sordid.
Re: EasyPopulate 4.0 Support Thread
Quote:
Originally Posted by
mc12345678
For information, the github.com site was updated about 22 hours ago to correct the other issue that was recently identified. About an error logged when debugging is on (default) and the directory not yet existing.
Besides possibly the addition of additional notifier s, in all working on a change in the way of establishing default values. Feedback, good or bad, is sordid.
ok. after installing I see easy pop on my tools but once again, when I click on it it says http 500 error and I can't configure or do anything with it. The error log is as follows:
[20-Mar-2024 11:37:42 America/Boise] PHP Fatal error: Uncaught Error: Cannot access private property queryFactory::$link in /home2/cedargr4/public_html/new/admin/includes/classes/class.query_factory_ep4.php:62
Stack trace:
#0 /home2/cedargr4/public_html/new/admin/easypopulate_4.php(28): queryFactoryEP4->getLink()
#1 /home2/cedargr4/public_html/new/admin/index.php(11): require('/home2/cedargr4...')
#2 {main}
thrown in /home2/cedargr4/public_html/new/admin/includes/classes/class.query_factory_ep4.php on line 62
[20-Mar-2024 11:37:42 America/Boise] Request URI: /new/admin/index.php?cmd=easypopulate_4, IP address: 47.219.208.101
--> PHP Fatal error: Uncaught Error: Cannot access private property queryFactory::$link in /home2/cedargr4/public_html/new/admin/includes/classes/class.query_factory_ep4.php:62
Stack trace:
#0 /home2/cedargr4/public_html/new/admin/easypopulate_4.php(28): queryFactoryEP4->getLink()
#1 /home2/cedargr4/public_html/new/admin/index.php(11): require('/home2/cedargr4...')
#2 {main}
thrown in /home2/cedargr4/public_html/new/admin/includes/classes/class.query_factory_ep4.php on line 62.
I really need to get this fixed today - been working on this for 2 weeks. I'm a novice. Can you help me 1 on 1 in the inbox?
Re: EasyPopulate 4.0 Support Thread
Re: EasyPopulate 4.0 Support Thread
Quote:
Originally Posted by
Fenomenal7
ok. after installing I see easy pop on my tools but once again, when I click on it it says http 500 error and I can't configure or do anything with it. The error log is as follows:
[20-Mar-2024 11:37:42 America/Boise] PHP Fatal error: Uncaught Error: Cannot access private property queryFactory::$link in /home2/cedargr4/public_html/new/admin/includes/classes/class.query_factory_ep4.php:62
Stack trace:
#0 /home2/cedargr4/public_html/new/admin/easypopulate_4.php(28): queryFactoryEP4->getLink()
#1 /home2/cedargr4/public_html/new/admin/index.php(11): require('/home2/cedargr4...')
#2 {main}
thrown in /home2/cedargr4/public_html/new/admin/includes/classes/class.query_factory_ep4.php on line 62
[20-Mar-2024 11:37:42 America/Boise] Request URI: /new/admin/index.php?cmd=easypopulate_4, IP address: 47.219.208.101
--> PHP Fatal error: Uncaught Error: Cannot access private property queryFactory::$link in /home2/cedargr4/public_html/new/admin/includes/classes/class.query_factory_ep4.php:62
Stack trace:
#0 /home2/cedargr4/public_html/new/admin/easypopulate_4.php(28): queryFactoryEP4->getLink()
#1 /home2/cedargr4/public_html/new/admin/index.php(11): require('/home2/cedargr4...')
#2 {main}
thrown in /home2/cedargr4/public_html/new/admin/includes/classes/class.query_factory_ep4.php on line 62.
I really need to get this fixed today - been working on this for 2 weeks. I'm a beginner. Can you help me 1 on 1 in the inbox?
I should have updated the date associated with the version but about five hours ago or less I made a change to the class file reported as the issue: admin/includes/classes/class.query_factory_ep4.php
Re: EasyPopulate 4.0 Support Thread
Quote:
Originally Posted by
mc12345678
I should have updated the date associated with the version but about five hours ago or less I made a change to the class file reported as the issue: admin/includes/classes/class.query_factory_ep4.php
That did it! Thank you :)
Re: EasyPopulate 4.0 Support Thread
Zen Cart 1.5.7d
Easy Populate 4.0.36.ZC - 07-05-2016
Import/Export Primary Key set to products_id
We're trying to delete a bunch of products. The csv file consists of only'
v_products_id v_products_type v_products_name_1 v_categories_name_1 v_status
219273 1 Product Name 9
On import, I'm getting
NOT FOUND! - Model: 219273 - cant delete...
This site does not use model numbers for any products. I assumed setting the import/export key to products_id would have the import use the products_id and not model.
Re: EasyPopulate 4.0 Support Thread
Quote:
Originally Posted by
jeking
Zen Cart 1.5.7d
Easy Populate 4.0.36.ZC - 07-05-2016
Import/Export Primary Key set to products_id
We're trying to delete a bunch of products. The csv file consists of only'
v_products_id v_products_type v_products_name_1 v_categories_name_1 v_status
219273 1 Product Name 9
On import, I'm getting
NOT FOUND! - Model: 219273 - cant delete...
This site does not use model numbers for any products. I assumed setting the import/export key to products_id would have the import use the products_id and not model.
Interesting condition. I too would expect the deletion even though I know there are some changes in the latest version that might address/relate; however, when trying to review the 4.0.36ZC code:
Code:
while ($row = ($ep_uses_mysqli ? mysqli_fetch_array($result) : mysql_fetch_array($result) )) { // chadd - this executes once?? why use while-loop?? $product_is_new = false; // we found products_model in database
// Get current products descriptions and categories for this model from database
// $row at present consists of current product data for above fields only (in $sql)
// since we have a row, the item already exists.
// let's check and delete it if requested
// v_status == 9 is a delete request
$continueNextRow = false;
if ($items[$filelayout['v_status']] == 9) {
$chosen_key = '';
switch (EP4_DB_FILTER_KEY) {
case 'products_model':
$chosen_key = 'v_products_model';
break;
case 'blank_new':
case 'products_id':
$chosen_key = 'v_products_id';
break;
default:
$chosen_key = 'v_products_model';
break;
}
$display_output .= sprintf(EASYPOPULATE_4_DISPLAY_RESULT_DELETED, $items[$filelayout[$chosen_key]]);
ep_4_remove_product($items[$filelayout[$chosen_key]]);
$continueNextRow = true;
}
$zco_notifier->notify('EP4_IMPORT_FILE_EARLY_ROW_PROCESSING');
if ($continueNextRow == true) {
continue 2; // short circuit - loop to next record
}
The appearance to me is that the result of the while condition is "falsey" causing that internal deletion to be skipped and leading to the message after the while loop indicating the product could not be found.
That said also, the above "file" data doesn't present what might be expected. It appears that there are only four pieces of data below the five column headers. I suspect this displayed condition is because the spreadsheet data was directly copied into this chat instead of the csv file contents. Because you are getting the error that you are, it seems one of the columns is made of non-problematic "empty" data.
It could be that the product does not have data fully across all necessary tables: Note the query.
Code:
$sql = 'SELECT p.products_id as v_products_id,
p.products_type as v_products_type,
p.products_model as v_products_model,
p.products_image as v_products_image,
p.products_price as v_products_price,';
if ($ep_supported_mods['uom'] == true) { // price UOM mod - chadd
$sql .= 'p.products_price_uom as v_products_price_uom,';
}
if ($ep_supported_mods['upc'] == true) { // UPC Code mod- chadd
$sql .= 'p.products_upc as v_products_upc,';
}
if ($ep_supported_mods['gpc'] == true) { // Google Product Category for Google Merhant Center - chadd 10-1-2011
$sql .= 'p.products_gpc as v_products_gpc,';
}
if ($ep_supported_mods['msrp'] == true) { // Manufacturer's Suggested Retail Price
$sql .= 'p.products_msrp as v_products_msrp,';
}
if ($ep_supported_mods['map'] == true) { // Manufacturer's Advertised Price
$sql .= 'p.map_enabled as v_map_enabled,';
$sql .= 'p.map_price as v_map_price,';
}
if ($ep_supported_mods['gppi'] == true) { // Group Pricing Per Item
$sql .= 'p.products_group_a_price as v_products_group_a_price,';
$sql .= 'p.products_group_b_price as v_products_group_b_price,';
$sql .= 'p.products_group_c_price as v_products_group_c_price,';
$sql .= 'p.products_group_d_price as v_products_group_d_price,';
}
if ($ep_supported_mods['excl'] == true) { // Exclusive Product Custom Mod
$sql .= 'p.products_exclusive as v_products_exclusive,';
}
$zco_notifier->notify('EP4_IMPORT_PRODUCT_DEFAULT_SELECT_FIELDS');
if (count($custom_fields) > 0) {
foreach ($custom_fields as $field) {
$sql .= 'p.' . $field . ' as v_' . $field . ',';
}
}
$sql .= 'p.products_weight as v_products_weight,
p.products_discount_type as v_products_discount_type,
p.products_discount_type_from as v_products_discount_type_from,
p.product_is_call as v_product_is_call,
p.products_sort_order as v_products_sort_order,
p.products_quantity_order_min as v_products_quantity_order_min,
p.products_quantity_order_units as v_products_quantity_order_units,
p.products_priced_by_attribute as v_products_priced_by_attribute,
p.product_is_always_free_shipping as v_product_is_always_free_shipping,
p.products_date_added as v_date_added,
p.products_date_available as v_date_avail,
p.products_tax_class_id as v_tax_class_id,
p.products_quantity as v_products_quantity,
p.products_status as v_products_status,
p.manufacturers_id as v_manufacturers_id,
p.metatags_products_name_status as v_metatags_products_name_status,
p.metatags_title_status as v_metatags_title_status,
p.metatags_model_status as v_metatags_model_status,
p.metatags_price_status as v_metatags_price_status,
p.metatags_title_tagline_status as v_metatags_title_tagline_status,
subc.categories_id as v_categories_id
FROM ' .
TABLE_PRODUCTS_TO_CATEGORIES . ' as ptoc,' .
TABLE_CATEGORIES . ' as subc,' .
TABLE_PRODUCTS . " as p ";
$zco_notifier->notify('EP4_IMPORT_PRODUCT_DEFAULT_SELECT_TABLES');
$sql .= "WHERE
p.products_id = ptoc.products_id AND
ptoc.categories_id = subc.categories_id AND ";
switch (EP4_DB_FILTER_KEY){
case 'products_model':
$sql .= "
p.products_model = :products_model:";
break;
case 'blank_new':
case 'products_id':
$sql .= "
p.products_id = :products_id:";
break;
default:
$sql .= "
p.products_model = :products_model:";
break;
}
$sql = $db->bindVars($sql, ':products_model:', $items[$filelayout['v_products_model']], 'string');
$sql = $db->bindVars($sql, ':products_id:', $items[$filelayout['v_products_id']], 'integer');
the products_to_categories table, categories and products tables are effectively all inner joined requiring a record in all three that give at least one result when queried on the products_id. So if that product isn't in the products_to_categories table or if the categories table doesn't have a match to the products_to_categories table, then the query doesn't find any results and we get the falsey value that bypasses the attempt to delete.
Can it, will it delete with that minimal amount of information, I would say yes and suggest reviewing the results of that query. May I suggest trying phpMyAdmin to run that query substituting the necessary data where it would be coded into the query. Again I suspect the result is 0 values returned and then need to figure out why.
Originally and only for information, I was going to question what filename is used; however, the response received indicates the file is being processed as an "everything else" file.
Re: EasyPopulate 4.0 Support Thread
Quote:
Originally Posted by
mc12345678
the products_to_categories table, categories and products tables are effectively all inner joined requiring a record in all three that give at least one result when queried on the products_id. So if that product isn't in the products_to_categories table or if the categories table doesn't have a match to the products_to_categories table, then the query doesn't find any results and we get the falsey value that bypasses the attempt to delete.
Thank you for the details trouble shooting and explanation.
This is the issue, the product_id does not exist in the products_to_categories table. I can't say how the products were added, probably with Apsona. I'll write a custom query to delete the products for this client.
Much appreciated!
Re: EasyPopulate 4.0 Support Thread
Quote:
Originally Posted by
jeking
Thank you for the details trouble shooting and explanation.
This is the issue, the product_id does not exist in the products_to_categories table. I can't say how the products were added, probably with Apsona. I'll write a custom query to delete the products for this client.
Much appreciated!
Alternatively the query in EP4 could be modified to support let joins for each of the tables instead of one joins. I would expect that to at least in part resolve the issue of being able to delete the product.
There are multiple possible reasons of the loss of product to category relationship. Glad that were able to confirm or identify the problem with that configuration.
1 Attachment(s)
Re: EasyPopulate 4.0 Support Thread
Please help.
Easy Populate 4.0.39.ZC, Zen Cart v1.5.7d, PHP Version 7.4
I can't import products that are in a subcategory.
Import Results
"Error: Unbalanced Categories defined in:"
Thanks.
Attachment 20556