#1
  1. No Profile Picture
    Contributing User
    Devshed Newbie (0 - 499 posts)

    Join Date
    Aug 2011
    Posts
    139
    Rep Power
    4

    Pulling out numerical portions


    Hi, i've seen where you can separate the numerical portion of a string from the other parts, but can't remember the syntax. i have some data like:

    ABCD1234
    FS9057
    AGSVGA34

    what is the syntax to pull out only the numerical values?

    thank you!
  2. #2
  3. No Profile Picture
    Registered User
    Devshed Newbie (0 - 499 posts)

    Join Date
    Nov 2012
    Posts
    4
    Rep Power
    0
    Originally Posted by WynnDeezl
    Hi, i've seen where you can separate the numerical portion of a string from the other parts, but can't remember the syntax. i have some data like:

    ABCD1234
    FS9057
    AGSVGA34

    what is the syntax to pull out only the numerical values?

    thank you!
    >>> "1".isdigit()
    True
    >>> "A".isdigit()
    False
    >>>
    #Loop over data and parse out what you need

    Comments on this post

    • WynnDeezl agrees : Got it! Thanks.

IMN logo majestic logo threadwatch logo seochat tools logo