I'd like to determine if an actual field value is a sequence of numbers (or letters if possible) or if all characters are the same. Working with Teradata Studio 15.0. I can convert the VARCHAR field to INTEGER to see if I can perform a mathematical operation to determine if it is a sequence or not but am not sure how to do this.
Are there any other kind of sequences than what you have listed? (fibonacci series, factors, all kinds of other thing).
If the answers is yes, I think it could be complicated (Type of number, int, smallint, bigint)?.
Can you please let me know your end goal?
I read somewhere "Finding numbers from a formula is a science. But finding a formula from numbers is an art."
I my view, SQL that address your question will be probably annoy your friend DBA (depending on size of the table).