Re: storing & searching docs

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On 12-12-2012 21:40, Maciek Sokolewicz wrote:
On 12-12-2012 21:03, Paul M Foster wrote:
Second, you've hit on one of my pet peeves. Never never store huge
blocks of text in SQL files. It slows them down and there's no real
reason for it. There's no reason to force a DBMS to schlep around
massive clumps of text or binary data. That's what disk file systems are
for. Store the target data in a file and store a reference to the
location of the data in the SQL database. Or perhaps, use a NoSQL
solution. I don't know much about the internals of nosql systems, but I
would hope that the metadata about the text objects would be stored
separately from the "payload" (text object).

Paul


I actually disagree on this point. In the past, storing data in a
database would make the entire database-system extremely slow and would
eat up memory. These days, most database-systems can be (or even are)
optimized to actually not do this anymore.

One positive aspect of storing such data in a database is the ability to
search using full-text searches. For example, you could use the Sphinx
Search Engine, which integrates into MySQL very well. It makes searching
for specific words, phrases, etc. very simple and VERY fast.

So in this case, storing it in a database WOULD actually be a good idea
IMO.

- Tul

Actually, I have to come back on that one. You could also store it locally in files, and feed it into the searchd daemon manually.


--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php



[Index of Archives]     [PHP Home]     [Apache Users]     [PHP on Windows]     [Kernel Newbies]     [PHP Install]     [PHP Classes]     [Pear]     [Postgresql]     [Postgresql PHP]     [PHP on Windows]     [PHP Database Programming]     [PHP SOAP]

  Powered by Linux