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

Not null specified as column types who recieve null value on initial account creation #61

Open
aaronduchateau opened this issue Nov 27, 2018 · 2 comments

Comments

@aaronduchateau
Copy link

aaronduchateau commented Nov 27, 2018

Hey Guys, first of all, nice project. I'm excited to start messing around with it.

in your db.sql dump i'm noticing not null constraints on almost (if not all) of the tables. The app fired up fine but columns like user.instagram are crapping out on account creation.

My workaround for now was just to make those columns nullable and re-import the db.

account_type enum('public','private') COLLATE utf8mb4_bin NOT NULL DEFAULT 'public',
instagram varchar(500) COLLATE utf8mb4_bin NULL,
twitter varchar(500) COLLATE utf8mb4_bin NULL,
facebook varchar(500) COLLATE utf8mb4_bin NULL,

etc...

Just wondering what you are doing on your side to deal with this, as I assume something is converting those missing columns into empty strings to avoid those errors when an account is created (on your side).

Also getting a bunch of Expression #1 of ORDER BY clause is not in SELECT list, references column 'gitmenu.hashtags.hashtag_time' which is not in SELECT list; this is incompatible with DISTINCT errors.... My understanding is that these errors can be dependent on the version of SQL you are running, so might be good to include that in the #readme...

Circumnavigating that for now by adding hashtag_time to the selection...

Also noticing i'm needing to add backticks to many of the table names for the queries not to fail. I'm running mySQL 8.0.11

Cheers,
Aaron

@dev1Blayzer
Copy link

yes, I had the same problem

@TheRadRabbit
Copy link

This is because MySQL is in 'strict' mode - by default. You'll need to turn off strict mode to effectively ignore these issues. See here: https://stackoverflow.com/questions/40881773/how-to-turn-on-off-mysql-strict-mode-in-localhost-xampp

Note to make it permanent (every time MySQL is started) you'll need to make the change in the .ini file or .cnf (win/linux)

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

No branches or pull requests

3 participants