Back to the month index |
Back to the list index
|
rasmus@vex.net
Sat, 28 Sep 1996 22:35:01 -0400 (EDT)
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ]
- Next message: Andreas Koenig: "Re: [mSQL] mSQL-Perl Help"
- Previous message: Gary Bickford: "Re: [mSQL] 255+"
- Maybe in reply to: Tom T. Thai: "[mSQL] 255+"
- Next in thread: Andreas Koenig: "Re: [mSQL] add column to a table"
From: rasmus@vex.net Date: Sat, 28 Sep 1996 22:35:01 -0400 (EDT) Subject: Re: [mSQL] add column to a table Message-Id: <ML-2.3.843964501.8565.rasmus@krone.house.mil>> My attempt to add a column to an existing table yield severe
> bugs/errors.
>
> * Following the instructions in the FAQ, I dumped the schema and the
> content of the table, add a field to the schema, create the new table,
> modify the dumped data, and use the msql monitor to insert the data into
> the new table. All this works fine for tables with small number of
> records.
> However, this does NOT work for tables with number of records more than
> 20 - the msql monitor simply gets "chocked" and won't insert the records.
> What is the reason for this dismal performance of the monitor?
> Is there anywayt to force the poor monitor to handle more than 20 records
> at a time?
>
> * I wrote a PHP code that automates all the above process. again, the
> program would succeed with small tables, but when it runs on large
> tables I get "You have exceeded the maximum allowed data space of
> 8388608 bytes on line 471..." and the program aborts prematurely. Why?
> The total content of the table is 300KB, so it's far below the error's
> declared 8MB. Also, both my development PC and the sever have plenty of
> memory available. Did anyone confronted a simillar problem? Any feasible
> solutions?
A safeguard was put into PHP to limit the amount of dataspace a single
PHP process is allowed to eat up. PHP was not designed to manipulate large
files like that. You can however easily increase this limit. If you are
using the Apache module version, you can increase by putting a line like
this in your srm.conf file:
phpMaxDataSpace 16384
This would take it to 16 megs. The default is 8. Or bump it as high as
you want.
You might also want to have a look at where you are reading all this
data into and see if you can optimize your script a bit.
If you are using the CGI version of PHP, you can increase the data space
by editing php.h. You will find the following comment in that file:
/*
* DEFAULT_MAX_DATA_SPACE
*
* Set this to the maximum size a memory sub-pool is allowed to grow
* to. (number of kilo bytes)
*/
#define DEFAULT_MAX_DATA_SPACE 8192
>
> Does anyone have another suggestions how to add a column to a large
> table?
MsqlPerl or use the C API straight.
-Rasmus
--------------------------------------------------------------------------
To remove yourself from the Mini SQL mailing list send a message containing
"unsubscribe" to "unsubscribe" to msql-list-request@bunyip.com. Send a message containing
"info msql-list" to majordomo@bunyip.com for info on monthly archives of
the list. For more help, mail owner-msql-list@bunyip.com NOT the msql-list!
- Next message: Andreas Koenig: "Re: [mSQL] mSQL-Perl Help"
- Previous message: Gary Bickford: "Re: [mSQL] 255+"
- Maybe in reply to: Tom T. Thai: "[mSQL] 255+"
- Next in thread: Andreas Koenig: "Re: [mSQL] add column to a table"