Reputation: 43
I am working on an application that will need to do some verification on data by checking fingerprints stored in a MySQL database.It was proposed to use proprietary software such as 'AFIS'..but i am wondering if the check can be done by using the BLOB column in the "where" clause of a select statement to filter the data. Is this possible?
The code i have in mind is something like this:
Select id from mytable
where image not in
(select image from other table)
With the image columns being of blob datatype
Upvotes: 4
Views: 2164
Reputation: 100195
Do you mean something like this:
SELECT * FROM yourTable WHERE CHAR_LENGTH(your_blob_field) > 0
char_length() works on a blob column type... if that is anything but 0 then you know you've got something in there.
Upvotes: 3