Hi,
Just wondering if there is an easy way to determine what tables are
joined in a query?
I'm doing something like this
query = session.query(System, dynamic_obj).select_from(self.j)
Where dynamic_obj could be any mapped object and self.j represents a
join produced by the
On Mon, Oct 26, 2009 at 10:09 PM, Bobby Impollonia bob...@gmail.com wrote:
You can also create a view mapped to that union and use that as a
virtual table so that you don't have to repeat the union specification
for every query:
http://www.w3schools.com/Sql/sql_view.asp
I don't know if
Only a couple of months late, but here is the final working recipe:
class A(Base):
__tablename__ = 'tbl_a'
id = Column(Integer, primary_key=True)
data = Column(String)
class B(Base):
__tablename__ = 'tbl_b'
id = Column(Integer, primary_key=True)
data = Column(String)
Hello Guys,
I've got a query which I'm currently running as literal SQL against a
MySQL database. I'm looking to create a ported version of the query
for SQLite but am totally new to that platform so am looking for a
little help with my date/time functions, I'm hoping someone here will
have a
Sir Rawlins wrote:
Hello Guys,
I've got a query which I'm currently running as literal SQL against a
MySQL database. I'm looking to create a ported version of the query
for SQLite but am totally new to that platform so am looking for a
little help with my date/time functions, I'm hoping
Hi all,
I am having a problem getting database creation on PostgreSQL done
correctly in an API that I am writing. I am using a svn checkout of SA trunk
from yesterday if that is important.
I have use the following code to create the database:
--- snip ---
...
try:
import psycopg2.extensions
Wolodja Wentland wrote:
def create(self):
Create this database
# set isolation level to AUTOCOMMIT
# postgres can't CREATE databases within a transaction
self._admin_engine.connect().connection.connection.set_isolation_level(
ISOLATION_LEVEL_AUTOCOMMIT)
On Tue, Oct 27, 2009 at 16:22 -0400, Michael Bayer wrote:
Wolodja Wentland wrote:
def create(self):
Create this database
# set isolation level to AUTOCOMMIT
# postgres can't CREATE databases within a transaction
Wolodja Wentland wrote:
On Tue, Oct 27, 2009 at 16:22 -0400, Michael Bayer wrote:
Wolodja Wentland wrote:
def create(self):
Create this database
# set isolation level to AUTOCOMMIT
# postgres can't CREATE databases within a transaction
Hi everyone,
how do I use two clauses in an outerjoin?
e.g.: select ... from t1 outer join t2 on (t1.c1=t2.c1 and
t1.c2t2.c2)
According to docs, outerjoin is
outerjoin(left, right, onclause=None)
so I don't really know where to place the second clause.
In a query object, outerjoin is
You wrap your two conditions with and_() as your onclause.
Mariano Mara wrote:
Hi everyone,
how do I use two clauses in an outerjoin?
e.g.: select ... from t1 outer join t2 on (t1.c1=t2.c1 and
t1.c2t2.c2)
According to docs, outerjoin is
outerjoin(left, right, onclause=None)
so I
Greetings!
I've known about sqlalchemy for a long time and have been interested in
using it professionally for a while now. I finally have the chance to use it
and have really been enjoying it. But it turns out that I am a little
confused about the best way to handle m2m relationships that have
On Sat, 24 Oct 2009 04:02:04 -0700 (PDT)
sector119 sector...@gmail.com wrote:
Hi All.
I've got UnicodeDecodeError: 'ascii' codec can't decode byte 0xa1 in
position 3: ordinal not in range(128)
Why it can happen? I use client_encoding=utf8 at postgresql.conf and
encoding=utf-8 at
13 matches
Mail list logo