Hey Mike, any objection to me adding a 'rebind' method to BoundMetaData
which would allow a swap of the engine at runtime?
Rick
-
Take Surveys. Earn Cash. Influence the Future of IT
Join SourceForge.net's Techsay panel and yo
Is it possible to specify a DISTINCT option to select_by()? Couldn't find it
in the docs.
Rick
-
Take Surveys. Earn Cash. Influence the Future of IT
Join SourceForge.net's Techsay panel and you'll get the chance to share your
Hi List,Has anyone considered or investigated using the mapper as a tool to map classes to HTML forms as well as DB-API drivers? I'm working on a mapper that uses FormEncode for server-side validation and a set of custom-written _javascript_ validators on the client side. In writing the mappers and
wrote:
On 9/26/06, Rick Morrison <[EMAIL PROTECTED]
> wrote:
Hey Terrence,Howdy ho! regarding the Datetime type -- not sure I understand where the [23,3] came from -- can you give a testcase?
Well, I can give the you the CREATE TABLE for the table that caused it (below) and I can tell you why
Does the "Users" table use Foreign Keys? If so, the table reflector will attempt to auto-load those referenced tables recursively. That's not tested very well just yet in the MSSQL driver.Rick
On 9/26/06, Terrence Brannon <[EMAIL PROTECTED]
> wrote:
Hi, I'm getting an error when attempting to setup
Hey Terrence,the "uppercase" fix was already in, thanks.regarding the Datetime type -- not sure I understand where the [23,3] came from -- can you give a testcase?Thanks,Rick
On 9/26/06, Terrence Brannon <[EMAIL PROTECTED]> wrote:
Well, the patch below to v1898 for me. I can get things out of my da
SQL thats being sent over the wire,or can you just run str() on the statement objects ? it feels likethis is a special need that would be addressed by a proxyingExecutionContext or similar.
On Sep 25, 2006, at 12:11 PM, Rick Morrison wrote:> Anyone know if is there an easy way to echo individu
Anyone know if is there an easy way to echo individual statements in SA?I know it's possible to do: x = engine.echo engine.echo = True engine.echo = xBut it would be nice to have a statement option for simple interpreter-prompt debugging where you didn't have a ref to the engine handy.
Rick
--
Just committed changeset 1890:fixes bug 261 (table reflection broken for MS-SQL case-sensitive databases)can now specify port for pymssql introduces new "auto_identity_insert" option for auto-switching between "SET IDENTITY_INSERT" mode when values specified for IDENTITY columns
Rick
--
I think that psycopg2 will automatically use a Unix socket if a host address is omitted on the connection call. You'd need a way to have SA not supply that -- not sure how that would fit in with the dburi way of things. What's the big deal with using localhost anyway? I was under the impression tha
G' feature. Maybe someone with more time than me can take a look at this.
RickOn 9/11/06, Michael Bayer <[EMAIL PROTECTED]> wrote:
On Sep 10, 2006, at 9:55 PM, Rick Morrison wrote:> Oh, it gets even better. You can only have IDENTITY_INSERT on for> one table at a time. Trying to
e feature completely, it's conceivably useful.
On Sep 11, 2006, at 10:16 AM, Rick Morrison wrote:The column definition in MSSQL already allows the specification of an IDENTITY column by using the Sequence() class; see the MSSQL module header docstring for some details.
Getting rid of the auto
+1 on Celko's book; it's on my bookshelf too. Good treatment of trees and graphs.Here's an oldie but goodie that focuses on the practical aspects instead of theory:
http://www.worldcatlibraries.org/wcpa/top3mset/90a7cf72a514e231.htmlOut of print for sure, but I've seen it available used for a d
making that behavior switchable w/b better?
RickOn 9/11/06, Michael Bayer <[EMAIL PROTECTED]> wrote:
On Sep 10, 2006, at 9:55 PM, Rick Morrison wrote:> Oh, it gets even better. You can only have IDENTITY_INSERT on for> one table at a time. Trying to set it on for another table while i
On 9/10/06, Michael Bayer <[EMAIL PROTECTED]> wrote:
On Sep 10, 2006, at 7:03 PM, Rick Morrison wrote:> issue by simply disallowing multiple identity columns in a single> table. I thought that multiple identity columns in a single table> would be a pretty rare occurrence. Maybe I wa
Multiple identity columns in a single MSSQL table is confusing and problematic because of a feature in SA that allows the user to specify a value for insert into a table, or to simply omit or specify None/NULL for the value to trigger sequence/identity generation.
For databases like Postgres, this
ROTECTED]> wrote:
Rick Morrison wrote:> Just how viral is GPL in a circumstance like this? I was under the> impression that it is perfectly OK to use a GPL library in a commercial> product, as long as the source to the library itself was made available,
> along with any patches/modifications
Just how viral is GPL in a circumstance like this? I was under the impression that it is perfectly OK to use a GPL library in a commercial product, as long as the source to the library itself was made available, along with any patches/modifications to that library.
RickOn 9/9/06, Kent Johnson <[EMA
Sounds like it's adodbapi. That uses ADO/OLEDB underneath, which takes one of those "connection strings".More info here on connection string: http://www.connectionstrings.com/
look under SQL Server/OLEDB for the detailsRickOn 8/10/06, Michael Bayer <[EMAIL PROTECTED]
> wrote:what DBAPI are you us
+1 QOTWOn 8/9/06, Michael Bayer <[EMAIL PROTECTED]> wrote:
i for one welcome rabbits in my orderedproperties.anyway, patched in r1773, thanks.On Aug 9, 2006, at 2:10 PM, Kapil Thangavelu wrote: from sqlalchemy.util import OrderedProperties
>>> props = OrderedProperties()>>> 'rabbit' in props:>
Just tested with MS-SQL and Sqlite, both accept the syntax fine.FWIW, MS-SQL does the behind-the-scenes unique index create.On 7/13/06, William K. Volkman
<[EMAIL PROTECTED]> wrote:
Hi Michael,On Thu, 2006-07-13 at 14:54, Michael Bayer wrote:> hey list ->> im working on explicit CONSTRAINT objects
On 7/6/06, Chris Perkins <[EMAIL PROTECTED]> wrote:
Two questions:1) Are there differing levels of support for different databases?Specifically, should I expect mssql to work properly in 2.4? Iunderstand that the mssql module was contributed, but I don't know if
it has kept up with the API changes
Mike, if you've got some time, you may want to review the discussion regarding a TypePolicy scheme a few weeks ago (IIRC the thread was titled something about Decimal/Numeric). If you're digging into type conversion and don't mind a bit more work, this might be a good time to start some work on it.
List seems to have missed this one, forwarding, sorry if you've seen it before.-- Forwarded message --From: Rick Morrison <
[EMAIL PROTECTED]>Date: Jun 6, 2006 4:54 AMSubject: Re: [Sqlalchemy-users] decimal type support in sqlalchemyTo: "William K. Volkman" &
Just a few clarifying points on this:I don't see what overhead isn't being already spent -- the data type conversion has to take place anyway, especially for type-agnostic engines like SQlite. For type-rich databases like PG, if the DBAPI type is already correct, then no conversion is needed or per
can you expand on this? i intend to use pymssql / freetds for writingproduction applications, though i haven't used them before.
Us too, though we have used them before. FWIW, they have been working
problem-free for over 2 years, though in a low-volume environment.
is there no way to confidentl
y or so)On Jun 5, 2006, at 9:55 AM, Rick Morrison wrote:
Right,
this would be a global "type policy" object that the Dialects would
consult to determine the appropriate conversion to make. Right now
that's done by convention, this would make things more explicit and
allow global over
List seems to have missed this one, resending, sorry if you've seen it before-- Forwarded message --From: Rick Morrison <
[EMAIL PROTECTED]>Date: Jun 5, 2006 12:13 PMSubject: Re: [Sqlalchemy-users] decimal type support in sqlalchemyTo: Michael Bayer <[EMAIL PROTEC
e_engine(url, use_types = [Unicode, Decimal])On Jun 3, 2006, at 4:55 PM, Rick Morrison wrote:
Or maybe a different column type so that user can control what comes back. Course that wouldn't work with table reflection Rick On 6/3/06,
Michael Bayer <[EMAIL PROTECTED]> wrote:
for thi
reate_engine) ? users would have to know
which options go where, which might seem kind of arbitrary. also
i would worry MetaData is just going to become another Engine again and
have database behavior undesrieably bound to a schema description.On Jun 3, 2006, at 11:15 PM, Rick Morrison wrote:
I
o specifically
want a Decimal ? sounds like another flag-like situation like
"convert_unicode".On Jun 3, 2006, at 2:16 PM, Rick Morrison wrote:
On 6/3/06, Michael Bayer <[EMAIL PROTECTED]> wrote:
The Numeric types in SQLAlchemy dont modify the incoming or outgoingreturn type of
On 6/3/06, Michael Bayer <[EMAIL PROTECTED]> wrote:
The Numeric types in SQLAlchemy dont modify the incoming or outgoingreturn type of bind parameters at all.
Maybe they should. Letting the DBAPI driver "do what it wants" for type
conversion breaks the database independence that SA purports to
pr
Also on this subject, can anyone out there report on their experiences with mxODBC vs. Sql Server?
It would be nice to have a stable and well supported Unix-based mssql
DBAPI module for SA; I've always been a bit nervous about using FreeTDS
in a production environment.
Rick
_
Sounds like you have FreeTDS misconfigued. Port 4000 is the default port
for TDS version 5, which is used to connect to Sybase servers.
You can override that with an environment variable -- see http://www.freetds.org/userguide/envvar.htm
for the details.
There are also date translation issues whe
Last I heard, SA was requiring only Python 2.3, so in-library support for Decimal would be ruled out. RickOn 5/30/06, Yuan HOng <
[EMAIL PROTECTED]> wrote:I got the schema reflected from a PostgreSQL table, where some fields
are defined as numeric type. In sqlalchemy the column type is shown assqla
...on a holiday weekend, no less.Go, Mike, go!On 5/28/06, Michael Bayer <[EMAIL PROTECTED]
> wrote:Releasing 0.2.0 last night was so much fun, i just had to do itagain. Some threaded environments revealed a big blunder in the
connection pool where I forgot to restore a plain dictionary to itsprope
I noticed that too, Mike. It's a great selling feature of SA, and it's
one of the reasons (among many) that originally caught my eye about the
project.
Rick
On 5/23/06, Michael Bayer <[EMAIL PROTECTED]> wrote:
just saw this today and thought it was interestinga postgresinjection attack that *o
Thanks for your input, everybody.
Threads vs. Async is like Emacs vs. vi, and can go on forever. Let me try to put this back into the SA context a bit:
Is there some way to get a hybrid mix of threaded vs. multiprocess that would let a programmer control how a request is handled?
Serving stati
Hi all,
This is cross-posted from Pylons-discuss, where it's not getting much
attention. It's a bit off-topic, but does touch on SA + heavy threading.
Any feedback welcome
--
We've got a commercial project we're developing that currently uses
Twisted + SQLAlchemy th
I believe all of the database modules expect and return "native" Python datetime objects (which were added in Python 2.3).
Import and use "datetime" instead of "mx.DateTime". See the Python docs for usage.
Rick
On 5/12/06, Dimi Shahbaz <[EMAIL PROTECTED]> wrote:
Here is a test case that fails wi
Speaking of psycopg1, is there any good reason to continue support for that now that:
a) psycopg2 has been out of beta for some time? Federico has been pushing for people to upgrade.
b) SA requires Python 2.3, which has Std library datetime support
I was under the impression that psycopg2 is
Hey Gambit,Yeah, we'll need a way to alias the column created by the subquery. Have you tried using the "use_labels" switch on the inner query?RickOn 5/13/06,
Gambit <[EMAIL PROTECTED]> wrote:
Hey Rick,I was playing with this patch a bit and noticed that while it seems prettygood for select()'s, i
I've been through the internals a bit, and this direction sounds like the way to go, but I understand that there's going to be a bit of refactoring for 0.2. I'd want Mike in on this for an opinion, anyway. Copying him on this message -- what's up with the list for you guys? Seems to be working OK f
OK, this patch against trunk r#1455 works with your testcase.
It defines a new CalculatedClause() class similar to that of Function(), and refactors Function() to derive from this new class.
Also adds new visit_calculatedclause() function to handle the compile-time part.
It requires the use of l
Hey Mike:
Attached please find a patch against trunk r#1441 that implements the SQL CASE construct.
I know you've argued in the past for an implementation in some kind of
.ext-land, but let me at least present a few arguments for inclusion in
the core library. I'll do this in the form of response
(copying to the list)-- Forwarded message --From: Rick Morrison <[EMAIL PROTECTED]>
Date: May 8, 2006 2:08 PMSubject: Re: Re[2]: [Sqlalchemy-users] SQLAlchemy and py2exe InstructionsTo: Gambit <[EMAIL PROTECTED]>
Hey Gambit,
I'm using cx_Freeze, which I guess does
Also be aware that the database imports (that is both database-specific support within SA such as "mysql.py", "mssql.py" etc., as well as the DBAPI files used beneath the covers) are loaded dynamically by SA, and therefore won't be detected by the dependency checkers in py2exe and cxFreeze.
You'
Mike, do you want a patch, or is posted code enough?
RickOn 4/17/06, Rick Morrison <[EMAIL PROTECTED]> wrote:
I'm OK with this. SQL Server (at least V7 & 2K) has a rather
strange fractional second implementation that is only accurate to a few
hundred milliseconds, limiting its us
I'm OK with this. SQL Server (at least V7 & 2K) has a rather
strange fractional second implementation that is only accurate to a few
hundred milliseconds, limiting its usefulness anyway. It almost looks
like it's a vestige of the old INT 8 timer interrupt, which fired off
18.2 times/second or somet
t;, which is not really the case. SchemaItemWhatever
is just too long (SchemaItem is the base class for Table,Column,ForeignKey, etc.)Rick Morrison wrote:> I am -1 on Schema as well. >> It incorrectly implies that the contents are associated with a database
> schema, which is bad enough. But e
I am -1 on Schema as well.
It incorrectly implies that the contents are associated with a database
schema, which is bad enough. But even more confusingly, it's possible
for the thing to hold Tables and other database objects that really
*are* in a different database schema (i.e.have object.table_
I was using, so if it works for other cases
I didnt try (since I hardly tried any), great (can you produce a unit
test that fails with the previous version? not so crucial tho).
committed in rev 1254.- mikeOn Apr 3, 2006, at 5:12 PM, Rick Morrison wrote:
Didn't work for me, Mike -- didn
ince I hardly tried any), great (can you produce a unit test that
fails with the previous version? not so crucial tho). committed
in rev 1254.- mikeOn Apr 3, 2006, at 5:12 PM, Rick Morrison wrote:
Didn't work for me, Mike -- didn't generate FROM clauses at all for normal non-aliased, sa
.>>> Rick>>> On 3/31/06, Michael Bayer <
[EMAIL PROTECTED]> wrote:>>>>>> rick ->>>> this is terrific, I will try to commit this ASAP.>>>> Since I dont have an MS-SQL server to test here, can you show me an
>> example of what specia
lumn):
super(MSCompiler, self).visit_column(column) if column.table is not None and self.tablealiases.has_key(column.table): self.strings[column]=self.strings
[self.tablealiases[column.table]._get_col_by_original(column.original)] On Apr 1, 2006, at 9:24 AM, Rick Morrison wrote:
I'm not
I'm not sure I've got all of the cases covered, but at least one instance is this:SQL Server seems to need a table name to be aliased when it is referenced in a different schema, so SELECT otherschema.tablename.columnname
FROM otherschemaname.tablenamewon't work, and instead needs to be specified
The attached patch implements a Microsoft SQL Server engine for Sql Alchemy.
This module passes most unitests, but is still in a fairly early stage and should be considered for experimental use only.
Thanks to Runar Petursson for earlier work on this module.
Rick
Release notes
---
On 3/30/06, Michael Bayer <[EMAIL PROTECTED]> wrote:> so, better to use the version id
>option, which is very simple and easy to make efficient...the developer>just adds a proper index to the version ID column. works with BLOBs etcSTM that you don't even need an index on the version column, the up
That would be me. It's currently misbehaving on binary / unicode data
with pymssql, but I was considering posting it anyway for experimental
work, as I'm getting tired of resolving conflicts on each "svn up".
Mike, on my working copy I've currently setup SqlServer IDENTITY columns to use a new cla
Hi Michael,
Great project!
I want to use it, but ran into a showstopper situation with the lack of
support for a few datatypes.
So
Below please find a patch that:
-- Adds support for SMALLINT, DATE and TIME as follow:
DB SMALLINT DATE TIME NOTE
60 matches
Mail list logo