1. Anonymous User
  2. RO CSVI
  3. Friday, 05 February 2021
  4.  Subscribe via email
I need to update VirtueMart products based on product_name (add sku and gtin to existing products)
I created a template but it does not work, because "Row cannot be loaded. Error: Missing field in database: VirtueMartTableProduct product_name. "
I've attached the log file
Could you please check this?
Attachments (1)
Accepted Answer
Accepted Answer Pending Moderation
Hello,
I need to update VirtueMart products based on product_name (add sku and gtin to existing products)

Instead of product_name field use virtuemart_product_id field to update SKU and GTIN fields. The reason is that product_name field does not belong to #__virtuemart_products table and import based on field supports only fields from #__virtuemart_products table.


I created a template but it does not work, because "Row cannot be loaded. Error: Missing field in database: VirtueMartTableProduct product_name. "

This error is because the field product_name does not belong to #__virtuemart_products table but it is from #__virtuemart_product_XX_XX (XX_XX is the language) language table.
Kind regards,

Tharuna

=========================
If you use our extensions, please post a rating and a review at the Joomla! Extension Directory
  1. more than a month ago
  2. RO CSVI
  3. # Permalink
Accepted Answer Pending Moderation
Hi

Thank you for your reply.
I don't have virtuemart_product_id/sku etc, the remote system provides only product_name.
I know it's not in the products table, so for this time I created my own script to update, this was just a notice maybe there are other users who want to import based on this field.
  1. more than a month ago
  2. RO CSVI
  3. # 1
Accepted Answer Pending Moderation
Hello,
I just wanted to check— is this still not possible? Unfortunately, in the remote system, the key is the product name.

Wouldn't it be possible to join the language table with #__virtuemart_products during the import?
  1. more than a month ago
  2. RO CSVI
  3. # 2
Accepted Answer Pending Moderation
Hello,
I just wanted to check— is this still not possible? Unfortunately, in the remote system, the key is the product name.

No you can only update based on fields from #__virtuemart_products table.

Wouldn't it be possible to join the language table with #__virtuemart_products during the import?

Language table is joined on import to update values but the field Import based on are only from #__virtuemart_product table.
Kind regards,

Tharuna

=========================
If you use our extensions, please post a rating and a review at the Joomla! Extension Directory
  1. more than a month ago
  2. RO CSVI
  3. # 3
Accepted Answer Pending Moderation
Hmm, that's sad. I must re-think the automated imports.
Thanky anyway
  1. more than a month ago
  2. RO CSVI
  3. # 4
Accepted Answer Pending Moderation
Hi,

One workaround would be to write a rule plugin that uses the product name field and retrieves the SKU or product ID from the database and puts that in the product_sku or ID field. That way you can import it based on product name. For more details you can check the Writing a rule plugin document.
Kind regards,

RolandD

=========================
If you use our extensions, please post a rating and a review at the Joomla! Extension Directory
  1. more than a month ago
  2. RO CSVI
  3. # 5
Accepted Answer Pending Moderation
Hi,

One workaround would be to write a rule plugin that uses the product name field and retrieves the SKU or product ID from the database and puts that in the product_sku or ID field. That way you can import it based on product name. For more details you can check the Writing a rule plugin document.


Amazing. Just a few lines of code, and I got what I needed. I also learned something with huge potential. Thank you so much!
  1. more than a month ago
  2. RO CSVI
  3. # 6
Accepted Answer Pending Moderation
Hi,

Happy to hear that you managed to make it work with your own rule. Indeed the rule system is quite powerful if you have some coding skills. This is often used to separate business logic from the RO CSVI core code, you do not have to worry about breaking your rule with any upgrade as your code is contained in your own plugin.
Kind regards,

RolandD

=========================
If you use our extensions, please post a rating and a review at the Joomla! Extension Directory
  1. more than a month ago
  2. RO CSVI
  3. # 7
  • Page :
  • 1


There are no replies made for this post yet.
Be one of the first to reply to this post!