[Skip to main content](#vessel-content)

#   Importing CSV to update quantities results in zero stock amounts

##

- **[avonrivercs](/forum/user/38726-avonrivercs "View avonrivercs's Profile")**
- [![avonrivercs's Avatar](https://www.hikashop.com/media/kunena/core/svg/person.svg)](/forum/user/38726-avonrivercs "View avonrivercs's Profile") Topic Author
- [ Offline](/forum/user/38726-avonrivercs)

Less More

- Posts: 59
- Thank you received: 2
-
-

6 years 4 months ago [\#322282](#322282) by [avonrivercs](/forum/user/38726-avonrivercs "View avonrivercs's Profile")  *[Importing CSV to update quantities results in zero stock amounts](/forum/44-mass-actions/900456-importing-csv-to-update-quantities-results-in-zero-stock-amounts#322282 "-- url of the page with the problem -- :   avonrivercomputers.com.au/mantest  -- HikaShop version -- : 4.3.0 -- Joomla version -- : 3.9.20 -- PHP version -- : 7.3 -- Browser(s) name and version -- : Vivaldi 2.8 -- Error-message(debug-mod must be tuned on) -- : No error message  Trying to get the mass action working to update stock quantities from a CSV file. I select the CSV file with the quantity updates and select to upload and I have verified and it gives me a valid file. All good so far. I have selected Save the products on Mass Action CSV import checkbox is ticked. I have set the limitations to 5000, well above the actual number of products. I have set the actions to Display the results and ticked Product code, product name and product quantity and if I process this, it displays the product code, name and quantity exactly as I want. When I select the And update the values, product quantity=int is where it all falls apart. The values get updated to zero and even if the values do not change, ie they are the same value in Hikashop as the CSV, Hikashop get updated to 0. I have read the docs, tutorial and also tried searching the forums and I believe that what I am doing is correct so the crux of my question is that how can it be that when I display, the result it is correct but when I try to update with the same result, it gives me a zero where the quantity has a number. Any pointers would be greatly appreciated, thanks.")* was created by *[avonrivercs](/forum/user/38726-avonrivercs "View avonrivercs's Profile")*

-- url of the page with the problem -- : [ avonrivercomputers.com.au/mantest](https://avonrivercomputers.com.au/mantest)
-- HikaShop version -- : 4.3.0
-- Joomla version -- : 3.9.20
-- PHP version -- : 7.3
-- Browser(s) name and version -- : Vivaldi 2.8
-- Error-message(debug-mod must be tuned on) -- : No error message

Trying to get the mass action working to update stock quantities from a CSV file. I select the CSV file with the quantity updates and select to upload and I have verified and it gives me a valid file. All good so far. I have selected Save the products on Mass Action CSV import checkbox is ticked. I have set the limitations to 5000, well above the actual number of products. I have set the actions to Display the results and ticked Product code, product name and product quantity and if I process this, it displays the product code, name and quantity exactly as I want. When I select the And update the values, product quantity=int is where it all falls apart. The values get updated to zero and even if the values do not change, ie they are the same value in Hikashop as the CSV, Hikashop get updated to 0. I have read the docs, tutorial and also tried searching the forums and I believe that what I am doing is correct so the crux of my question is that how can it be that when I display, the result it is correct but when I try to update with the same result, it gives me a zero where the quantity has a number. Any pointers would be greatly appreciated, thanks.

Please [Log in](/login?return=aHR0cHM6Ly93d3cuaGlrYXNob3AuY29tL2ZvcnVtLzQ0LW1hc3MtYWN0aW9ucy85MDA0NTYtaW1wb3J0aW5nLWNzdi10by11cGRhdGUtcXVhbnRpdGllcy1yZXN1bHRzLWluLXplcm8tc3RvY2stYW1vdW50cz90bXBsPW1hcmtkb3du) or [Create an account](/component/users/registration?Itemid=101) to join the conversation.

- **[nicolas](/forum/user/63-nicolas "View nicolas's Profile")**
- [![nicolas's Avatar](https://www.hikashop.com/media/kunena/avatars/resized/size144/users/avatar63.png?1793428657)](/forum/user/63-nicolas "View nicolas's Profile")
- [ Offline](/forum/user/63-nicolas)

Less More

- Posts: 86584
- Thank you received: 14325
-
-

6 years 4 months ago [\#322306](#322306) by [nicolas](/forum/user/63-nicolas "View nicolas's Profile")  Replied by *[nicolas](/forum/user/63-nicolas "View nicolas's Profile")* on topic *[Importing CSV to update quantities results in zero stock amounts](/forum/44-mass-actions/900456-importing-csv-to-update-quantities-results-in-zero-stock-amounts#322306 "-- url of the page with the problem -- :   avonrivercomputers.com.au/mantest  -- HikaShop version -- : 4.3.0 -- Joomla version -- : 3.9.20 -- PHP version -- : 7.3 -- Browser(s) name and version -- : Vivaldi 2.8 -- Error-message(debug-mod must be tuned on) -- : No error message  Trying to get the mass action working to update stock quantities from a CSV file. I select the CSV file with the quantity updates and select to upload and I have verified and it gives me a valid file. All good so far. I have selected Save the products on Mass Action CSV import checkbox is ticked. I have set the limitations to 5000, well above the actual number of products. I have set the actions to Display the results and ticked Product code, product name and product quantity and if I process this, it displays the product code, name and quantity exactly as I want. When I select the And update the values, product quantity=int is where it all falls apart. The values get updated to zero and even if the values do not change, ie they are the same value in Hikashop as the CSV, Hikashop get updated to 0. I have read the docs, tutorial and also tried searching the forums and I believe that what I am doing is correct so the crux of my question is that how can it be that when I display, the result it is correct but when I try to update with the same result, it gives me a zero where the quantity has a number. Any pointers would be greatly appreciated, thanks.")*

Hi,

You say "And update the values, product quantity=int is where it all falls apart".
So it would mean that you have an action "update the values" on the "product_quantity" column.
This is not necessary.
No action in the mass action is necessary to update the product data with the data from the CSV. It will be updated automatically.
I suppose that you have a wrong value in the action "update the values" and thus it uses 0 and updates the quantity to 0 because of that action.
Remove the action, and only keep the filter of the CSV file and process the mass action and it should directly update the quantity.

Please [Log in](/login?return=aHR0cHM6Ly93d3cuaGlrYXNob3AuY29tL2ZvcnVtLzQ0LW1hc3MtYWN0aW9ucy85MDA0NTYtaW1wb3J0aW5nLWNzdi10by11cGRhdGUtcXVhbnRpdGllcy1yZXN1bHRzLWluLXplcm8tc3RvY2stYW1vdW50cz90bXBsPW1hcmtkb3du) or [Create an account](/component/users/registration?Itemid=101) to join the conversation.

Board Categories HikaShop Install &amp; Update Product &amp; Category Display Content Creation Sales and Orders Orders management Reports &amp; Statistics Customers Checkout Payment Methods Shipping Methods Import &amp; Export (CSV, XLS…) Specific Features Affilation Taxes Wishlist Vote Carousel &amp; Slider Mass Actions Filters &amp; Search Discount &amp; Coupon Feature Request Integrations Showcase General Talk about HikaShop Development HikaShop 3.0 Beta Translation Commercial Jobs HikaShop Components HikaMarket Market: Feature requests Market: How to? Market: Bug Report HikaSerial General talk about HikaSerial Serial: Bug Report Serial: How to? Support en Français de HikaSerial (French Support) HikaSubscription HikaAuction Auction: Feature requests Auction: How to? Auction: Bug report Hikashop around the world Support en Français (French Support) Russian FAQ. Курс выживания с Hikashop. Частые вопросы и о Расширения Hikashop Наши сайты на Hikashop 日本語版サポート(Japanese Support) Thai German Archives Bug Report How to?

[](/forum/topics/feed/mode-topics?format=feed&type=rss)

Time to create page: 0.043 seconds

[Powered by](/forum/credits) [Kunena Forum](https://www.kunena.org)
