Newbie to client/server

Larry Bates lbates at swamisoft.com
Thu Apr 22 10:24:57 EDT 2004


Use SQL "joins" to create a single "logical" record from
as many different tables as you want resulting in a single
result record that contains all the fields on your form.
If there is a one-many relationship between tables, you
will loop over all the result records.

That way you only need a single cursor.

FYI,
Larry Bates
Syscon, Inc.

"John Fabiani" <jfabiani at yolo.com> wrote in message
news:p6Qhc.39822$on5.30998 at newssvr29.news.prodigy.com...
> I don't understand how to get data from multi tables for my forms/windows.
> I have been reading how to connect and get data (using a SQL statement)
> from MySQL.  I think I understand.
> Now the question if I have a form (i.e. AR invoice) that requires data
from
> more than one table (or I need multi SQL statements) where do I put it.
It
> appears that I can have only one cursor.  This must be wrong. I can
> understand that I can reuse the connect object but the returning
> information ends up into the same cursor.  I don't want code (just how to
> do it right) but when I do something like the following it does not work:
> Con=myconnection_string
> Cursor=con.cursor()
> Cursor.execute(somestatement)
> newCursor=con.cursor()
> newCursor.execute(somestatement)  #does not work
> John
> -- 
> John Fabiani





More information about the Python-list mailing list