cmda-bt / be-course-17-18

๐ŸŽ“ Backend ยท 2017-2018 ยท Curriculum and Syllabus ๐Ÿ’พ
Other
47 stars 19 forks source link

Storage assignment #559

Closed Maikxx closed 6 years ago

Maikxx commented 6 years ago

repo

I can not handle any more SQL. After spending hours trying to get PostgreSQL working, it didn't, so I switched over to mySQL, hoping that would go better, it didn't. For some reason this language doesn't seem to make sense to me, with examples like foo.id = ? instead of foo.id === ? or even foo.id == ?. I am so done with it spending way over 12 hours trying to get things working. This is as far as I'll go. Everything works (when I last tested) except adding new animals, I also added a dump of four animals I added, as well as a schema. Usually I don't get so salty, but when time pressure is on and this comes along, I don't get along well with it.

rijkvanzanten commented 6 years ago

Hey @Maikxx!

I'm not able to start your application ๐Ÿ˜ž I get an Error: ER_ACCESS_DENIED_ERROR. This is most likely due to the fact that you don't use a password in your connection to mysql.

https://github.com/Maikxx/shelter/blob/master/server/index.js#L15-L19

Could you update just that one thing so I can check it out? ๐Ÿ˜„

wooorm commented 6 years ago

@Maikxx Ping!

Maikxx commented 6 years ago

For what it's worth, ehm I did not indeed set a password on purpose, so that this wouldn't happen. So I just need to set a password on it? Updated code

rijkvanzanten commented 6 years ago

Hey @Maikxx! Your code looks pretty good, but no matter what I do, I get a 500 error.. I tried using your SQL script as found in the readme to initialize my DB. That failed due to a syntax error in the SQL:

You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near 'NOT NULL,
  description TEXT CHARACTER SET utf8,
  sex ENUM('male', 'female') NO' at line 6

I then proceeded to install the DB using the SQL file I found in your repo. It installed fine, but doesn't seem to play nicely with your code, as every page I open results in a 500 internal server error.