Skip to Content Skip to Menu

🎃 Happy Halloween! Treat yourself with an awesome discount on memberships! Get 20% off now with code SPOOKY-2024!

Problem with Installation or Database?

  • krileon
  • krileon
  • ONLINE
  • Posts: 48460
  • Thanks: 8280
  • Karma: 1443
11 years 5 months ago #227790 by krileon
Replied by krileon on topic Problem with Installation or Database?

(1) There is no problem at all with the change to text type, and the site will be running fine as before, right?

Yes, it's perfectly fine to make the change.

(2) Since I changed the database using phpMyAdmin, when I ran the CB Tools from the backend, as the core xml file was not changed, it reported inconsistencies like being "text" type instead of "varchar". This is expected. I just leave them as such, right?

This is normal. CB field check tool checks field column types. Only way to get rid of this is to adjust the type in cb.core.xml or simply ignore it.

(3) Of course, the easier way should have been changing the core xml file. As you suggested, when CB Tools is run, it will show the incorrect type in the database, and can be fixed. But I couldn't find in which all places the type should be changed into "text". In other words, I really didn't understand what you said exactly. I have attached the core xml file for your review. Would you be kind enough to guide me?

Just fix it for Text and Select type fields as those are the most commonly used so fixing just them 2 should solve your issue. So you'll want to adjust the below for example.

FROM:
Code:
<field type="select" label="Drop Down (Single Select)"> <data name="" nametype="namesuffix" type="sql:varchar(255)" null="true" default="NULL" strict="false" />
TO:
Code:
<field type="select" label="Drop Down (Single Select)"> <data name="" nametype="namesuffix" type="sql:text" null="true" default="NULL" strict="false" />

FROM:
Code:
<field type="text" label="Text Field"> <data name="" nametype="namesuffix" type="sql:varchar(255)" null="true" default="NULL" strict="false" />
TO:
Code:
<field type="text" label="Text Field"> <data name="" nametype="namesuffix" type="sql:text" null="true" default="NULL" strict="false" />

If you have a bunch of Radio, Web Address, or Email fields you may want to adjust them too, but typically the above is all you should need to change.

(4) If the core xml file is changed, will future CB upgrades change the type back to "varchar", as I presume the core xml file will be written over?

Yes, you'll need to apply the change with each new CB release. Shouldn't be too much of a concern as CB 2.0 will have this fixed internally and next 1.x release is a bug fix release so should be only 1 more release where you'd need to apply the fix manually.

(5) Do I have to do this field type change if I am moving to JP hosting with MySQL 5.5? If 'yes,' I will keep the engine as MyISAM itself (the current setting) and change the field type to "text" before moving to JP hosting, and then import the database into JP hosting. Please guide me..

It's a MYSQL limitation so yes it'll happen on JP hosting as well (It'll happen on every host). If you change before moving then it'll stay as what you changed it to and you won't need to do it again.


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: interspaceintel

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

Moderators: beatnantkrileon
Powered by Kunena Forum