I have some working SQL that gets the last two id's (autoincremented) in a
TaskRevisons table that has a column that maps to an id in a Tasks table.
The SQL is:
select task_id, id from TaskRevisions where (
select count(*) from TaskRevisions as t
where t.task_id = TaskRevisions.task_id and
Hello Guys,
I was having issues cause some empty arguments were treated as "" (emtpy)
instead of none, so the filter() was translating the query as 'where
column=""' instead of "where column is NULL", so I'm trying to write some
validation in my add method in my classes:
class
On Friday, June 17, 2016 at 12:14:05 PM UTC-5, Mike Bayer wrote:
>
>
>
> On 06/17/2016 12:44 PM, Chuck Bearden wrote:
> > I'm using SQLAlchemy 1.0.13 with Python 2.7.10.
> >
> > I load much of my data naively from text files, which means that for
> > newly-created Declarative objects, all the
On Friday, June 17, 2016 at 1:14:05 PM UTC-4, Mike Bayer wrote:
>
> seems appropriate for a basic validator:
>
>
> http://docs.sqlalchemy.org/en/rel_1_0/orm/mapped_attributes.html?highlight=validates#simple-validators
>
>
>
There's also the 'descriptor' pattern (on the same page as the
On 06/17/2016 12:44 PM, Chuck Bearden wrote:
I'm using SQLAlchemy 1.0.13 with Python 2.7.10.
I load much of my data naively from text files, which means that for
newly-created Declarative objects, all the values are strings, whatever
the declared column type:
|
fromsqlalchemy.ext.declarative
I'm using SQLAlchemy 1.0.13 with Python 2.7.10.
I load much of my data naively from text files, which means that for
newly-created Declarative objects, all the values are strings, whatever the
declared column type:
from sqlalchemy.ext.declarative import declarative_base
from sqlalchemy import