[sqlalchemy] Re: wx and SqlAlchemy

2008-08-29 Thread Werner F. Bruhin
Mike, Mike wrote: I found the issue. For some reason, SqlAlchemy is passing a unicode string to a varchar field in SQL Server, which is causing an error to be raised. If I explicitly set the value to an integer or a string, it works fine. I'm not sure how it's getting cast to unicode,

[sqlalchemy] Re: wx and SqlAlchemy

2008-08-29 Thread Mike
Werner, On Aug 29, 2:21 am, Werner F. Bruhin [EMAIL PROTECTED] wrote: Mike, Mike wrote: I found the issue. For some reason, SqlAlchemy is passing a unicode string to a varchar field in SQL Server, which is causing an error to be raised. If I explicitly set the value to an

[sqlalchemy] Re: wx and SqlAlchemy

2008-08-29 Thread Mike
Werner, On Aug 29, 2:21 am, Werner F. Bruhin [EMAIL PROTECTED] wrote: Mike, Mike wrote: I found the issue. For some reason, SqlAlchemy is passing a unicode string to a varchar field in SQL Server, which is causing an error to be raised. If I explicitly set the value to an

[sqlalchemy] Re: wx and SqlAlchemy

2008-08-28 Thread Werner F. Bruhin
Mike, Mike wrote: Hi, I am working on a wxPython application that saves data to various tables in our MS SQL Server 2000. I connect to one table and get data using a session. This works great. I then do a session.close() and then a conn.close() where conn = engine.connect(). This seems to

[sqlalchemy] Re: wx and SqlAlchemy

2008-08-28 Thread Werner F. Bruhin
Mike, Sent this a bit to quickly Mike wrote: Hi, I am working on a wxPython application that saves data to various tables in our MS SQL Server 2000. I connect to one table and get data using a session. This works great. I then do a session.close() and then a conn.close() where conn =

[sqlalchemy] Re: wx and SqlAlchemy

2008-08-28 Thread Mike
Hi Werner, On Aug 28, 1:39 am, Werner F. Bruhin [EMAIL PROTECTED] wrote: Mike, Sent this a bit to quickly Mike wrote: Hi, I am working on a wxPython application that saves data to various tables in our MS SQL Server 2000. I connect to one table and get data using a session. This

[sqlalchemy] Re: wx and SqlAlchemy

2008-08-28 Thread Cecil Westerhof
2008/8/28 Mike [EMAIL PROTECTED]: Does this work for multiple databases? This particular program I am working on will be connecting to 2 or 3 databases and a table or three in each of those. I'm pretty sure I have to create separate engines for each db and probably bind separate sessions for

[sqlalchemy] Re: wx and SqlAlchemy

2008-08-28 Thread Werner F. Bruhin
Mike, Mike wrote: ... Does this work for multiple databases? This particular program I am working on will be connecting to 2 or 3 databases and a table or three in each of those. I'm pretty sure I have to create separate engines for each db and probably bind separate sessions for those.

[sqlalchemy] Re: wx and SqlAlchemy

2008-08-28 Thread Mike
Hi, Here's what I'm doing. I have a timesheet application written in wxPython. It works, but I think it would work better if I changed the database calls into SA calls. There are 3 databases. I created one and the other two are pre-existing. The one I created is the one I store all the user

[sqlalchemy] Re: wx and SqlAlchemy

2008-08-28 Thread Werner F. Bruhin
Mike, Mike wrote: Hi, Here's what I'm doing. I have a timesheet application written in wxPython. It works, but I think it would work better if I changed the database calls into SA calls. There are 3 databases. I created one and the other two are pre-existing. The one I created is the one I

[sqlalchemy] Re: wx and SqlAlchemy

2008-08-28 Thread Mike
Werner, On Aug 28, 11:24 am, Werner F. Bruhin [EMAIL PROTECTED] wrote: Mike, Mike wrote: Hi, Here's what I'm doing. I have a timesheet application written in wxPython. It works, but I think it would work better if I changed the database calls into SA calls. There are 3 databases. I