You are here: Re: Where to store pictures, in DB or in files? « PHP Programming Language « IT news, forums, messages
Re: Where to store pictures, in DB or in files?

Posted by David T. Ashley on 07/08/06 03:52

"Richard Levasseur" <richardlev@gmail.com> wrote in message
news:1152322021.658752.74530@b28g2000cwb.googlegroups.com...
> Another option would be to name the file after the primary key, or
> other unique index, of the table.

The reason for the prime moduli directory scheme is that Unix directory
operations become inefficient beyond a few hundred entries in a directory.

The prime moduli scheme is designed to avoid this by filling up the
lowest-level directories evenly.

It isn't clear that naming the file after the primary key would have the
same advantage.

The example I gave was with three primes. In practice, one should use
primes not larger than 200 and enough of them so that their product exceeds
2^32.

 

Navigation:

[Reply to this message]


Удаленная работа для программистов  •  Как заработать на Google AdSense  •  England, UK  •  статьи на английском  •  PHP MySQL CMS Apache Oscommerce  •  Online Business Knowledge Base  •  DVD MP3 AVI MP4 players codecs conversion help
Home  •  Search  •  Site Map  •  Set as Homepage  •  Add to Favourites

Copyright © 2005-2006 Powered by Custom PHP Programming

Сайт изготовлен в Студии Валентина Петручека
изготовление и поддержка веб-сайтов, разработка программного обеспечения, поисковая оптимизация