Unlimited Usenet
day retention, 99% Completion, Unlimited Access, Free Trial!

Pure Php Flat-File Databases?

This is a discussion on Pure Php Flat-File Databases? within the PHP Language forums, part of the PHP Programming Forums category; I've writing my own flat file database.. well table-based pure php code, PhpSimpleDb but I was looking into ...


Go Back   Usenet Forums > PHP Programming Forums > PHP Language

FAQ Members List Calendar Search Today's Posts Mark Forums Read
  #1 (permalink)  
Old 06-04-2008
Gorilla3D
 
Posts: n/a
Default Pure Php Flat-File Databases?

I've writing my own flat file database.. well table-based pure php
code, PhpSimpleDb but I was looking into some bench marking so was
wonder if anyone knew any other flat-file php db's out there.

Gladius DB
txtSQL

ps. http://code.google.com/p/phpsimpledb/ is what I have working right
now.
Reply With Quote
  #2 (permalink)  
Old 06-04-2008
Rik Wasmus
 
Posts: n/a
Default Re: Pure Php Flat-File Databases?

On Wed, 04 Jun 2008 02:00:35 +0200, Gorilla3D <sutabi@gmail.com> wrote:

> I've writing my own flat file database.. well table-based pure php
> code, PhpSimpleDb but I was looking into some bench marking so was
> wonder if anyone knew any other flat-file php db's out there.
>
> Gladius DB
> txtSQL
>
> ps. http://code.google.com/p/phpsimpledb/ is what I have working right
> now.


Any reason to compete with SQLite? I found that is was enabled on most
servers...
--
Rik Wasmus
....spamrun finished
Reply With Quote
  #3 (permalink)  
Old 06-04-2008
Gorilla3D
 
Posts: n/a
Default Re: Pure Php Flat-File Databases?

Well, SQLite uses SQL, I was just looking to to use pure php to query
rather then SQL. Which is why I considered writing my own. I am in no
way trying to compete with SQLite in the sense of a full fledge
database, just something simple for php using php.

Sample MySQL
$link = mysql_connect('localhost', 'username', 'password');
$table = mysql_select_db('sampledb');
$query = mysql_query('SELECT * t1 WHERE c LIKE "%thousand%"');
$entry = mysql_fetch_assoc($query);

Sample SimpleDb
$t = new t1('data');
$rows = $t->filter('stristr(c, "thousand")')->query();
$idx = array_shift($rows);
$entry = $t->fetch($idx);

On Jun 3, 5:01 pm, "Rik Wasmus" <luiheidsgoe...@hotmail.com> wrote:
> On Wed, 04 Jun 2008 02:00:35 +0200, Gorilla3D <sut...@gmail.com> wrote:
> > I've writing my own flat file database.. well table-based pure php
> > code, PhpSimpleDb but I was looking into some bench marking so was
> > wonder if anyone knew any other flat-file php db's out there.

>
> > Gladius DB
> > txtSQL

>
> > ps.http://code.google.com/p/phpsimpledb/is what I have working right
> > now.

>
> Any reason to compete with SQLite? I found that is was enabled on most
> servers...
> --
> Rik Wasmus
> ...spamrun finished


Reply With Quote
  #4 (permalink)  
Old 06-04-2008
Jerry Stuckle
 
Posts: n/a
Default Re: Pure Php Flat-File Databases?

Gorilla3D wrote:
> Well, SQLite uses SQL, I was just looking to to use pure php to query
> rather then SQL. Which is why I considered writing my own. I am in no
> way trying to compete with SQLite in the sense of a full fledge
> database, just something simple for php using php.
>
> Sample MySQL
> $link = mysql_connect('localhost', 'username', 'password');
> $table = mysql_select_db('sampledb');
> $query = mysql_query('SELECT * t1 WHERE c LIKE "%thousand%"');
> $entry = mysql_fetch_assoc($query);
>
> Sample SimpleDb
> $t = new t1('data');
> $rows = $t->filter('stristr(c, "thousand")')->query();
> $idx = array_shift($rows);
> $entry = $t->fetch($idx);
>
> On Jun 3, 5:01 pm, "Rik Wasmus" <luiheidsgoe...@hotmail.com> wrote:
>> On Wed, 04 Jun 2008 02:00:35 +0200, Gorilla3D <sut...@gmail.com> wrote:
>>> I've writing my own flat file database.. well table-based pure php
>>> code, PhpSimpleDb but I was looking into some bench marking so was
>>> wonder if anyone knew any other flat-file php db's out there.
>>> Gladius DB
>>> txtSQL
>>> ps.http://code.google.com/p/phpsimpledb/is what I have working right
>>> now.

>> Any reason to compete with SQLite? I found that is was enabled on most
>> servers...
>> --
>> Rik Wasmus
>> ...spamrun finished

>


I think you'll find SQLLite or MySQL will outperform anything you write
in PHP, unless it's for very small files.

--
==================
Remove the "x" from my email address
Jerry Stuckle
JDS Computer Training Corp.
jstucklex@attglobal.net
==================
Reply With Quote
  #5 (permalink)  
Old 06-04-2008
Erwin Moller
 
Posts: n/a
Default Re: Pure Php Flat-File Databases?

Gorilla3D schreef:
> I've writing my own flat file database.. well table-based pure php
> code, PhpSimpleDb but I was looking into some bench marking so was
> wonder if anyone knew any other flat-file php db's out there.
>
> Gladius DB
> txtSQL
>
> ps. http://code.google.com/p/phpsimpledb/ is what I have working right
> now.


Hi,

I used a few in the past, with different results.
In these days almost every server running PHP also runs at least mySQL,
or if you are really lucky: Postgresql.

Here is a link to a reasonably wellknown flatfile engine: ffdb (flat
file db):
http://sourceforge.net/projects/ffdb-php/

You can use that one for benchmarking.

I don't want to be negative, but the flatfile approach is needed less
and less. So unless you are doing this for pure fun, I don't expect many
will need it.

Good luck!

Regards,
Erwin Moller

PS: I wanted to give you more links, but in all honesty, I plainly
forgot the names of the other flat file SQL engines I used. :-)
I know there a few more out there.
Reply With Quote
  #6 (permalink)  
Old 06-04-2008
Baris-C
 
Posts: n/a
Default Re: Pure Php Flat-File Databases?

On Jun 4, 3:00*am, Gorilla3D <sut...@gmail.com> wrote:
> I've writing my own flat file database.. well table-based pure php
> code, PhpSimpleDb but I was looking into some bench marking so was
> wonder if anyone knew any other flat-file php db's out there.
>
> Gladius DB
> txtSQL
>
> ps.http://code.google.com/p/phpsimpledb/is what I have working right
> now.


By the way i use SQLite on my usb-sticks, where i store my sites as
portable back-ups, run hp from stick from my customized apache-lite,
its really handy.. I use to used flat files but, i think SQLite is the
best.
Reply With Quote
Reply
Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are Off
[IMG] code is Off
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On




All times are GMT +1. The time now is 08:28 AM.


Powered by vBulletin® Version 3.7.3
Copyright ©2000 - 2010, Jelsoft Enterprises Ltd.
Content Relevant URLs by vBSEO 3.0.0