Re: Working with recordsets
From: AdSR (adsr_at_poczta.onet.pl)
Date: 01/07/05
- Next message: Philippe C. Martin: "Tkinter: passing parameters to menu commands"
- Previous message: Philippe C. Martin: "Re: Developing Commercial Applications in Python"
- In reply to: chema.rey_at_gmail.com: "Working with recordsets"
- Next in thread: Steve Holden: "Re: Working with recordsets"
- Reply: Steve Holden: "Re: Working with recordsets"
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ]
Date: Fri, 07 Jan 2005 19:58:08 +0100
chema.rey@gmail.com wrote:
> Hi.
>
> I have one recorset that I would like to pass to 2 functions, one is
> for create an CSV file and the other one is to create a HTML file. The
> problem is that the recordset is totally read in the first function,
> and then when I pass it to the second funtion the recordset is in the
> last record.
>
> I've read docs, but I think that one cursor doesn't have something
> like movefirst() method. Anybody have an idea to solve this?
>
> Thank's.
>
Try loading the whole recordset with the fetchall() method and use the
resulting sequence in your functions. It won't be memory-efficient but
it will be easy to do.
AdSR
- Next message: Philippe C. Martin: "Tkinter: passing parameters to menu commands"
- Previous message: Philippe C. Martin: "Re: Developing Commercial Applications in Python"
- In reply to: chema.rey_at_gmail.com: "Working with recordsets"
- Next in thread: Steve Holden: "Re: Working with recordsets"
- Reply: Steve Holden: "Re: Working with recordsets"
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ]
Relevant Pages
|
|