News:

Support the VirtueMart project and become a member

Main Menu

Bulk change shopper group under product pricing

Started by allfromboats, October 16, 2019, 11:22:14 AM

Previous topic - Next topic

allfromboats

Hi,
he we run the latest version of VirtueMart.

We have several hundred products in our shop. At the moment users who are not logged in, cannot see any prices. We want to change this, so any user who visits the site can see prices and add products to the cart.

Actual we have a shopper group called "members". All products are set to the shopper group under the 'Product pricing' (NOT under Product information)  to "members".

How can i change this field for all products to "available for all" ? Because i really donĀ“t want to open each article and set it manually.

Thanks
Max




StefanSTS

Fastest will be to set the column virtuemart_shoppergroup_id in your database table #__virtuemart_product_prices to 0.
Should take a second.

--
Stefan Schumacher
www.jooglies.com - VirtueMart Invoice Layouts

Please use only stable versions with even numbers for your live shop! Use Alpha versions only if you know what risk you are taking.

allfromboats

Sounds good. Could you help me with the SQL query?

allfromboats

Ok, i got it:

UPDATE #(prefix)_virtuemart_product_prices
SET
`virtuemart_shoppergroup_id` = 0
WHERE 1

Thanks

StefanSTS

Welcome,

feels much better to have gotten to the SQL yourself, doesn't it. ;-)
--
Stefan Schumacher
www.jooglies.com - VirtueMart Invoice Layouts

Please use only stable versions with even numbers for your live shop! Use Alpha versions only if you know what risk you are taking.

AH

IMHO you should have ensured you only change where the shoppergroup was equal to the mis-configured shoppergroup

UPDATE #(prefix)_virtuemart_product_prices
SET
`virtuemart_shoppergroup_id` = 0

where `virtuemart_shoppergroup_id` = the configured shoppergroup


But my opinion may be wrong because you did not state the full information about the current price table values
Regards
A

Joomla 4.4.5
php 8.1