SQLite3 database support

Description of Patch

Title is self explanatory, please test and report bugs.

Installation of Patch

Download the patch file.

patch -p0 < sqlite3.patch

Then re-build Motion and test the patch.

Change History of Patch

  • 0.1 Initial revision
  • 0.2 Improved configure.in detection of sqlite3 , make it work with svn -r433.

Discussion and Comments

I did some test and works ok.

1-. Create a sqlite3 database :
sqlite3 /tmp/database.db
CREATE TABLE security (camera int, filename char(80) not null, frame int, file_type int,time_stamp timestamp(14), event_time_stamp timestamp(14)); 
.exit

2-. Setup motion.conf
sql_log_picture on sql_log_movie on sql_query insert into security(camera, filename, frame, file_type, time_stamp, event_time_stamp) values('%t', '%f', '%q', '%n', '%Y-%m-%d   %T', '%C') database_type sqlite3 sqlite3_db /tmp/database


Committed to Svn -r434

-- AngelCarpintero - 25 Oct 2008


Can you please add this patch to the download file, motion-3.2.11.1.tar? I am trying to use motion with sqlite3 on openwrt build. Thanks in advance.

-- YaadGiri - 21 Feb 2010


This patch it's already in trunk , so you can get from snapshots http://www.lavrsen.dk/sources/motion-daily//motion-daily-last.tar.gz

-- AngelCarpintero - 22 Feb 2010
Topic revision: r5 - 22 Feb 2010 - 02:20:17 - AngelCarpintero
 
Motion - SQLite 3 Patch
Copyright © 1999-2012 by the contributing authors. All material on this collaboration platform is the property of the contributing authors.
Please do not email Kenneth for support questions (read why). Use the Support Requests page or join the Mailing List.