Zen Cart Logo
Forums / Setting Up Categories, Products, Attributes / Setting Default Prices for Attributes

Setting Default Prices for Attributes

Locked

Views: 2,920

Results 1 to 19 of 19
This thread is locked. New replies are disabled.
2 Feb 2008, 8:18 PM
#1
samad64 avatar

samad64

Totally Zenned

Join Date:
May 2006
Location:
Texas
Posts:
554
Plugin Contributions:
2

Setting Default Prices for Attributes

OK - I know how to set up attributes and stuff, and how to set prices on them. My client offers vinyl decals for sale in about 20-30 different sizes, and the price goes by size - not the item itself. So, decal A and decal B at 5" is the same price.

Is there a way to copy all attributes (including attribute pricing) to each and every item, without having to go in there and manually enter them one at a time? I was looking around and found this: http://www.zen-cart.com/forum/showthread.php?t=7451 but wasn't sure if it works with pricing too. If anyone has any other ideas too, please feel free to respond.

Thanks!

2 Feb 2008, 9:45 PM
#2
samad64 avatar

samad64

Totally Zenned

Join Date:
May 2006
Location:
Texas
Posts:
554
Plugin Contributions:
2

Re: Setting Default Prices for Attributes

Looks like copying the product works just fine. If anyone has other suggestions feel free to post them up, but I think its resolved now.

2 Feb 2008, 10:23 PM
#3
ajeh avatar

ajeh

Oba-san

Join Date:
Sep 2003
Location:
Ohio
Posts:
62,757
Plugin Contributions:
1

Re: Setting Default Prices for Attributes

Did you go to the Attributes Controller and use the Copy to Category? This will copy all attributes from 1 Product to all the Products in a given Category ... :smile:

6 Feb 2008, 2:47 AM
#4
juliartz avatar

juliartz

New Zenner

Join Date:
Oct 2007
Posts:
53
Plugin Contributions:
0

Re: Setting Default Prices for Attributes

Ajeh:

Did you go to the Attributes Controller and use the Copy to Category? This will copy all attributes from 1 Product to all the Products in a given Category ... :smile:

ok, I understand this part, I think, so far. What I cannot find to change is my base price. What I mean, is that I sell my photographic art. I have a base price of 25.00 for an 8 x 10. Anything other than this, you have to choose from a drop down. i.e. i want an 11 x 14 instead. So I choose this from the drop down. When added to the shopping cart, the price showing is the base price PLUS the difference I've designated (in this case + 20.00) so it shows the 11 x 14 price as 45.00. I've figured (again, I think! :dontgetit ) how to change the added prices and to transfer this to all my 300 plus listings, BUT, I cannot find how to change the BASE price. I can't even find where it is. Please help :wacko: I've set this up so long ago, and now I'm in the process of doing price changes. In this case, making 24.95 to 25.00, getting rid of the
"95".!

6 Feb 2008, 3:20 AM
#5
ajeh avatar

ajeh

Oba-san

Join Date:
Sep 2003
Location:
Ohio
Posts:
62,757
Plugin Contributions:
1

Re: Setting Default Prices for Attributes

The Product Price is on the Product itself when you go to Catalog ... Categories/Products and add/edit your Product ...

Are you trying to globally set every single Product to have a products_price of 25.00?

To be sure, peek at your database via phpMyAdmin and look at the products table and the current products_price ...

If so, this can be done with a single command ...

6 Feb 2008, 3:34 AM
#6
juliartz avatar

juliartz

New Zenner

Join Date:
Oct 2007
Posts:
53
Plugin Contributions:
0

Re: Setting Default Prices for Attributes

Ajeh:

The Product Price is on the Product itself when you go to Catalog ... Categories/Products and add/edit your Product ...

Are you trying to globally set every single Product to have a products_price of 25.00?

:frusty: HUH? What do you mean by "global"? All I know is that I have like a "hidden" base price in the drop down. (https://www.juliartz.com/shopping). Meaning that is the lowest/default price for the 8 x 10 or 5 x 12 panoramic. If you want anything else, you choose the choices from the drop down. I'm trying to eliminate the "95" bull dinky in the price, and make it whole dollars. But in order to do that, I need to change the base price from 24.95 to 25.00

Ajeh:

To be sure, peek at your database via phpMyAdmin and look at the products table and the current products_price ...

If so, this can be done with a single command ...

I'd have to have my friend look there for me, as 1) I don't know how to find that area, and even if I did, I would be totally afraid to touch anything there. I have no clue when it comes to that stuff, and I would make my site explode! :Flush:

6 Feb 2008, 4:15 AM
#7
ajeh avatar

ajeh

Oba-san

Join Date:
Sep 2003
Location:
Ohio
Posts:
62,757
Plugin Contributions:
1

Re: Setting Default Prices for Attributes

Go to your Admin ...

Go to the Catalog ... Categories/Products ...

Pick a Category ...

Pick a Product ...

Click on the E for Edit ...

Do you see a
Product Price: 24.95

That is where the 24.95 is coming from, on the Product itself and not with the Attributes ...

6 Feb 2008, 4:24 AM
#8
juliartz avatar

juliartz

New Zenner

Join Date:
Oct 2007
Posts:
53
Plugin Contributions:
0

Re: Setting Default Prices for Attributes

Ajeh:

Go to your Admin ...

Go to the Catalog ... Categories/Products ...

Pick a Category ...

Pick a Product ...

Click on the E for Edit ...

Do you see a
Product Price: 24.95

That is where the 24.95 is coming from, on the Product itself and not with the Attributes ...

Ok, I think its sinking (and sinking, sinking, sinking...) in :( , but please.. can you tell me if there is an easy way to change them ALL in one fell swoop?? I so dread the mere thought that I would have to edit more then 300 lisings... :frusty:
BTW, thank you for your patience. I am truly stupid when it comes to this stuff. :clap:
julz

6 Feb 2008, 4:34 AM
#9
ajeh avatar

ajeh

Oba-san

Join Date:
Sep 2003
Location:
Ohio
Posts:
62,757
Plugin Contributions:
1

Re: Setting Default Prices for Attributes

If these are all set in the Catalog ... Categories/Products ... with the Product Price as 24.95 then they can be updated in one command to 25.00 ...

Backup your database first ...

Then you can run this command in the Tools ... Insert SQL Patches ...

UPDATE products SET products_price = 25.00;

This will change ALL products_price in the products table to be 25.00 ...

Next, go to the Tools ... Store Manager ... and run the:

Update ALL Products Price Sorter
to be able to sort by displayed prices:

And that will update all of the products_price_sorter fields with the correct value for sorting purposes by price ...

6 Feb 2008, 4:47 AM
#10
juliartz avatar

juliartz

New Zenner

Join Date:
Oct 2007
Posts:
53
Plugin Contributions:
0

Re: Setting Default Prices for Attributes

Ajeh:

If these are all set in the Catalog ... Categories/Products ... with the Product Price as 24.95 then they can be updated in one command to 25.00 ...

Backup your database first ...

Then you can run this command in the Tools ... Insert SQL Patches ...

UPDATE products SET products_price = 25.00;

> 
> This will change ALL products_price in the products table to be 25.00 ...
> 
> Next, go to the Tools ... Store Manager ... and run the:
> 
> 
> And that will update all of the products_price_sorter fields with the correct value for sorting purposes by price ...


**:clap:    :clap:    :clap:

Okay, another total dumb noob question.... how do you back up your data base? A friend is hosting my site, so I am not sure if I've ever been in "that" area.... :unsure:  and an SQL patch... hmmmm, :lookaroun  I'm definately looking dumber and dumber...:wacko: Guess I will have to wait til my friend comes back online, and forward your instructions. I am sure that she would have no problems understanding....
Again. thanks sooooo much :thumbsup: for you patience in helping me. I really do appreciate this.**
6 Feb 2008, 4:50 AM
#11
ajeh avatar

ajeh

Oba-san

Join Date:
Sep 2003
Location:
Ohio
Posts:
62,757
Plugin Contributions:
1

Re: Setting Default Prices for Attributes

Backups can be done with phpMyAdmin which is available through your Control Panel for your domain ...

Or, you can get the add-on for Backup MySQL and install that ...

Or, you can wait for your friend to help you learn this trick ... :smile:

You really want to do regular backups in case you have a bad hair day ... and totally moof up your site ... :eek:

6 Feb 2008, 5:00 AM
#12
juliartz avatar

juliartz

New Zenner

Join Date:
Oct 2007
Posts:
53
Plugin Contributions:
0

Re: Setting Default Prices for Attributes

Ajeh:

Backups can be done with phpMyAdmin which is available through your Control Panel for your domain ...

Or, you can get the add-on for Backup MySQL and install that ...

Or, you can wait for your friend to help you learn this trick ... :smile:

You really want to do regular backups in case you have a bad hair day ... and totally moof up your site ... :eek:

Hmmmm, and since I am the "Queen" of "Moofs", you are most certainly correct. I will have her talk me thru a back up lesson. Bad hair days? Don't think I've any "good" hair days lately... kinda getting used to the mop! :laugh:

16 Mar 2008, 9:24 AM
#13
heavenlynights avatar

heavenlynights

Zen Follower

Join Date:
Jan 2006
Location:
Australia
Posts:
303
Plugin Contributions:
0

Re: Setting Default Prices for Attributes

Hi Ajeh

Is there a simple command like this for attribute pricing. What I am wanting to do is change the attribute price for specific sizes of a product. Mind you garments are NOT priced by attributes. Instead they are priced as follows

Currently Sizes

Small, Medium, Large, X Large, one size, 32, 34, 36, 38 are all set as a base price

sizes 1x, 2x, 3x, 4x, 1x/2x, 2x/3x, Plus Size, 40, 42, 44 are all priced with a fixed increase.

eg below:

11106 Size Small + 0.0000 + 0 1
AUD$0.00 AUD$0.00
11107 Size Medium + 0.0000 + 0 2
AUD$0.00 AUD$0.00
11108 Size Large + 0.0000 + 0 3
AUD$0.00 AUD$0.00
11109 Size 1X/2X + 9.9500 + 0 51
AUD$9.95 AUD$0.00
11110 Size 3X/4X + 9.9500 + 0 52
AUD$9.95 AUD$0.00

What I want to do is decrease or completely get rid of the larger size prices. I want to do this on a global scale and would rather not do this individually as I have hundreds of products, which this will effect. Would you be able to help us out there.

TIA

16 Mar 2008, 9:32 PM
#14
ajeh avatar

ajeh

Oba-san

Join Date:
Sep 2003
Location:
Ohio
Posts:
62,757
Plugin Contributions:
1

Re: Setting Default Prices for Attributes

If you know the options_id and options_values_id in the products_attributes table you could do global replacements on the options_values_price ...

Then, when all is done, you can run the Tools ... Store Manager ... and the:

Update ALL Products Price Sorter
to be able to sort by displayed prices:

NOTE: this is providing ALL Attributes defined as a given pair of options_id and options_values_id are to be the same price ...

17 Mar 2008, 4:13 AM
#15
heavenlynights avatar

heavenlynights

Zen Follower

Join Date:
Jan 2006
Location:
Australia
Posts:
303
Plugin Contributions:
0

Re: Setting Default Prices for Attributes

Thanks Ajeh

I do realise that I would have to run a command for each product value id #.

For instance if I was to change the price from say 9.95 to say 4.95 for the specific size 1x using the below bolded info, what would then be the command code I would run in the install sql patches from the admin?

product option name = size with an id of 1
product option value = 1x with an id of 66

I hope that this hasn't confused you.

TIA

19 Mar 2008, 7:10 PM
#16
heavenlynights avatar

heavenlynights

Zen Follower

Join Date:
Jan 2006
Location:
Australia
Posts:
303
Plugin Contributions:
0

Re: Setting Default Prices for Attributes

sorry for bumping but need some help with this!

Thanks

21 Mar 2008, 4:42 AM
#17
ajeh avatar

ajeh

Oba-san

Join Date:
Sep 2003
Location:
Ohio
Posts:
62,757
Plugin Contributions:
1

Re: Setting Default Prices for Attributes

WARNING: Backup your database first!

Then ... Backup your database ...

Did I mention Backup your database?

UPDATE products_attributes SET options_values_price = 4.95 WHERE options_id = 1 and options_values_id = 66 and options_values_price = 9.95;
21 Mar 2008, 5:20 AM
#18
heavenlynights avatar

heavenlynights

Zen Follower

Join Date:
Jan 2006
Location:
Australia
Posts:
303
Plugin Contributions:
0

Re: Setting Default Prices for Attributes

Ajeh:

WARNING: Backup your database first!

Then ... Backup your database ...

Did I mention Backup your database?

UPDATE products_attributes SET options_values_price = 4.95 WHERE options_id = 1 and options_values_id = 66 and options_values_price = 9.95;


Your so funny :laugh::laugh: but I love it. Thanks ajeh.  

PS I always back-up before a **possible** major screw up :D
26 Mar 2008, 7:01 AM
#19
heavenlynights avatar

heavenlynights

Zen Follower

Join Date:
Jan 2006
Location:
Australia
Posts:
303
Plugin Contributions:
0

Re: Setting Default Prices for Attributes

Hi Ajeh back again. Just a quick question!

I realised that I have quite a few diferent option_values_price's so is there a way of changing them all using something like a wildcard command in the line of code you mentioned?

eg: where it says options_values_price = 9.95

can we put something else (generic) in there where it says 9.95 so that it changes whatever the figure might be rather than just that particular one.

I want to change them all to the same value.

UPDATE products_attributes SET options_values_price = 4.95 WHERE options_id = 1 and options_values_id = 66 and options_values_price = 9.95;  

TIA