# SQlite row size

- Thread: https://externals.io/message/17328
- Original archive: https://news-web.php.net/php.internals/17328
- Started by Andreas Ahlenstorf on 2005-07-19T20:13:19+00:00
- Messages: 3
- Reply by email to internals@lists.php.net
- More for agents: search with https://externals.io/search.md?q={query} · JSON API at https://externals.io/api · documentation at https://externals.io/llms.txt

---

## #17328 — Andreas Ahlenstorf — 2005-07-19T20:13:19+00:00

URL: https://externals.io/message/17328#17328

Hi,

I'm playing around with SQlite in PHP 5 and as far as I can see, the  
row size is limited to 1 MB, even it's possible to set it up to 16  
MB. What's the reason for it? I know I can change it for myself when  
I recompile the extension, but that's quiet hard on Windows without a  
compiler and without the required knowledge...

Andreas

---

## #17329 — Wez Furlong — 2005-07-19T20:23:10+00:00

URL: https://externals.io/message/17328#17329 · In reply to: #17328

Just because it is the library default; the intention is to make php
generate sqlite files compatible with other applications that use
sqlite.

IIRC, you can happily exceed this "limit", it'll just be slower to
access such a row.

To be honest, support for blob style data in sqlite 2 and below is
pretty crappy; if you're serious about it, I'd suggest upgrading to
PHP 5.1 and using PDO SQLITE instead.  SQLite 3 (which it uses)
actually has a concept of binary data.

--Wez.


> Hi,
> 
> I'm playing around with SQlite in PHP 5 and as far as I can see, the
> row size is limited to 1 MB, even it's possible to set it up to 16
> MB. What's the reason for it? I know I can change it for myself when
> I recompile the extension, but that's quiet hard on Windows without a
> compiler and without the required knowledge...
> 
> Andreas

---

## #17330 — Andreas Ahlenstorf — 2005-07-19T21:02:16+00:00

URL: https://externals.io/message/17328#17330 · In reply to: #17329

Am 19.07.2005 um 22:23 schrieb Wez Furlong:

> Just because it is the library default; the intention is to make php
> generate sqlite files compatible with other applications that use
> sqlite.

Ah, that makes sense :)

> To be honest, support for blob style data in sqlite 2 and below is
> pretty crappy; if you're serious about it, I'd suggest upgrading to
> PHP 5.1 and using PDO SQLITE instead.  SQLite 3 (which it uses)
> actually has a concept of binary data.

I'll think about it - does the row size limit still exist in SQLite 3?

Andreas
