+ Reply to Thread
Results 1 to 2 of 2

Extract text/string from URL text

  1. #1
    Registered User
    Join Date
    05-14-2019
    Location
    Singapore
    MS-Off Ver
    4
    Posts
    1

    Extract text/string from URL text

    So I need some help here...
    I have columns A to G like this:

    I have a query code in A1 which retrieves some data from other spreadsheet in other tab:
    =query('A spreadsheet'!A:T,"select F, B where (T = 'Yes') and F != '' label F 'url1', B 'special code'")

    The code works fine everything works.
    But the question is, I want to retrieve the text after the "/" in url1
    So like this..
    From ht..tp//youtu.be/8tMq70b0Ork
    To
    8tMq70b0Ork
    So what I need is to remove the "...//youtu.be/"

    What do i do? Is there any way to combine the formula needed for that with the query code I have above?
    Because I need to do this for many rows and cells not just a cell.

    Thank you.
    Attached Images Attached Images

  2. #2
    Forum Expert CK76's Avatar
    Join Date
    06-16-2015
    Location
    ONT, Canada
    MS-Off Ver
    Office 365 ProPlus
    Posts
    5,883

    Re: Extract text/string from URL text

    If "ht..tp//youtu.be/" is constant...

    You can use SUBSTITUTE.
    =SUBSTITUTE(YourUDF,"ht..tp//youtu.be/","")

    If it isn't constant, and you want portion after last "/".
    =TRIM(RIGHT(SUBSTITUTE(YourUDF,"/",REPT(" ",99)),99))
    ?Progress isn't made by early risers. It's made by lazy men trying to find easier ways to do something.?
    ― Robert A. Heinlein

+ Reply to Thread

Thread Information

Users Browsing this Thread

There are currently 1 users browsing this thread. (0 members and 1 guests)

Similar Threads

  1. Extract numbers after a specific text from a text string
    By robertovm28 in forum Excel General
    Replies: 7
    Last Post: 04-23-2019, 09:53 PM
  2. Extract text between two characters in a string - varing text length
    By luv2birdie in forum Excel Formulas & Functions
    Replies: 3
    Last Post: 11-04-2014, 06:10 PM
  3. [SOLVED] Extract text from a given point in a text string, when data points do not share the given
    By reedersketer in forum Excel Formulas & Functions
    Replies: 3
    Last Post: 07-09-2014, 03:57 PM
  4. [SOLVED] How to extract text strings out of longer text string
    By GIS2013 in forum Excel Formulas & Functions
    Replies: 9
    Last Post: 09-17-2013, 06:08 AM
  5. [SOLVED] Extract text from a string of text (amend formula to include new criteria)
    By robertguy in forum Excel Formulas & Functions
    Replies: 2
    Last Post: 09-10-2013, 04:53 PM
  6. Replies: 5
    Last Post: 05-03-2011, 09:35 AM
  7. [SOLVED] EXTRACT TEXT FROM TEXT STRING:The names are of variable length
    By carricka in forum Excel Formulas & Functions
    Replies: 4
    Last Post: 07-08-2005, 06:05 AM

Tags for this Thread

Bookmarks

Posting Permissions

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

Search Engine Friendly URLs by vBSEO 3.6.0 RC 1