Jump to content

array limit?


ok

Recommended Posts

I've never thought about this as never had the need of very big arrays. However, what I can think that limits the array is the actual memory_limit (default should be 16M) configuration option. You can increase that in php.ini. Even though, I guess your application isn't designed well if it needs several MB of memory just for arrays. There are databases for this.

Link to comment
Share on other sites

Hi, have a look at the messages on the 15/8 as I asked the same question. So what I found was it is limited by memory, think PHP gets 128Mb as default, but can change in php.ini.

 

In my code I did some tests by calling memory_get_usage() and memory_get_peak_usage() during the code running (as debug type statements). Yes mem usage went up during array build outs (never over 2.5Mb though but this depends on array site - my array was about 2511 and 9 columns wide of about 40 chars).

 

Doing an unset of the array freed loads of memory so probably good to do that !

Link to comment
Share on other sites

This thread is more than a year old. Please don't revive it unless you have something important to add.

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Restore formatting

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.