Search queries tracking

DataparkSearch supports query tracking.

When doing a search, front-end uses table qtrack to store query words, client IP address, a number of found documents and current UNIX timestamp in seconds and table qinfo to store all search parameters.

To enable tracking, add the trackquery parameter to DBAddr command (see the Section called DBAddr command in Chapter 3) in your search template.

Note: If you use searchd, you should add this parameter in your searchd.conf file.

Query tracking is useful to have a statistics of your search engine usage. To make a search queries summary, you may execute, for example, this SQL expression:


SELECT qwords,count(*),sum(found),avg(found) FROM qtrack GROUP BY qwords;