Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

MySQL issue can't a text column have a default value in MySQL #41

Open
AlfredoPagano opened this issue Jun 26, 2019 · 3 comments
Open

Comments

@AlfredoPagano
Copy link

Hi @mdziekon

I understood why you put in README:
Setup a MySQL server. Disable STRICT_TRANS_TABLES mode.

Basically, I noticed the MySQL has an Issue on some operative system where the "Text" field cannot have a default value: this can be bypassed as you wrote OR otherwise is possible put all "Text" field as DEFAULT NULL.

I noticed this issue using Altervista (hosting site) and i solved it putting the "Text" fields as default null : this is needed in case the user don't have the "Admin" control of the MySQL database.

An Example of issue:

Field 'screen_settings' doesn't have a default value
INSERT INTO Uni1_users SET username = 'TestReg', email = '[email protected]', email_2 = '[email protected]', ip_at_reg = '78.13.222.196', id_planet = 0, register_time = 1561585694, onlinetime = 1561585694 - (246060), rules_accept_stamp = 1561585694, password = MD5('TestReg');
File: /Uni1/reg_ajax.php?callback=regCallback&register=1&username=TestReg&password=TestReg&email=email%40email.it&galaxy=1&rules=on&captcha_response=&_=1561585694040
User: []

https://stackoverflow.com/questions/3466872/why-cant-a-text-column-have-a-default-value-in-mysql/25233562

Do you see any issue putting these Text fields as DEFAULT NULL ?

Best regards,
Alfredo.

@sixu83
Copy link

sixu83 commented Apr 27, 2020

Hi, AlfredoPagano

I've been trying to install the game, simply to test out its capabilities and ran into the same problem. I don't have the privleges on the server to change the tables mode.

could you post or otherwise send me the code (or tell me what I need to change) in order to bypass this limitation?

Thanks so much!

(apologies for sounding stupid, I'm not really a coder, as I am a graphical artist)

@mdziekon
Copy link
Owner

Hi @sixu83, since all you want (for now, at least) is to try this engine out, I would recommend an alternate solution. Instead of running it on a remote server, you can always setup an instance on your local machine. I don't know what OS do you use, but to prevent any mess on your computer, your best options are either a virtualized instance (eg. using VirtualBox, or Vagrant to automate it a bit) or containerized instance (using Docker).

I could share my local development docker-compose.yml file here, but it's far from perfect and it will most likely need some tinkering to do the initial bootstrap.

@sixu83
Copy link

sixu83 commented Apr 29, 2020

If no remote server option is possible, then sure I will look into docker. I was looking at the suggestions you mentioned and that looks the most impressive.

Let me know if you need any menial grunt work in finding a way to bypass the strict tables, would be happy to help.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

3 participants