Remove Numbers

I have a column within a table with date like 25C1, 26B1, 345SS4, 432BRP5, ect........

I need the remove the numbers both front & back and leave only the letters.

Like C, B, SS, BRP...........

The letters will be in a new column.....

Thanks


Answer this question

Remove Numbers

  • withersd

    If you're familiar with ODBC, you can call SQLColumns( ) on the table name, and then SQLFetch( ), SQLGetData( ) to get each column name in sequence. Then you can parse each column name character by character, skipping characters until you come to a non-numeric character, and append that character to your column's name.

    The problem with what you're trying to do is the risk of duplication. For example, 25C1, 3355C89, C12345, will all result in the same column name.

    Here's a link on MSDN to SQLColumns( ):

    http://msdn2.microsoft.com/en-us/library/ms131413.aspx


  • Remove Numbers