Hello,
I have relation User-User2Group-Group with additional attribute System on
User2Group table.
The System is part of primary key, which means
*'user can me member of group via multiple systems'.*
class User(Base):
__tablename__ = 'User'
name = Column('Name', Unicode(256),
Hi,
Adding viewonly=True on User.groups relationship solved the issue.
cheers!
Dne čtvrtek 5. března 2015 11:26:58 UTC+1 Pavel S napsal(a):
Hello,
I have relation User-User2Group-Group with additional attribute System on
User2Group table.
The System is part of primary key, which means
-association-objects
Hope that helps,
Simon
On Thu, Mar 5, 2015 at 10:43 AM, Pavel S pa...@schon.cz javascript:
wrote:
Hi,
Adding viewonly=True on User.groups relationship solved the issue.
cheers!
Dne čtvrtek 5. března 2015 11:26:58 UTC+1 Pavel S napsal(a):
Hello
, the UserKeyword's user property is not set explicitly,
but because of the backref on User.user_keywords, appending to the
list will cause the user property to be assigned.
Simon
On Thu, Mar 5, 2015 at 11:46 AM, Pavel S pa...@schon.cz javascript:
wrote:
Hi,
I just noticed
metadata, so
sqlalchemy can write the right sql for you. also, your query should be a
*select()* object, like your example.
this worked for me for some time, using SA 0.9, i don't know about 1.0,
but it should work too.
cheers,
richard.
On 04/22/2015 04:26 AM, Pavel S wrote:
Hello
time, using SA 0.9, i don't know about 1.0,
but it should work too.
cheers,
richard.
On 04/22/2015 04:26 AM, Pavel S wrote:
Hello,
I have pythonic application which imports custom module written in C++
using boost::python.
The module creates database connection(s) and executes
Hi,
it happened to me many times during development, mainly when used custom
column types, that I passed wrong type of value to the query.
Then the the following warning was emitted:
SAWarning: Unicode type received non-unicode bindparam value
The problem with such warning is it does not say
Hello,
I have pythonic application which imports custom module written in C++
using boost::python.
The module creates database connection(s) and executes queries.
The python calls various methods on that module and passes plain SQL into
them. Results are then returned to python.
I would like
,
you dan do:
import warnings
warnings.simplefilter('error')
This will raise an exception. and give you a stacktrace on where the
Unicode warnign happened.
On 04/22/2015 09:48 AM, Pavel S wrote:
Hi,
it happened to me many times during development, mainly when used custom
You should refer documentation of your RDBMS.
'*func*' is just proxy to any function defined inside RDBMS.
If your RDBMS has function *bla* (e.g. CREATE FUNCTION bla...), then you
can call if from python using *func.bla()*.
Dne neděle 2. srpna 2015 19:12:04 UTC+2 c.b...@posteo.jp napsal(a):
Hi,
I have declarative Model with couple of columns, one of them is
lastAccess = Column('LastAccess', DateTime, nullable=False,
onupdate=datetime.datetime.utcnow)
I fetch the object from database like the following:
obj = ScopedSession.query(Model).get(something)
Later in code I commit the
Hi Michael, this is amazing, thanks!!!
On Thursday, September 10, 2015 at 3:35:39 PM UTC+2, Michael Bayer wrote:
>
>
>
> On 9/10/15 8:48 AM, Pavel S wrote:
>
> Let's say, I have declarative classes A, B, C, D.
>
> A is the parent
> B has FK to A
> C has FK to B,
Let's say, I have declarative classes A, B, C, D.
A is the parent
B has FK to A
C has FK to B,
D has FK to C etc...
I'd like to implement *generic method* walk(obj) which will recursively
yield dependent/related objects of obj (which is instance of A).
I know that there is introspection
elif related is not None:
for walk_related in walk(related, level + 1, memo):
yield walk_related
On Thursday, September 10, 2015 at 3:48:55 PM UTC+2, Michael Bayer wrote:
>
>
>
> On 9/10/15 9:35 AM, Mike Bayer wrote:
>
>
>
> On
pondělí 14. září 2015 11:57:05 UTC+2 Pavel S napsal(a):
>
> Hi,
>
> I just realized that I need your first solution, since I need to get only
> those objects that would cascade in case of deletion.
>
> But thanks anyhow...
>
> P
>
> Dne čtvrtek 10. září 2015 15
Hi,
I just realized that I need your first solution, since I need to get only
those objects that would cascade in case of deletion.
But thanks anyhow...
P
Dne čtvrtek 10. září 2015 15:35:39 UTC+2 Michael Bayer napsal(a):
>
>
>
> On 9/10/15 8:48 AM, Pavel S wrote:
>
>
Hi,
we use application-level partitioning (but no real partitioning in mysqld),
where new tables are created daily with the same structure, but different
name (suffix).
- mysqld is shared for these components:
- daemon written in C++
- creates new tables every day and fills
Hi,
I maintain extremely complex application (>100k LOC) which uses SQLAlchemy.
Often in the log I find errors like:
sqlalchemy/engine/default.py:450: Warning: Truncated incorrect DOUBLE
value: 'Foo'
or
sqlalchemy/sql/sqltypes.py:201: SAWarning: Unicode type received
non-unicode bind param
18 matches
Mail list logo