save behavior events in SQLite database