User-Defined string Functions Transact-SQL

  • Ladies and Gentlemen,

    I would like to offer you the following string functions Transact-SQL

    GETWORDCOUNT()  Counts the words in a string

    GETWORDNUM()    Returns a specified word from a string

    AT()   Returns the beginning numeric position of the first occurrence of a character expression within

           another character expression, counting from the leftmost character

    RAT() Returns the numeric position of the last (rightmost) occurrence of a character string within

          another character string

    OCCURS() Returns the number of times a character expression occurs within another character expression

    PADL()   Returns a string from an expression, padded with spaces or characters to a specified length on the left side

    PADR()   Returns a string from an expression, padded with spaces or characters to a specified length on the right side

    PADC()   Returns a string from an expression, padded with spaces or characters to a specified length on the both sides

    PROPER() Returns from a character expression a string capitalized as appropriate for proper names

    RCHARINDEX()  Is similar to a built-in function Transact-SQL charindex but the search of which is on the right

    ARABTOROMAN() Returns the character Roman number equivalent of a specified numeric expression

    ROMANTOARAB() Returns the number equivalent of a specified character Roman number expression  ...

    For more information about string UDFs Transact-SQL please visit the

    http://www.universalthread.com/wconnect/wc.dll?LevelExtreme~2,54,33,27115

    Please,  download the file

    http://www.universalthread.com/wconnect/wc.dll?LevelExtreme~2,2,27115

    With the best regards

  • This was removed by the editor as SPAM

  • Igor,

    Thanks. Would you like to post some of these in the script section?

  • Igor,

     

    I'm doing a lot of work with string manipulation at the moment, and the AT and RAT functions will be certainly useful to me!

     

    Cheers!

    Alex

  • Thanks for posting the functions, I found them very useful. Even the help is done very well.


    What I hear I forget, what I see I remember, what I do I understand

Viewing 5 posts - 1 through 4 (of 4 total)

You must be logged in to reply to this topic. Login to reply