Support is online

Error on user export #7598

Open peterva opened this topic Thursday, 10 September 2015 · 5 replies
Author

Hi Roland, I have CSVI 6.1.2 with Joomla 3.4.3 and VM 3.0.9

I get an error on exporting user info:

Column 'email' in field list is ambiguous SQL=SELECT zxvf_virtuemart_userinfos.first_name, zxvf_virtuemart_userinfos.middle_name, zxvf_virtuemart_userinfos.last_name, email FROM zxvf_virtuemart_userinfos LEFT JOIN zxvf_virtuemart_vmusers ON zxvf_virtuemart_vmusers.virtuemart_user_id = zxvf_virtuemart_userinfos.virtuemart_user_id LEFT JOIN zxvf_virtuemart_vmuser_shoppergroups ON zxvf_virtuemart_vmuser_shoppergroups.virtuemart_user_id = zxvf_virtuemart_userinfos.virtuemart_user_id LEFT JOIN zxvf_virtuemart_vendors ON zxvf_virtuemart_vendors.virtuemart_vendor_id = zxvf_virtuemart_vmusers.virtuemart_vendor_id LEFT JOIN zxvf_virtuemart_shoppergroups ON zxvf_virtuemart_shoppergroups.virtuemart_shoppergroup_id = zxvf_virtuemart_vmuser_shoppergroups.virtuemart_shoppergroup_id LEFT JOIN zxvf_users ON zxvf_users.id = zxvf_virtuemart_userinfos.virtuemart_user_id GROUP BY email

My template setting:
Action = Export
Component = Virtuemart
Operation = Users Info

I tried Component = Joomla Users but that also results in errors.

Any ideas on how to fix this? Thnx!

Support

Hello,

The reason you see this error is because the database is telling us that the email field exists in multiple places. Now when I run this query on my system, it shows me the results. This makes me wonder, which of these tables in your setup has the email field in it? The zxvf_users should be the only table with an email field. Did you alter any of the tables?

Kind regards,

RolandD

=========================
If you use our extensions, please post a rating and a review at the Joomla! Extension Directory

Author

Yep, I see an 'email' field also in the zxvf_virtuemart_userinfos table. No idea how it got there. And until recently, the CSVI user export worked fine.

What happens if I drop the field from the zxvf_virtuemart_userinfos table? On my development site of course ;-)

Author

Ok, dropping the field seems to have solved the problem, my export is ok now. Just have to check & see if anything else is corrupted now, but so far it looks good.

Support

Hello,

No idea either how the email field ended up in the userinfos table. It is not in the database creation file of VirtueMart. You should be OK by removing it.

Kind regards,

RolandD

=========================
If you use our extensions, please post a rating and a review at the Joomla! Extension Directory

Author

I updated my website 2 weeks ago and then used VM Migrator to copy the latest users and orders to my new site. Maybe something happened there, cannot think of anything else.

Anyway, I dropped the field and all is fine.

Thanks for pointing me in the right direction!

Log in to reply to this topic.