On 11/11/2016 12:18 PM, Michael Williamson wrote:
That still requires the repetition of the name of the attribute, which
I'd rather avoid. I've put together a variation on hybrid_property
which automatically assigns the label by scanning through the class
dict. It could probably do with a bit
On Fri, 11 Nov 2016 11:59:52 -0500
mike bayer wrote:
>
>
> On 11/11/2016 07:20 AM, Michael Williamson wrote:
> > I'm using hybrid_property, and would like the key of the property
> > to be set to the attribute name, rather than the name of the
> > getter. This is
On 11/11/2016 07:20 AM, Michael Williamson wrote:
I'm using hybrid_property, and would like the key of the property to be
set to the attribute name, rather than the name of the getter. This is
because I'm generating a getter function based on some args, rather than
having the caller directly
I should add: The specific queries I was running that were throwing the
error all worked using your test case setup.
Greg--
On Fri, Nov 11, 2016 at 10:50 AM, Greg M. Silverman wrote:
> Hi Mike,
> Modifications of your test made to point to the actual database file I am
>
Hi Mike,
Modifications of your test made to point to the actual database file I am
using worked. The only difference in your test versus my code is that my
ClinicalData class definition uses a Flask db.Model versus a straight
declarative_base. I'll need to play around with this a bit more.
On Friday, November 11, 2016 at 2:22:28 PM UTC, Simon King wrote:
>
> On Fri, Nov 11, 2016 at 1:53 PM, Michael Williamson > wrote:
> >
> >> I think your code is basically fine, you've just got a mistake on the
> >> last line. Presumably you meant to query Person, not
SQLAlchemy has a case sensitivity behavior that assumes an all lowercase
name to indicate "case insensitive". Firebird and Oracle both use
ALL_UPPERCASE to indicate "case insensitive". SQLAlchemy converts
between these two.
Therefore if your table shows up in Firebird as SOME_TABLE,
On Fri, Nov 11, 2016 at 1:53 PM, Michael Williamson wrote:
>
>> I think your code is basically fine, you've just got a mistake on the
>> last line. Presumably you meant to query Person, not Person.born?
>
>
> I want Person.born so that I don't have to get the entire object. It
> I think your code is basically fine, you've just got a mistake on the
> last line. Presumably you meant to query Person, not Person.born?
>
I want Person.born so that I don't have to get the entire object. It
doesn't make much difference in this example, but is quite important for us
in
On Fri, Nov 11, 2016 at 12:20 PM, Michael Williamson wrote:
> I'm using hybrid_property, and would like the key of the property to be set
> to the attribute name, rather than the name of the getter. This is because
> I'm generating a getter function based on some args, rather
I'm using hybrid_property, and would like the key of the property to be set
to the attribute name, rather than the name of the getter. This is because
I'm generating a getter function based on some args, rather than having the
caller directly defining the getter. As a minimal example:
from
Hello, I'm trying to reflect existing FireBird database like
metadata.reflect(engine) it's works ok with UPPERCASE tablename but with
lowercase name raise exception:
reflection.py, line 598, in reflecttable
raise exc.NoSuchTableError(table.name)
sqlalchemy.exc.NoSuchTableError: foo_states
On Fri, Nov 11, 2016 at 6:59 AM, Alfred Soeng wrote:
> It's the issue in the inheritance:
> What I want to do is like this:
> class Employee(Base):
> __tablename__ = 'employee'
> id = Column(
> Integer,
> primary_key=True,
> )
> type_name =
On Fri, Nov 11, 2016 at 7:59 AM, Muhammad Aldo Firmansyah
wrote:
> I want to make API using flask, flask-restless and flask sqlalchemy.
> Database using postgres
>
> Here's my model. The relation below is one-to-many (User have one or many
> tasks. And a task is
14 matches
Mail list logo