2013-09-13 11:52:07 UTC
create table mytable(
where productcode like '12345a'
Is it possible to include slight variations of that productcode so that it returns any other record where the value differs by one character?
Example, can I get it to also return productcode = 19345a or 12335a?
4321,really good cleaner,19345a
I don't care what the postion of the differing values are, so 12375a, 42345a, 12342a, 123455, 11345a, etc would all be acceptable.
I want all records "where productcode like '12345a'"
productcode will always have a length of 6 characters (i.e. '12345a7' or '123456a' is not valid).
I suppose I'm looking for something like a regexp for sql. Can this be done?