Welcome to the Treehouse Community

Want to collaborate on code errors? Have bugs you need feedback on? Looking for an extra set of eyes on your latest project? Get support with fellow developers, designers, and programmers of all backgrounds and skill levels here with the Treehouse Community! While you're at it, check out some resources Treehouse students have shared here.

Looking to learn something new?

Treehouse offers a seven day free trial for new students. Get access to thousands of hours of content and join thousands of Treehouse students and alumni in the community today.

Start your free trial

JavaScript Using SQL ORMs with Node.js Defining Models Add Validations to a Model

Jordan Kittle
seal-mask
.a{fill-rule:evenodd;}techdegree seal-36
Jordan Kittle
Full Stack JavaScript Techdegree Graduate 20,147 Points

Using latest version of SQLite3 and Sequelize do not allow for custom notNull error messages. Is there a workaround?

I was unable to install the version of SQLite3 that this project called for, so I updated to the latest versions of SQLite3 and Sequelize. I'm sure this is the reason why I can't get custom notNull messages working, but I was wondering if anybody knew how to get them working with the latest versions. Thank you for your help.

Hei,

It was long time ago, you posted this, :) but if it's still actual, can you provide your code? I could set custom error message without any problem with the latest SQLite.

Thanks.

Jordan Kittle
seal-mask
.a{fill-rule:evenodd;}techdegree seal-36
Jordan Kittle
Full Stack JavaScript Techdegree Graduate 20,147 Points

Adam Csetneki hi thanks for responding. My question was posted in response to this thread that I read. I wasn't able to get notNull custom messages to work. Is it possible your notEmpty messages are what you see working instead of notNull? https://github.com/sequelize/sequelize/issues/1500

1 Answer

Oi yes, Indeed. :) I used notEmpty for the first place. :) But at least, It would be provided in your question, even though you answered yourself. :)