Results 1 to 6 of 6
  1. #1
    Join Date
    Nov 2011
    Posts
    121
    Plugin Contributions
    0

    Default Global changes to Attribute price?

    I found an old thread where a solution was posted for global changes to attribute image.
    Here is the sql patch:

    UPDATE products_attributes SET attributes_image = 'attribute_image.jpg' WHERE options_id = XXX and options_values_id = XXX;

    What would be the field name used for the attribute price change?
    Something like:

    UPDATE products_attributes SET attributes_price = 15.00 WHERE options_id = XXX and options_values_id = XXX;

    Thank for the help.

  2. #2
    Join Date
    Jun 2005
    Location
    Cumbria, UK
    Posts
    10,262
    Plugin Contributions
    3

    Default Re: Global changes to Attribute price?

    The field is called options_values_price .

    But what exactly are you trying to do?

    You say you are looking to do a GLOBAL update.

    If you want to do a GLOBAL update, then you need to establish FIRST, which products have which attributes assigned, and how they are currently priced.

    That bit of SQL you mention refers to a SPECIFIC item:

    WHERE options_id = XXX and options_values_id = XXX

    The XXX will be replaced by the relevant id's.

    If you are looking to update MULTIPLE option values, then considerable care is needed

    This can be tricky, and I would not advise a novice doing it.

    It depends on a few things... do you want to raise prices by a set value - such as by 20%, or does each have a unique value?
    19 years a Zencart User

  3. #3
    Join Date
    Nov 2011
    Posts
    121
    Plugin Contributions
    0

    Default Re: Global changes to Attribute price?

    Thank you for the response. What I am trying to achieve is the same as the attribute swatch patch but with the attribute price change.
    The problem really comes from the fact that I have many products that share the same attributes, but the attribute properties (such as image swatch and prices for individual options) are not transferrable when copying the options from 1 product to another.

    I have created an sql patch which will update all the option image swatches after I create/copy now products with their attributes, now I need to do the same for the price changes as well. In the case of the Attribute_image, the field value (image file name) is enclosed in " ", I just need to know if the Option_values_price is of numeric type (00.000) or does it need to be in quotes as well ("00.000")? I would assume it is just standard decimal 00.000 but need it to be sure.

  4. #4
    Join Date
    Nov 2011
    Posts
    121
    Plugin Contributions
    0

    Default Re: Global changes to Attribute price?

    Just FYI, thanks for pointing me in the right direction, I was able to setup the option price change along with the attribute image, now I can update all of my attributes in 1 single sql file any time I add new products.

  5. #5
    Join Date
    Nov 2010
    Posts
    6
    Plugin Contributions
    0

    Default Re: Global changes to Attribute price?

    Hi Michael

    It would be great if you could post the sql file or fix for this, I am also trying to update an attribute price for multiple products.

  6. #6
    Join Date
    Dec 2014
    Location
    Canada
    Posts
    2
    Plugin Contributions
    0

    Default Re: Global changes to Attribute price?

    Quote Originally Posted by michaelchu View Post
    Just FYI, thanks for pointing me in the right direction, I was able to setup the option price change along with the attribute image, now I can update all of my attributes in 1 single sql file any time I add new products.
    Hi, can you please provide the sql file that you used as I"m not very savvy in those things?

 

 

Similar Threads

  1. v139h Global Attribute Price
    By Phil S in forum Setting Up Categories, Products, Attributes
    Replies: 6
    Last Post: 31 Jan 2013, 05:30 PM
  2. v150 Attribute Controls with Global changes
    By debello in forum Setting Up Categories, Products, Attributes
    Replies: 0
    Last Post: 25 Apr 2012, 05:06 PM
  3. Attribute Pricing Changes with Sale Price-WRONG!
    By MdyBlu in forum Setting Up Specials and SaleMaker
    Replies: 20
    Last Post: 11 Nov 2010, 05:50 PM

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  
disjunctive-egg
Zen-Cart, Internet Selling Services, Klamath Falls, OR