[web2py] Re: Empty strings stored as null in database

2016-04-17 Thread kenny c
thank you Leonel and Niphlod! -- Resources: - http://web2py.com - http://web2py.com/book (Documentation) - http://github.com/web2py/web2py (Source code) - https://code.google.com/p/web2py/issues/list (Report Issues) --- You received this message because you are subscribed to the Google Groups "

Re: [web2py] Re: Empty strings stored as null in database

2016-04-14 Thread Raul Monares
I just tested 2.14.5 and the solution is working. Great job !! On Thursday, April 14, 2016 at 7:46:57 AM UTC-6, Richard wrote: > > Let test then!! > > On Thu, Apr 14, 2016 at 9:15 AM, Niphlod > > wrote: > >> I hear you and I'm happy (or not, not sure) to not being alone ranting >> about web2py's

Re: [web2py] Re: Empty strings stored as null in database

2016-04-14 Thread Richard Vézina
Let test then!! On Thu, Apr 14, 2016 at 9:15 AM, Niphlod wrote: > I hear you and I'm happy (or not, not sure) to not being alone ranting > about web2py's code quality and lack of tests. this was a serious bug that > should have had the effect of retiring web2py's release until it was fixed > (or

[web2py] Re: Empty strings stored as null in database

2016-04-14 Thread Niphlod
I hear you and I'm happy (or not, not sure) to not being alone ranting about web2py's code quality and lack of tests. this was a serious bug that should have had the effect of retiring web2py's release until it was fixed (or at least loudly advertised). On Thursday, April 14, 2016 at 5:08:24 AM

[web2py] Re: Empty strings stored as null in database

2016-04-13 Thread Leonel Câmara
Ok I've fixed it: https://github.com/web2py/web2py/pull/1294 And now I hate you guys with a tremendous passion. It took me a huge amount of time for a fix that ended up being a oneliner. html.py is horrible, Cthulhu level horrible, it couldn't be harder to follow its execution flow if it had go

[web2py] Re: Empty strings stored as null in database

2016-04-13 Thread David Manns
This problem is still in 2.14.4. This use case suggests the problem is within form handling, nothing to do with database or adapter. David Manns On Monday, April 11, 2016 at 10:06:41 AM UTC-4, David Manns wrote: > > There is a similar problem with SQLFORM.factory. E.g: > > searchform=SQLFORM

[web2py] Re: Empty strings stored as null in database

2016-04-11 Thread David Manns
There is a similar problem with SQLFORM.factory. E.g: searchform=SQLFORM.factory( Field('name', 'string', default='', comment='(start of) last name'), Field('status', 'string', requires=IS_EMPTY_OR(IS_IN_SET(['Full', 'Student', 'Comp', 'Inactive']))), Field('paid_year'

[web2py] Re: Empty strings stored as null in database

2016-04-05 Thread Anthony
I cannot replicate with SQLite. How are you doing the insert, and how are you verifying the value that ends up in the database? On Tuesday, April 5, 2016 at 1:00:07 PM UTC-4, Raul Monares wrote: > > I just did a test using sqlite. It also inserted a column with a null value > > Here is a sample c

[web2py] Re: Empty strings stored as null in database

2016-04-05 Thread Raul Monares
I just did a test using sqlite. It also inserted a column with a null value Here is a sample code db.define_table('actividades', Field('descripcion','string',length=100,label='Descripcion',default='') ) On Monday, April 4, 2016 at 2:48:10 PM UTC-6, Anthony wrote

[web2py] Re: Empty strings stored as null in database

2016-04-04 Thread Anthony
Also, can you check whether the same problem occurs with SQLite? On Monday, April 4, 2016 at 4:47:33 PM UTC-4, Anthony wrote: > > Can you show some code? I think Firebird uses the same insert code as the > base adapter, and that appears to correctly insert an empty string. > > Anthony > > On Mond

[web2py] Re: Empty strings stored as null in database

2016-04-04 Thread Anthony
Can you show some code? I think Firebird uses the same insert code as the base adapter, and that appears to correctly insert an empty string. Anthony On Monday, April 4, 2016 at 3:54:10 PM UTC-4, Raul Monares wrote: > > It appears that default='' in the field constructor is being ignored. When

[web2py] Re: Empty strings stored as null in database

2016-04-04 Thread Dave S
On Monday, April 4, 2016 at 12:54:10 PM UTC-7, Raul Monares wrote: > > It appears that default='' in the field constructor is being ignored. When > I later do an update to the same field with an empty string, it is stored > correctly in the database. > > I don't know if that would be in dal.py, p

[web2py] Re: Empty strings stored as null in database

2016-04-04 Thread Raul Monares
It appears that default='' in the field constructor is being ignored. When I later do an update to the same field with an empty string, it is stored correctly in the database. On Friday, April 1, 2016 at 12:41:12 PM UTC-6, Raul Monares wrote: > > I'm using Firebird 2.5.4 on Freebsd 10.2 > > >

[web2py] Re: Empty strings stored as null in database

2016-04-01 Thread Raul Monares
I'm using Firebird 2.5.4 on Freebsd 10.2 On Friday, April 1, 2016 at 12:01:00 PM UTC-6, Dave S wrote: > > On Thursday, March 31, 2016 at 7:39:23 PM UTC-7, Raul Monares wrote: >> >> Hello >> I just updated to version 2.14.3 and noticed that empty strings are being >> stored as null in database fi

[web2py] Re: Empty strings stored as null in database

2016-04-01 Thread Dave S
On Thursday, March 31, 2016 at 7:39:23 PM UTC-7, Raul Monares wrote: > > Hello > I just updated to version 2.14.3 and noticed that empty strings are being > stored as null in database field. This didn't happened in 2.13.4. > > Is this the intended behavior ? > Which database engine are you using?