On Wed, Dec 20, 2006 at 09:22:59AM +0100, Fredrik Lundh wrote:
> Andrew Sackville-West wrote:
>
> > I've also tried building tuples and lists and then using this
> >
> > cursor.execute("insert into daily values (%s)", values)
> >
> > with no luck. it appears to me that I have to put in all 132 '
On Wed, Dec 20, 2006 at 07:00:38AM -0800, Ant wrote:
>
>
> On Dec 20, 5:20 am, Andrew Sackville-West <[EMAIL PROTECTED]>
> wrote:
> > > >>> values = ", ".join([escapeAndQuote(f[:-2]) for f in fields])
>
> Obviously this is the appropriate choice since this is a database app.
> In general the str
On Dec 20, 5:20 am, Andrew Sackville-West <[EMAIL PROTECTED]>
wrote:
> > >>> values = ", ".join([escapeAndQuote(f[:-2]) for f in fields])
Obviously this is the appropriate choice since this is a database app.
In general the strip() group of string methods do what you want in a
safe way - assumin
Andrew Sackville-West wrote:
> I've also tried building tuples and lists and then using this
>
> cursor.execute("insert into daily values (%s)", values)
>
> with no luck. it appears to me that I have to put in all 132 '%s' in
> order to make that work and that just seems stupid.
on the other h
Andrew Sackville-West schrieb:
> I have an ascii data dump from a POS system that has 131 fields in a
> single column in a flat file. I can easily open the file, read in the
> data and assemble it into various formats. okay. what I *want* to do
> is insert each of these fields into a mysql databas
On Tue, Dec 19, 2006 at 07:34:58PM -0800, Todd Neal wrote:
> Andrew Sackville-West wrote:
> >
> > I can successfully connect to mysql and do stuff to my tables my
> > specific problem is how to efficiently put those 132 fields into the
> > thing. All I have been able to figure out is really ugly s
Andrew Sackville-West wrote:
>
> I can successfully connect to mysql and do stuff to my tables my
> specific problem is how to efficiently put those 132 fields into the
> thing. All I have been able to figure out is really ugly stuff like:
> build the mysql statement out of various pieces with appr
Hi list,
I've tried, lots of interpreter testing and google grepping to figure
this out and I think I'm missing something fundamental.
I have an ascii data dump from a POS system that has 131 fields in a
single column in a flat file. I can easily open the file, read in the
data and assemble it i