SQLite Forum

Operation speed
Login
Hello everyone,

I am working on an embedded equipment in Linux C++.

It takes about 4.5 seconds to execute the SQL statement below.
 
DELETE FROM points_11 WHERE uint64_ID NOT IN (SELECT uint64_pointIDX FROM values_11);

There are 1440 records in table points_11, 46049 records in table values_11.
The structure of these 2 talbes is as below.

Is this normal?
Which aspects I cloud check to speed up please? 

Thanks a lot.


points_11
	|_ uint64_ID				INTEGER PRIMARY KEY
	|_ uint_UTC				INTEGER
	|_ uint_OSC				INTEGER
	|_ uint_storeUTC			INTEGER
	|_ uint_storeOSC			INTEGER
	|_ text_timesource			TEXT
	|_ text_status				INTEGER
	|_ uint_job				INTEGER
	|_ blob_raw				BLOB

values_11
	|_ uint64_ID				INTEGER PRIMARY KEY
	|_ uint64_pointIDX			INTEGER
	|_ text_name				TEXT
	|_ text_value				TEXT
	|_ text_unit				TEXT
	|_ uint_UTC				INTEGER
	|_ text_timesource			TEXT
	|_ blob_signature			BLOG
	|_ uint64_obisId			INTEGER
	|_ uint_regValue			INTEGER
	|_ uint_regFormat			INTEGER