I am developing a website to track weight and calorie lifting. I had never developed my own database before, and I decided that I should get as much space as possible before starting coding. Every time I think I am done, it seems to me that it is not perfect. I mainly use MySQL Workbench, but I still have a few questions.
I also attached an ERM chart. If anyone could point out any obvious violations, that would be greatly appreciated.
Begin as beautifully as you can, and then make it as imperfect as possible.
No practical, operational database is perfect. All warts have.
, , . , . , , .
, , - .
, , , .. , . .
... 1. . . . 2. badges- > userbadges. , PK (id). 3. id (.. User, "userid", "id" "foodid" ). - , .
" SQL" , SQL " " .
Codd (3NF/BCNF ). - ( , ) .., , . . .
:
exercise , , - secondary1, secondary2, secondaryN... ! :
exercise
userid PK (varchar), usernumber int? , . , , ( id), , - . , userid ( username?) ( - " " , ).
userid
usernumber
id
username
(userid vs usernumber vs id). , . , , , , .
. .
... exercise. secondary1 to secondary10 -, , , . , , , , ? .
secondary1
secondary10
, ( ) , . ( ). , .
. :
1 - . , /.
2 - / UTC . ( datetime unix, . mysql DATETIME.)
, , . mysql , , . , , script, ( ) . . , . ram, , .
, , . Boyce-Codd/5th Normal Form , .
, , . , , , , . YAGNI Agile, , .
, , , , . , , - , . - , , , , .
"". . , , , , .
- . .
, , . , BCNF. , .
. . . CJ . , , .
, , , . , .
.
!
- , .
, .
Source: https://habr.com/ru/post/1780140/More articles:ASPNETDB.MDF file not showing up in APP_DATA - asp.netObjectDisposedException when calling Abort in an HttpWebRequest used asynchronously - c #CreateFile error with error ERROR_SHARING_VIOLATION - c ++Accents, URLs and Firefox - htmlsslv3 warns of an unexpected message when using soap4r - ruby | fooobar.com2D OpenGL drawing lines that don't exactly match the pixel raster - cThe best way to get closer to loading a class from a comma-delimited file is coding-styleWhy spring security kerberos extension 1.0.0.M2 does not work for jdk 1.6.0_22 and higher - spring-securityЕсть ли рельсовая жемчужина, которая тянет твиты из твиттера в объект, который я могу повторить? - ruby-on-railsBuilt-in javascript interpreter for php - javascriptAll Articles