Thank you! You eliberated me to finally move to the next step in my
project, this kept me at a standstill.
Thank you !
marți, 11 septembrie 2018, 12:59:18 UTC+3, Simon King a scris:
>
> On Tue, Sep 11, 2018 at 9:39 AM George Brande > wrote:
> >
> > Hello.
> >
> > My angular is using a
On Tue, Sep 11, 2018 at 9:39 AM George Brande wrote:
>
> Hello.
>
> My angular is using a datepicker to send a date in string format(ex:
> 2018-09-11) to my flask app to postgres via sqlalchemy.
> In my postgres all rows have a column ef_time of timestamps type.(ex:
> 2018-09-07 13:24:30.138)
>
Hello.
My angular is using a datepicker to send a date in string format(ex:
2018-09-11) to my flask app to postgres via sqlalchemy.
In my postgres all rows have a column ef_time of timestamps type.(ex:
2018-09-07
13:24:30.138)
@app.route('/orders/')
def get_orders(ide):
session = Session()
On 03/11/2017 10:15 AM, mike bayer wrote:
On 03/10/2017 11:12 AM, Alessandro Molina wrote:
On Fri, Mar 10, 2017 at 3:40 PM, mike bayer > wrote:
If this is truly, "unexpected error but we need to do things",
perhaps you
On 03/10/2017 11:12 AM, Alessandro Molina wrote:
On Fri, Mar 10, 2017 at 3:40 PM, mike bayer > wrote:
If this is truly, "unexpected error but we need to do things",
perhaps you can use before_flush() to memoize the details
On Fri, Mar 10, 2017 at 4:12 PM, Alessandro Molina
wrote:
>
>
> On Fri, Mar 10, 2017 at 3:40 PM, mike bayer
> wrote:
>>
>> If this is truly, "unexpected error but we need to do things", perhaps you
>> can use before_flush() to memoize the
On Fri, Mar 10, 2017 at 3:40 PM, mike bayer
wrote:
> If this is truly, "unexpected error but we need to do things", perhaps you
> can use before_flush() to memoize the details you need for a restore inside
> of session.info.
>
> An event hook can be added but it would
On 03/10/2017 01:57 AM, Alessandro Molina wrote:
I have been looking for a way to know what's going to be rolled back in
SQLAlchemy so that I can know what was changed and restore other
database unrelated things to their previous state.
By
I have been looking for a way to know what's going to be rolled back in
SQLAlchemy so that I can know what was changed and restore other database
unrelated things to their previous state.
By http://docs.sqlalchemy.org/en/latest/orm/events.html#session-events it
looks like it's available an
Hello,
I'm currently implementing a RBAC-like model for a webapp with the
usual suspects: users, roles, permissions, etc where a Role has one
or more Permissions, and an User can be in 1 or more Role.
I would like to some virtual-like Role that are automatically
attribued in some
On May 22, 2013, at 7:14 AM, Julien Cigar jci...@ulb.ac.be wrote:
Hello,
I'm currently implementing a RBAC-like model for a webapp with the usual
suspects: users, roles, permissions, etc where a Role has one or more
Permissions, and an User can be in 1 or more Role.
I would like to
On Aug 22, 2012, at 11:38 PM, Warwick Prince wrote:
Thanks Michael
I struggle sometimes to find examples of the simple things, so eventually
searched out the like_op as it was in the same place as eq() etc.
So, on that subject - is it better to use query.where(eq(a, b)) or
OK - cool.
I had looked at the first ORM tutorial, but I guess I had glossed over it, as
it was talking about session.query, and I believed I was looking for something
lower level than that for the direct table.select. Obviously not. :-) Makes
sense that it would all follow suit, but I was
Hi
When creating a basic query, how does one code a NOT LIKE using SA?
I can do this;
query = table.select().where(like_op(table.c.name, 'fred%'))
I can not find a NOT LIKE operator. The ones there notlike_op and
notilike_op raise NotImplemented.
I've placed it in as text('%s NOT LIKE %s')
not sure why the like_op and nolike_op have come into your normal
vocabulary here as they are usually just the ops used internally.
LIKE is column.like(other) and NOT LIKE is ~column.like(other).
On Aug 22, 2012, at 9:15 PM, Warwick Prince wrote:
Hi
When creating a basic query, how does
Thanks Michael
I struggle sometimes to find examples of the simple things, so eventually
searched out the like_op as it was in the same place as eq() etc.
So, on that subject - is it better to use query.where(eq(a, b)) or
query.where(a==b), or does it make no difference really?
not sure
I'm trying to do a like statement in a query filter. I'm fine doing it one way
for instance
session.query(Table).filter(Table.path.like(C:\Test\%))
which would hopefully return all folders and files in the folder Test
but what if I want to do it the other way around and pass
sure it does, if you convert it to a SQL token first:
literal(C:\test\testfile.txt).like(Table.path + %)
or even
literal(C:\test\testfile.txt).startswith(Table.path)
On Nov 7, 2011, at 8:40 AM, Paul wrote:
I'm trying to do a like statement in a query filter. I'm fine doing it one way
for
Hi All-
I'm a long-time Django user who has become accustomed to Django's easy
generation and loading of test fixtures (i.e., a known database state
for testing) and I'm looking for something similar for SQLAlchemy.
I've seen and been working with Kumar's fixture project (http://
On Mar 11, 2011, at 2:25 PM, Todd Rowell wrote:
Hi All-
I'm a long-time Django user who has become accustomed to Django's easy
generation and loading of test fixtures (i.e., a known database state
for testing) and I'm looking for something similar for SQLAlchemy.
I've seen and been
Hi *,
I am fighting half a day with something I expected to be trivial: Keep
the order of items in a collection implemented vi a secondary table
(many-to-many relationship).
Basically, I have a Collection class with a relationship to Items in the
collection. That relationship is configured via
On Nov 18, 2010, at 9:32 AM, Torsten Landschoff wrote:
Hi *,
I am fighting half a day with something I expected to be trivial: Keep
the order of items in a collection implemented vi a secondary table
(many-to-many relationship).
Basically, I have a Collection class with a relationship
Hi Michael,
Thanks for your lightning fast reply!
On Thu, 2010-11-18 at 10:17 -0500, Michael Bayer wrote:
this is correct. The functionality provided by secondary is that SQLA will
maintain a table with foreign keys to the related primary keys on either
side. It does not do anything at
On Nov 18, 2010, at 11:01 AM, Torsten Landschoff wrote:
Hi Michael,
Thanks for your lightning fast reply!
On Thu, 2010-11-18 at 10:17 -0500, Michael Bayer wrote:
this is correct. The functionality provided by secondary is that SQLA
will maintain a table with foreign keys to the
I try to update counter for omr object ang got following:
Traceback (most recent call last):
File /home/vugluskr/tmp/z/sa.py, line 56, in module
main()
File /home/vugluskr/tmp/z/sa.py, line 52, in main
q2.update({data.cnt: data.cnt + 1})
File
this is a bug , created at http://www.sqlalchemy.org/trac/ticket/1935 , and a
patch which fixes this issue is there. will try to get this committed soon.
On Sep 30, 2010, at 9:57 AM, bogun.dmit...@gmail.com wrote:
I try to update counter for omr object ang got following:
Traceback
2010/9/30 Michael Bayer mike...@zzzcomputing.com:
this is a bug , created at http://www.sqlalchemy.org/trac/ticket/1935 , and a
patch which fixes this issue is there. will try to get this committed
soon.
Thanks, patch fix issue.
I try to update counter for omr object ang got following:
Hello,
sqlalchemy seems to be the proper tool for my needs but I can't figure
out how to design my project or set the ORM properly.
Let's say, I build a music database, storing tracks and their
associated metadata in an sql-like database defined as such :
TRACK_TABLE ( ident *, url , duration )
On 08/17/2010 11:32 AM, yota wrote:
Hello,
sqlalchemy seems to be the proper tool for my needs but I can't figure
out how to design my project or set the ORM properly.
Let's say, I build a music database, storing tracks and their
associated metadata in an sql-like database defined as such :
I have the following TypeDecorator type to store a tuple of strings as
a delimited string. It works fine but I discovered an abnormality
with LIKE. The right side of a like expression is being passed to the
converter, so it has to be a one-item tuple instead of a string. This
makes my model
is there something similar to inspectdb in sqlalchemy
where it returns orm classes for tables already in the db?
--~--~-~--~~~---~--~~
You received this message because you are subscribed to the Google Groups
sqlalchemy group.
To post to this group, send email to
I have a web application which is accessed from different sub-domains.
Each sub-domain corresponds to one row/object in installation table.
I am fetching this one row/object on every request which is
unnecessary.
My question is: how can I fetch this object only once and somehow
stuff it inside a
On Nov 12, 2008, at 12:14 PM, Steve Howe wrote:
Hello all,
I'm having trouble using SQLAlchemy 0.50.rc3 and like query
filters with the
psycopg2 adapter:
class Activity(Base):
__tablename__ = 'activities'
id = Column(Integer, primary_key=True, autoincrement=True)
name =
Hello Michael,
its not clear to me what is actually going wrong in that case. does
it work if you use a raw psycopg2 script ?
Yes it does, however I figured out the print statement from the other block
was just printing what would be sent to the adapter and not to the database -
that
try two percent signs to escape it - %%.
On May 14, 2008, at 10:50 AM, Artur Siekielski wrote:
Hi.
I want to execute ready SQL query using SA's engine:
engine.execute(r''' SELECT * FROM City WHERE name LIKE 'a%' ''')
I get this strange error:
It works :). Ah, I was sure I have tried it :).
Thanks for fast reply.
On 14 Maj, 18:42, Michael Bayer [EMAIL PROTECTED] wrote:
try two percent signs to escape it - %%.
--~--~-~--~~~---~--~~
You received this message because you are subscribed to the Google
Hi,
I have a question related to sql injection when using a clause like
this: User.c.username.like('%' + userinput + '%')
What restrictions do I have to put on the variable userinput? Of course,
I will ensure that is no percent character ('%') in userinput. Is that
enough (assuming that
On Jun 6, 12:37 am, Mike Orr [EMAIL PROTECTED] wrote:
On 6/5/07, Techniq [EMAIL PROTECTED] wrote:
I'm going through the wiki cookbook
http://docs.pythonweb.org/display/pylonscookbook/SQLAlchemy+for+peopl...
and I'm discovering that even though 'model.class.c.column_name.like'
is
On 6/5/07, Techniq [EMAIL PROTECTED] wrote:
I'm going through the wiki cookbook
http://docs.pythonweb.org/display/pylonscookbook/SQLAlchemy+for+people+in+a+hurry
and I'm discovering that even though 'model.class.c.column_name.like'
is available it doesn't perform a LIKE in the query.
from
39 matches
Mail list logo