jcrespo added a subscriber: jcrespo.
jcrespo added a comment.

First comments from a MySQL DBA, assuming that goes to production:

- Some tables lack of a `PRIMARY KEY`.** This should be a requirement for new 
tables**.
- character strings do not have a specified `CHARACTER SET`. Check that those 
do not have to be `BINARY` fields for compatibility with current wiki fields or 
set them otherwise (by default, they may be restricted to latin characters in 
some systems).
- Unless there is a reason not to, add the index definition along the table 
creation, and not with separate `CREATE INDEX` afterwards. While the results 
are the same from the point of view of the application, not from the point of 
view of maintaining hundreds of wikis.
- Some `PRIMARY KEY`s use guid strings. Those should be justified by external 
dependencies, otherwise stick to int or bigint for better innodb performance.
- `VARBINARY(15)` for import_date seems like a bad idea, there are specific 
data types for that.
- There is a tendency of using `VARCHAR(255)` for variable length fields. 
Please note that using `VARCHAR(255)` is not an advantage over `VARCHAR(256)`, 
and that smaller sizes are usually preferred (again, unless justified by 
existing types).


TASK DETAIL
  https://phabricator.wikimedia.org/T102992

EMAIL PREFERENCES
  https://phabricator.wikimedia.org/settings/panel/emailpreferences/

To: jcrespo
Cc: jcrespo, Tamslo, JAnstee_WMF, csteipp, Springle, hoo, Aklapper, daniel, 
Wikidata-bugs, aude, GWicke, Krenair, Malyacko, P.Copp



_______________________________________________
Wikidata-bugs mailing list
[email protected]
https://lists.wikimedia.org/mailman/listinfo/wikidata-bugs

Reply via email to