mercredi 14 janvier 2015

Sqlite : Loop through rows and match, break when distinct row encountered

I want to compare two tables A and B, row by row on the basis of a column name.As soon as I encounter a distinct row I want to break.


I want to do this using a query, something like this :


select case when ( compare row 1 of A and B if same continue with row+1 else break ) if all same, then 1 else 0 end as result


I am not sure how to loop through rows and break? Is it even possible in sqlite?


Aucun commentaire:

Enregistrer un commentaire