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 8 throw error on varchar(255) table creation on myisam engine #2349

Open
AnnieRuru opened this Issue Jan 4, 2019 · 1 comment

Comments

Projects
None yet
1 participant
@AnnieRuru
Copy link
Contributor

AnnieRuru commented Jan 4, 2019

Describe the bug
mysql 8 doesn't allow table creation with varchar(255) on myisam engine
https://stackoverflow.com/questions/1814532/1071-specified-key-was-too-long-max-key-length-is-767-bytes
https://stackoverflow.com/questions/20014106/how-to-create-this-table-1071-specified-key-was-too-long-max-key-length-is/42497309

To Reproduce
Steps to reproduce the behavior:

  1. install mysql 8
  2. run sql-files/main.sql

Expected behavior
.........

Screenshots
mysql8

System specs (please complete the following information):

  • OS: [e.g. windows 7, 64-bit]
  • Hercules Version [e.g. v2019.01.01]
  • Mode: [renewal]
  • Packet version: still setting up test server
  • Client type: still setting up test server

Plugins used or source modifications
still setting up test server

Additional context
rathena/rathena#3093

@AnnieRuru

This comment has been minimized.

Copy link
Contributor

AnnieRuru commented Jan 4, 2019

1 way to get this done, is do 1 of the provided answer
mysql8_1
use utf8 during schema creation
EDIT: which doesn't support case-sensitive search .....

select * from login;

select email from login where email = 'athena@athena.com';
update login set email = 'athena@athena.coM' where account_id >0;

explain login;
show create table login;

ALTER TABLE login MODIFY COLUMN email VARCHAR(39) COLLATE latin1_general_cs;

after a few tweaking finally able to get this done
yup somehow utf8 table can collate with latin1_general_cs ... ?

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