Re: Solved - Python: automate input to MySQL query

2009-09-24 Thread D'Arcy J.M. Cain
On Thu, 24 Sep 2009 15:03:26 +0200 Tino Wildenhain wrote: > > In any case, I have a strong philosophical objection to using the same > > name to refer to two different things regardless of any operational > > issues. The manager.firstname and employee.firstname are not the same > > thing and shou

Re: Solved - Python: automate input to MySQL query

2009-09-24 Thread D'Arcy J.M. Cain
On Thu, 24 Sep 2009 08:49:02 -0400 Joe Riopel wrote: > On Wed, Sep 23, 2009 at 4:21 PM, D'Arcy J.M. Cain wrote: > > In any case, I have a strong philosophical objection to using the same > > name to refer to two different things regardless of any operational > > issues.  The manager.firstname and

Re: Solved - Python: automate input to MySQL query

2009-09-24 Thread Tino Wildenhain
Hi, ... code, even that is not needed, as the columns are returned in the order specified so code /knows/ that the first column is from /this/ table and the other column with is from /that/ table). Unless you get a dictionary return. In any case, I have a strong philosophical objection to

Re: Solved - Python: automate input to MySQL query

2009-09-24 Thread Joe Riopel
On Wed, Sep 23, 2009 at 4:21 PM, D'Arcy J.M. Cain wrote: > In any case, I have a strong philosophical objection to using the same > name to refer to two different things regardless of any operational > issues.  The manager.firstname and employee.firstname are not the same > thing and should have d

Re: Solved - Python: automate input to MySQL query

2009-09-23 Thread D'Arcy J.M. Cain
On Wed, 23 Sep 2009 11:37:07 -0700 Dennis Lee Bieber wrote: > On Wed, 23 Sep 2009 10:49:51 -0400, "D'Arcy J.M. Cain" > declaimed the following in gmane.comp.python.general: > > from pg import DB # PyGreSQL > > db = DB() # uses my default PostgeSQL database > > res = db.query(""" > > SELECT *

Re: Solved - Python: automate input to MySQL query

2009-09-23 Thread Joe Riopel
On Wed, Sep 23, 2009 at 10:49 AM, D'Arcy J.M. Cain wrote: > Of course you can get around this by specifying every field and using > "AS" to change the names to manager_id and employee_firstname, etc. but > if you are going to do that anyway, why not just do it once in the > database instead of lit

Re: Solved - Python: automate input to MySQL query

2009-09-23 Thread D'Arcy J.M. Cain
On Tue, 22 Sep 2009 22:36:15 -0700 Dennis Lee Bieber wrote: > I wasn't really referring to the table used as a qualifier (in front > of the "."). But in your sample statement, every /field/ name seemed to > contain the table name too... > > traveler.travelerFirstName > > rather than

Solved - Python: automate input to MySQL query

2009-09-22 Thread Threader Slash
-- Forwarded message -- From: Dennis Lee Bieber To: python-list@python.org Date: Tue, 22 Sep 2009 10:43:52 -0700 Subject: Re: Solved - Python: automate input to MySQL query On Tue, 22 Sep 2009 15:58:18 +1000, Threader Slash declaimed the following in gmane.comp.python.general: > >

Solved - Python: automate input to MySQL query

2009-09-21 Thread Threader Slash
-- Forwarded message -- > From: Philip Semanchuk > To: "Python-list (General)" > Date: Mon, 21 Sep 2009 08:49:27 -0400 > Subject: Re: Python: automate input to MySQL query > > On Sep 21, 2009, at 5:18 AM, Threader Slash wrote: > > Hi Everybody... >> >> I have a query that works a