Difference between revisions of "SQL Executer Plugin"

From TimeSnapper
Line 1: Line 1:
(NB: this plugin has not been released and is mostly intended for developers and very technically inclined people)
+
(NB: This plugin is mostly intended for developers and very technically inclined people)
  
 
The SQL Executer is a sample plugin that allows anyone to run SQL queries against TimeSnapper database.
 
The SQL Executer is a sample plugin that allows anyone to run SQL queries against TimeSnapper database.
  
 
[[Image:sql-executer-plugin.png]]
 
[[Image:sql-executer-plugin.png]]
 
  
 
The results can be copied from the results grid to e.g. Microsoft Excel for further processing.
 
The results can be copied from the results grid to e.g. Microsoft Excel for further processing.
Line 25: Line 24:
 
   select count(*) from activity where filename is not null
 
   select count(*) from activity where filename is not null
  
 +
 +
If you develop some interesting queries, be sure to send us a copy and we'll include them here for others to enjoy!
  
 
[[Category:Plugins]]
 
[[Category:Plugins]]

Revision as of 13:53, 16 September 2009

(NB: This plugin is mostly intended for developers and very technically inclined people)

The SQL Executer is a sample plugin that allows anyone to run SQL queries against TimeSnapper database.

Sql-executer-plugin.png

The results can be copied from the results grid to e.g. Microsoft Excel for further processing.

For a definition of TimeSnapper's database model - see Database Model

Sample Queries

List available TimeSnapper tables:

select rdb$relation_name
from rdb$relations
where rdb$view_blr is null 
and (rdb$system_flag is null or rdb$system_flag = 0)
order by 1

Count the number of screenshots that have been taken since TimeSnapper was first installed:

 select count(*) from activity

Count the number of screenshots that are still existing:

 select count(*) from activity where filename is not null


If you develop some interesting queries, be sure to send us a copy and we'll include them here for others to enjoy!