Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

Already on GitHub? Sign in to your account

Sequel::Model#create with null values is broken #253

Closed
jeremyevans opened this Issue May 1, 2011 · 2 comments

Comments

Projects
None yet
1 participant
Owner

jeremyevans commented May 1, 2011

class Test < Sequel::Model(:test)
set_schema do
primary_key :id
int :field, :null => true
end

create_table!
end

inserts a 0 instead of a null

INSERT INTO test (field) VALUES (0)

t = Test.create :field => nil

Google Code Info:
Issue #: 228
Author: themaste...@gmail.com
Created On: 2008-05-23T08:17:28.000Z
Closed On: 2008-05-24T03:32:55.000Z

@ghost ghost assigned jeremyevans May 1, 2011

@jeremyevans jeremyevans closed this May 1, 2011

Owner

jeremyevans commented May 1, 2011

Patch here: http://github.com/tmm1/sequel/commit/c65aa2df50c077bb277a8a3ec2cbee52dcc1a6dc

Google Code Info:
Author: themaste...@gmail.com
Created On: 2008-05-23T19:02:47.000Z

Owner

jeremyevans commented May 1, 2011

Applied with some changes:
http://github.com/jeremyevans/sequel/commit/0bf3e462856691e2fe0c0796549889aa7aef0f2c

Google Code Info:
Author: jeremyev...@gmail.com
Created On: 2008-05-24T03:32:55.000Z

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment