Announcement

Collapse
No announcement yet.

Update Product Via Provide.xml

Collapse
X
 
  • Filter
  • Time
  • Show
Clear All
new posts

    Update Product Via Provide.xml

    Is there a way to update products, specifically attributes/options via the provide.xml file. Seems to ignore any changes if the product is present.
    Bruce Golub
    Phosphor Media - "Your Success is our Business"

    Improve Your Customer Service | Get MORE Customers | Edit CSS/Javascript/HTML Easily | Make Your Site Faster | Get Indexed by Google | Free Modules | Follow Us on Facebook
    phosphormedia.com

    #2
    Re: Update Product Via Provide.xml

    The provide file uses an "add" function for products, so if the product code already exists, the provide does nothing. You have to literally delete products in MM5 to pull in info with the provision file.

    Comment


      #3
      Re: Update Product Via Provide.xml

      yea...know that...hoping there was an undocumented feature to update...not just add...
      Bruce Golub
      Phosphor Media - "Your Success is our Business"

      Improve Your Customer Service | Get MORE Customers | Edit CSS/Javascript/HTML Easily | Make Your Site Faster | Get Indexed by Google | Free Modules | Follow Us on Facebook
      phosphormedia.com

      Comment


        #4
        Re: Update Product Via Provide.xml

        Let me ask.
        Thanks,

        Rick Wilson
        CEO
        Miva, Inc.
        [email protected]
        https://www.miva.com

        Comment


          #5
          Re: Update Product Via Provide.xml

          Was there any answer to this?

          I am wondering about price, cost, description, etc, as well as attributes and the most important, inventory counts.

          TIA,

          Scott
          What help do you need today!
          Interactive Design Solutions http://www.southbound.com
          MivaMerchant Business Partner | Certified MivaMerchant Web Developer
          My T-shirt Collection is mostly MivaCon T-shirts!!
          Competitive Rates, Popular Modules, and Integrations:
          Product Copy | AutoBaskets | Waitlist Integration| Wholesale Integration

          Comment


            #6
            Re: Update Product Via Provide.xml

            Scott, this thread's 2.5 years old, so I don't recall in the slightest. Maybe Bruce can chime in.
            Thanks,

            Rick Wilson
            CEO
            Miva, Inc.
            [email protected]
            https://www.miva.com

            Comment


              #7
              Re: Update Product Via Provide.xml

              Yep, realized how old this thread is, but since I haven't found any documentation, the subject is still current. My similar/exact question on the dev forum has gone unanswered. If I didn't see this thread, I would have created a ticket.

              Thanks,

              Scott
              What help do you need today!
              Interactive Design Solutions http://www.southbound.com
              MivaMerchant Business Partner | Certified MivaMerchant Web Developer
              My T-shirt Collection is mostly MivaCon T-shirts!!
              Competitive Rates, Popular Modules, and Integrations:
              Product Copy | AutoBaskets | Waitlist Integration| Wholesale Integration

              Comment


                #8
                Re: Update Product Via Provide.xml

                Product_Update is the tag you want to update existing products:
                Code:
                <Product_Update code="existing_code">
                <Code>new_code</Code>
                <Name>new_name</Name>
                <Price>1.23</Price>
                <Cost>1.23</Cost>
                <Weight>1.23</Weight>
                <Description>new_desc</Description>
                <ThumbnailImage>new_thumbnail</ThumnailImage>
                <FullSizeImage>new_image</FullSizeImage>
                <Taxable>Yes</Taxable>
                <Active>Yes</Active>
                </Product_Update>
                If you leave any of the tags out the existing values will be retained.

                Attributes can be added, deleted, or updated using provisioning:

                Code:
                <ProductAttribute_Add product_code="code">
                <Code></Code>
                <Type></Type>
                <Prompt></Prompt>
                <Price></Price>
                <Cost></Cost>
                <Weight></Weight>
                <Required></Required>
                <Inventory></Inventory>
                <Image></Image>
                </ProductAttribute_Add>
                
                <ProductAttribute_Update product_code="" attribute_code="">
                <Code></Code>
                <Type></Type>
                <Prompt></Prompt>
                <Price></Price>
                <Cost></Cost>
                <Weight></Weight>
                <Required></Required>
                <Inventory></Inventory>
                <Image></Image>
                </ProductAttribute_Update>
                
                <ProductAttribute_Delete_All product_code="" />
                <ProductAttribute_Delete product_code="" attribute_code="" />
                
                <ProductAttributeOption_Add product_code="" attribute_code="">
                <Code></Code>
                <Prompt></Prompt>
                <Price></Price>
                <Cost></Cost>
                <Weight></Weight>
                <Image></Image>
                <DefaultOption>No</DefaultOption>
                </ProductAttributeOption_Add>
                
                <ProductAttributeOption_Update product_code="" attribute_code="" option_code="">
                <Code></Code>
                <Prompt></Prompt>
                <Price></Price>
                <Cost></Cost>
                <Weight></Weight>
                <Image></Image>
                <DefaultOption>No</DefaultOption>
                </ProductAttributeOption_Add>
                
                <ProductAttributeOption_Delete product_code="" attribute_code="" option_code="" />
                In PR7 (I think, it may have been one of the PR6 patches), we modified the attribute export module so that is has an option to output a <ProductAttribute_Delete_All> tag for each product, so that existing attributes can be replaced.
                Last edited by zdumlao; 11-30-11, 03:23 PM.

                Comment


                  #9
                  Re: Update Product Via Provide.xml

                  Thanks John.

                  Looks like inventory is only part of the attribute block? True?

                  How many product records can be handled in one file? Is there a limit?

                  Thanks again,

                  Scott
                  What help do you need today!
                  Interactive Design Solutions http://www.southbound.com
                  MivaMerchant Business Partner | Certified MivaMerchant Web Developer
                  My T-shirt Collection is mostly MivaCon T-shirts!!
                  Competitive Rates, Popular Modules, and Integrations:
                  Product Copy | AutoBaskets | Waitlist Integration| Wholesale Integration

                  Comment


                    #10
                    Re: Update Product Via Provide.xml

                    Code:
                    		<InventoryProductSettings_Update product_code="armor-stdleather">
                    			<TrackProduct>Yes</TrackProduct>
                    			<AdjustStockBy>500</AdjustStockBy>
                    			<InStockMessageShort><![CDATA[]]></InStockMessageShort>
                    			<InStockMessageLong><![CDATA[]]></InStockMessageLong>
                    			<TrackLowStockLevel>Yes</TrackLowStockLevel>
                    			<LowStockLevel>Default</LowStockLevel>
                    			<LowStockMessageShort><![CDATA[]]></LowStockMessageShort>
                    			<LowStockMessageLong><![CDATA[]]></LowStockMessageLong>
                    			<TrackOutOfStockLevel>Yes</TrackOutOfStockLevel>
                    			<HideOutOfStockProducts>Yes</HideOutOfStockProducts>
                    			<OutOfStockLevel>Default</OutOfStockLevel>
                    			<OutOfStockMessageShort><![CDATA[]]></OutOfStockMessageShort>
                    			<OutOfStockMessageLong><![CDATA[]]></OutOfStockMessageLong>
                    			<LimitedStockMessage><![CDATA[]]></LimitedStockMessage>
                    		</InventoryProductSettings_Update>
                    In my search I did find this snippet. Is this still valid?

                    Thanks,

                    Scott
                    What help do you need today!
                    Interactive Design Solutions http://www.southbound.com
                    MivaMerchant Business Partner | Certified MivaMerchant Web Developer
                    My T-shirt Collection is mostly MivaCon T-shirts!!
                    Competitive Rates, Popular Modules, and Integrations:
                    Product Copy | AutoBaskets | Waitlist Integration| Wholesale Integration

                    Comment


                      #11
                      Re: Update Product Via Provide.xml

                      The <Inventory> tag for attributes only controls whether the attribute has its inventory flag turned on or off (for attribute inventory). <InventoryProductSettings_Update> is still used to control actual inventory levels or settings for a product.

                      Comment


                        #12
                        Re: Update Product Via Provide.xml

                        Scott,
                        I"m using miva 5.5 pr4.
                        It worked for me. I saw a bug report dated earlier in feb 2012 (mentioning here for posterity's sake)
                        that quantity updating via import has some bugs that seem to turn off inventory tracking
                        so you have to specify tracking, low stock, out of stock and hide out of stock to all be yes to prevent the import bug.
                        Also saw that miva says it is fixed in pr5 in house, but pr5 isn't released to the public yet.

                        the following worked fine for me to update inventory quantities. (i am being on the safe side specify all the yes's)

                        Code:
                        <InventoryProductSettings_Update product_code="AA315">
                          <CurrentStock>50</CurrentStock>
                         <TrackProduct>Yes</TrackProduct>
                         <TrackLowStockLevel>Yes</TrackLowStockLevel>
                         <TrackOutOfStockLevel>Yes</TrackOutOfStockLevel>
                         <HideOutOfStockProducts>Yes</HideOutOfStockProducts>
                        </InventoryProductSettings_Update>
                        the following worked fine for me to update weight on a product

                        Code:
                        <Product_Update code="AA315">
                        <Weight>1.23</Weight>
                        </Product_Update>
                        Last edited by kayakbabe; 03-01-12, 12:34 AM.

                        Comment


                          #13
                          Re: Update Product Via Provide.xml

                          Hey guys, I know I'm chiming in here a little late but here we go...

                          Is there a way to add new and update existing at the same time? In the master_provide.xml file I'm seeing

                          <Import_Add module="productimport">

                          which has the option

                          <Products>add|update|addupdate|replace|addreplac e</Products>

                          The problem is, I don't know what Import_Add module does.
                          Jamin Jones, CEO
                          the Appalachian Offroad Motorcycle Company

                          Comment


                            #14
                            Re: Update Product Via Provide.xml

                            That tag adds a pre-configured import to the Import Data screen. The example you quoted above is referencing the productimport module and the <Products> tag in that case controls the "Products" option for the import.

                            There is no single provisioning tag that would correspond to the "Add New and Update Existing Products" option for that module. What we have done in the past when we required this functionality is to output both <Product_Add> and <Product_Update> tags for the same product. If the product already exists, the add will generate an error message that can be ignored (it will not create a duplicate product).

                            Comment


                              #15
                              Re: Update Product Via Provide.xml

                              How does the Provide.xml file handle custom product fields? I can't seem to get it to work like the other normal tags.


                              Code:
                              <Product_Update code="AA315">
                              <Brand>Nike</Brand>
                              </Product_Update>
                              Last edited by phishbed; 02-22-13, 11:32 AM.
                              Jamin Jones, CEO
                              the Appalachian Offroad Motorcycle Company

                              Comment

                              Working...
                              X