Results 1 to 2 of 2
  1. #1
    Join Date
    Aug 2004
    Posts
    1

    Unanswered: Generate Alphanumeric random numbers

    Hi,

    Can you please let me know a simple way to generate random alphanumeric random numbers

    Alternatively I found something as given below on net.. can anyone throw light on whether the following will work ?

    get a random numeric number... change the number into EBCDIC format ??

    what is the function to convert a normal numeral to a three digit EBCDIC format ?

    Response will be greatly appreciated.

    Regards

  2. #2
    Join Date
    Aug 2001
    Location
    UK
    Posts
    4,650
    with temp(a) as
    (
    values(1)
    union all
    select INT(RAND()*255) from temp where
    a not between 65 and 90
    and a not between 97 and 122
    and a not between 48 and 57
    )
    select chr(a) from temp where
    a between 65 and 90 -- A-Z A
    or a between 97 and 122 -- a-z

    or a between 48 and 57 -- 0 - 9
    ;

    HTH

    Sathyaram
    Visit the new-look IDUG Website , register to gain access to the excellent content.

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •