vendredi 26 février 2016

sql lite regexp - why returns values in digits instead of actual value

I am having this issue. in col1 there are values abc, def, ghi,

when I use regexp

select from col1, col1 regexp '[a-z]' as result from table_name

I receive returning values with 0 or 1. I understand regexp is explaning me that with 0 there is no [a-z] chars within string and with 1 there are, but I am looking for a solution, where regexp would return me how many of chars are within particular cell, but not in option 3 for abc, but 111.

so for an example:

abc = 111

is this possible?

Thanks.

Aucun commentaire:

Enregistrer un commentaire