php - SQLSTATE[23502]: Not null violation: 7 ERROR: null value in column
Get the solution ↓↓↓I am building an application with postgres as my preferred database. I have a users table and in the process of saving into it, I got the error below:
SQLSTATE[23502]: Not null violation: 7 ERROR: null value in column \"verification_code\" violates not-null constraint\nDETAIL: Failing row contains (825, 2348035442578, S-LF79a_O3ELcNc0TQmLOjy5No0KScjT, $2y$13$tPS82tr5pH2CHfNiZ9OSKOmE/z8iXOpc0PQ0uGWmeQYXtMX9AguBq, null, [email protected], null, 0, 11, 2020-04-25 13:54:32, 2020-04-25 13:54:32, null, null, null, null).\nThe SQL being executed was: INSERT INTO \"users\" (\"username\", \"auth_key\", \"password_hash\", \"email\", \"isActivated\", \"status\", \"created_at\", \"updated_at\") VALUES ('2348035442578', 'S-LF79a_O3ELcNc0TQmLOjy5No0KScjT', '$2y$13$tPS82tr5pH2CHfNiZ9OSKOmE/z8iXOpc0PQ0uGWmeQYXtMX9AguBq', '[email protected]', 0, 11, NOW(), NOW()) RETURNING \"id\"
Here is the table structure:
Table "public.users"
Column | Type | Collation | Nullable | Default
Where do you think I should check for correction or what exactly am I not doing right?
Answer
Share solution ↓
Additional Information:
Link To Answer People are also looking for solutions of the problem: call to undefined function mysqli_connect()
Didn't find the answer?
Our community is visited by hundreds of web development professionals every day. Ask your question and get a quick answer for free.
Similar questions
Find the answer in similar questions on our website.
Write quick answer
Do you know the answer to this question? Write a quick response to it. With your help, we will make our community stronger.