Skip to Content Skip to Menu

🌟 CB Editor Assistant 1.0.0 is here! Discover our new AI Joomla Plugin that wrote its story! (and this banner!)
Start at just $12.50/month* or 💸 save 30% with our 🛍️ Black Friday Intro Offer for your subscription's lifetime
🎉 Black Friday sale is here! Great savings on professional and developer memberships! Get 25% off now with code BLACK-FRIDAY-2024!

[SOLVED] Required Query field; edit not recognised

  • krileon
  • krileon
  • ONLINE
  • Posts: 48560
  • Thanks: 8292
  • Karma: 1445
6 years 10 months ago #301297 by krileon
Replied by krileon on topic Required Query field; edit not recognised
Have reviewed your install. I'm not sure why, but seams to be an issue specifically with those fields. I created a new test query select field with same usage as your country field and it worked fine. Were these query fields some other fieldtype at some point? Changing a fields type can sometimes mess up the data storage for them. Suggest recreating your two query fields.


Kyle (Krileon)
Community Builder Team Member
Before posting on forums: Read FAQ thoroughly + Read our Documentation + Search the forums
CB links: Documentation - Localization - CB Quickstart - CB Paid Subscriptions - Add-Ons - Forge
--
If you are a Professional, Developer, or CB Paid Subscriptions subscriber and have a support issue please always post in your respective support forums for best results!
--
If I've missed your support post with a delay of 3 days or greater and are a Professional, Developer, or CBSubs subscriber please send me a private message with your thread and will reply when possible!
--
Please note I am available Monday - Friday from 8:00 AM CST to 4:00 PM CST. I am away on weekends (Saturday and Sunday) and if I've missed your post on or before a weekend after business hours please wait for the next following business day (Monday) and will get to your issue as soon as possible, thank you.
--
My role here is to provide guidance and assistance. I cannot provide custom code for each custom requirement. Please do not inquire me about custom development.

Please Log in or Create an account to join the conversation.

6 years 10 months ago #301302 by Thelowlandpiper
Replied by Thelowlandpiper on topic Required Query field; edit not recognised
I noticed when looking at the comprofiler table in the database that the field type for both fields was Text rather than INT, which is the data type of the field being read from the countries/zones table ; changing these datatypes does not seem to have solved the problem.
The fields certainly underwent some major manipulation when I realised that the J2Store customer address tables needed varchar(255) which is why I changed the comprofiler field datatype to Text (in error, of course; it should have been varchar, though I can't see that this would interfere with storing the data in the comprofiler fields) changing these datatypes to INT(11) does not seem to have solved the problem.


So following your suggestion,
If I create new fields. is there an easy way to transfer the data or do I need to do it via SQL in the database
I presume that saving a copy of these two fields will probably not be enough?

Please Log in or Create an account to join the conversation.

  • krileon
  • krileon
  • ONLINE
  • Posts: 48560
  • Thanks: 8292
  • Karma: 1445
6 years 10 months ago #301303 by krileon
Replied by krileon on topic Required Query field; edit not recognised
The columns should be text. Suggest just recreating them as my test field worked fine with your exact query setup on your site. In the future please do not alter CBs database structure.

If I create new fields. is there an easy way to transfer the data or do I need to do it via SQL in the database

Yes, you can do a simple update query ran directly on your database to move the data. Example as follows.

Code:
UPDATE `jos_comprofiler` SET `new_field_name` = `old_field_name`

Be sure to of course replace new_field_name and old_field_name as needed as well as the jos_ prefix with whatever your table prefix is.


Kyle (Krileon)
Community Builder Team Member
Before posting on forums: Read FAQ thoroughly + Read our Documentation + Search the forums
CB links: Documentation - Localization - CB Quickstart - CB Paid Subscriptions - Add-Ons - Forge
--
If you are a Professional, Developer, or CB Paid Subscriptions subscriber and have a support issue please always post in your respective support forums for best results!
--
If I've missed your support post with a delay of 3 days or greater and are a Professional, Developer, or CBSubs subscriber please send me a private message with your thread and will reply when possible!
--
Please note I am available Monday - Friday from 8:00 AM CST to 4:00 PM CST. I am away on weekends (Saturday and Sunday) and if I've missed your post on or before a weekend after business hours please wait for the next following business day (Monday) and will get to your issue as soon as possible, thank you.
--
My role here is to provide guidance and assistance. I cannot provide custom code for each custom requirement. Please do not inquire me about custom development.
The following user(s) said Thank You: Thelowlandpiper

Please Log in or Create an account to join the conversation.

6 years 10 months ago #301313 by Thelowlandpiper
Replied by Thelowlandpiper on topic Required Query field; edit not recognised
Many thanks for solving this; I've replaced the fields and copied the data and the front-end profile required fields can now be updated.
To anyone else viewing this, remember that if you create a new state query field that depends on a new country query fied you will have to update both the query, and the 'update from' fields in the state field!
The following user(s) said Thank You: krileon

Please Log in or Create an account to join the conversation.

Moderators: beatnantkrileon
Powered by Kunena Forum