Hi there,
I just got the following error after upgrading from 2.0.18 to 2.0.20b:
vmError: getNeighborProducts Unknown column 'product_price' in 'order clause' SQL=SELECT `l`.`virtuemart_product_id`, `l`.`product_name` FROM `mf0sk_virtuemart_products` as `p` JOIN `mf0sk_virtuemart_products_en_gb` as `l` using (`virtuemart_product_id`) JOIN `mf0sk_virtuemart_product_categories` as `pc` using (`virtuemart_product_id`) LEFT JOIN `mf0sk_virtuemart_product_shoppergroups` as `psgr` on (`psgr`.`virtuemart_product_id`=`l`.`virtuemart_product_id`) WHERE `virtuemart_category_id` = 6 and `slug` < "bike-helmet-1-1232012-09-21-17-58-22-1262012-09-23-21-25-25" AND ( psgr.`virtuemart_shoppergroup_id`= "2" OR psgr.`virtuemart_shoppergroup_id` IS NULL ) AND p.`published`= 1 ORDER BY product_price DESC LIMIT 0,1
vmError: getNeighborProducts Unknown column 'product_price' in 'order clause' SQL=SELECT `l`.`virtuemart_product_id`, `l`.`product_name` FROM `mf0sk_virtuemart_products` as `p` JOIN `mf0sk_virtuemart_products_en_gb` as `l` using (`virtuemart_product_id`) JOIN `mf0sk_virtuemart_product_categories` as `pc` using (`virtuemart_product_id`) LEFT JOIN `mf0sk_virtuemart_product_shoppergroups` as `psgr` on (`psgr`.`virtuemart_product_id`=`l`.`virtuemart_product_id`) WHERE `virtuemart_category_id` = 6 and `slug` > "bike-helmet-1-1232012-09-21-17-58-22-1262012-09-23-21-25-25" AND ( psgr.`virtuemart_shoppergroup_id`= "2" OR psgr.`virtuemart_shoppergroup_id` IS NULL ) AND p.`published`= 1 ORDER BY product_price ASC LIMIT 0,1
I hope you are planning to solve this. I'm not the only one getting the above error. See this topic as well:
http://forum.virtuemart.net/index.php?topic=113052.15
UPDATE: The error is only visible when I'm logged in with the Admin user. If I'm logged in with a normal user the error is not visible. I forgot to mention that I see this error only on the Product Page
this needs more attention.
I would really appreciate a developers reply. Thanks
That means that in your session is an old variable. Store your vm config,... clear your browser cache.
Thanks for the reply :) All good with clearing the browser cache but what do you mean by "store your vm config" ? A detailed explanation will be much appreciated :)
The vm config is the one you find in your Backend (BE). There is a joomla config and a shop config and a vm config. The vm config is in Configuration->Configuration
update, I think I found two problems with the neighboured products. Please try the product model attached
[attachment cleanup by admin]
Update
I have added that file to /administrator/components/com_virtuemart/models/product.php
This has fixed the error.
I am now getting an info message when logged in
Info: I join price ORDER BY product_price
Info: I join price ORDER BY product_price
A temporary fix to hide the info message is in your template index file
//if ($view->hasMessages())
//echo artxPost('<jdoc:include type="message" />');
oh, yes I forgot to remove the vmInfo, just remove the line in the file containing it.
new file attached, should also contain the fix for ordering for category_name
[attachment cleanup by admin]
It works fine.
Thank you..
thank you very much for this solution, I had the same problem.
But this solution is final? is not likely to have the same problem in future updates?
Thankyou thankyou thank you Milbo!! This worked at least my products are coming up now!!
I am still getting on debug:
vmdebug checkValidOrderingField:VirtueMartModelProduct programmer choosed invalid ordering pc.ordering, use pc.ordering
Any idea why?
Works like magic!!! Thanks ;)
Hi guys,
I write here because, I have the same problem after the update of VM, pleae see the attachment, I have tried to delete the cache of browse, but noting....
I have tried also to upded the file of product, but i'm not able to change the premission, in 777.
Can you help me?
[attachment cleanup by admin]
go to configuration and enable database Update tools
go to tools & migration -> DB Tools -> click on "Install or if necessary update tables"
DON'T FORGET BACKUP OF YOUR DATABASE BEFORE
Hi, I have enabled database Update tools, and I have clicked "Install or if necessary update tables".....but nothing the problem still resist :(
Have you some other ideas?
have you added the file in this directory?
/administrator/components/com_virtuemart/models/product.php
and have you renamed the file from product.php.txt to product.php?
you don't need 777 permissions, simple upload the file with ftp to the directory
Hi I have tried to change permission in 777, but filezilla told me that I can't change the permission in 777...maybe there is another way to change in 777, but I don't know.
Can you explane me, please?
Works GREAT!! Thanks Milbo!!
Quote from: Milbo on March 20, 2013, 22:11:55 PM
oh, yes I forgot to remove the vmInfo, just remove the line in the file containing it.
new file attached, should also contain the fix for ordering for category_name
Quote from: volantiniofferte on April 18, 2013, 03:59:08 AM
Hi I have tried to change permission in 777...
On a live website this file is usually set to 644 and like 'kkmediaproduction' said, you don't have to change it. Just overwrite the orginal file by uploading the new one with your filezilla.
Hi, I have tried, but filezile doesn't overwrite the file
Perhaps you have a Filezilla configuration problem. (I don't know anything about Filezilla, I'm using the FireFTP plugin instead). You may try to delete the file first and then upload it again. If that doesn't work either, some hints concerning ownership of files in this article might help: http://docs.joomla.org/Why_can%27t_you_install_any_extensions%3F
BTW - there is a joomla extension that usually makes it easy to change file permissions: http://extplorer.net/
I have the same problem
vmError: getNeighborProducts Unknown column 'category_description' in 'order clause' SQL=SELECT `l`.`virtuemart_product_id`, `l`.`product_name` FROM `j25_virtuemart_products` as `p` JOIN `j25_virtuemart_products_es_es` as `l` using (`virtuemart_product_id`) JOIN `j25_virtuemart_product_categories` as `pc` using (`virtuemart_product_id`) LEFT JOIN `j25_virtuemart_product_shoppergroups` as `psgr` on (`psgr`.`virtuemart_product_id`=`l`.`virtuemart_product_id`) WHERE `virtuemart_category_id` = 33 and `slug` < "plancha-de-corcho-8-9" AND ( psgr.`virtuemart_shoppergroup_id`= "2" OR psgr.`virtuemart_shoppergroup_id` IS NULL ) AND p.`published`= 1 ORDER BY category_description DESC LIMIT 0,1
Hiding the error message I don“t think is a profesional solution.
Have you tried the solutions from this thread?
I not understand why I can't upload the file into the modules dir....I have red the Joomlawiki, but is all ok....
....I think that I must set the permissions on 777, but for this directory is denied
the directory don't need 777
you must upload it with ftp and maybe you have wrong ftp settings or you are in the wrong ftp group or or or...
but this have nothing to do with Joomla or VirtueMart...check your ftp access
Thanks. works magical
I still get the same error about pcordering, if i could fix it I would lt you know!
Quote from: Milbo on March 20, 2013, 22:11:55 PM
oh, yes I forgot to remove the vmInfo, just remove the line in the file containing it.
new file attached, should also contain the fix for ordering for category_name
Works great now.
Thank you
Thanks you so much Milbo :)
Sorry, but it doesn't work for me.
We have done the Update to VM 2.0.22a from 2.0.18 and now we get this error:
QuotegetNeighborProducts error
if we are logged in VM will shows the complete message like that one at the beginning of this thread.
Now i have uploaded the latest product.php from "MILBO" but it doesn't work for us.
So my question is what is to do in VM_config (Componentens/Virtuemart - Configuration - Configuration)?
If you want to see the site look at: www.hengelsport-kruidenier.com (http://www.hengelsport-kruidenier.com) it happens if you click on one product.
Thanks.
yes, same as Ahler...
Here's someone who can help us?
and after puting ''milbo's'' product.php file i also get this message when I click on BUY button:
Notice: Undefined property: stdClass::$quantity in home/....
Hi
I upgraded to 2.0.22c and I have the same problem.
When I would overwrite the product.php which is linked to in this thread much code would be gone since there were updates on that file.
Do you have an updated product.php to replace?
Regards,
Why you couldn't use product.php from the last version? From the 22d for example? What is your VM version then?
I am seeing this when I run debug.
just to report that the problem is solved with the newest versions of Gantry and VM .