P
P
PRO100_CALLIA2021-02-26 11:06:04
Google Sheets
PRO100_CALLIA, 2021-02-26 11:06:04

How to remove part of url between characters in Google Sheets?

There is a column in Google Spreadsheet with links to posted posts, you need to convert them in such a way that the text from the question mark to the last equal sign with a number is replaced with showtopic
Yes

http://testingipb.ipb.su/index.php?act=ST&f=2&t=2068
http://lili.ipb.su/index.php?act=ST&f=1&t=2785
http://majdan.ipb.su/index.php?act=ST&f=20&t=345
http://psychotronic.ipb.su/index.php?act=ST&f=2&t=251

Necessary
http://testingipb.ipb.su/index.php?showtopic=2068
http://lili.ipb.su/index.php?showtopic=2785
http://majdan.ipb.su/index.php?showtopic=345
http://psychotronic.ipb.su/index.php?showtopic=251

Such links are interspersed with others, it is desirable that only these are equal in the table.

Answer the question

In order to leave comments, you need to log in

1 answer(s)
V
Vladimir Yurchenkov, 2021-03-01
@EPIDEMIASH

Your formula will look quite long, you can write it, but it's too easy for you))))
I suggest the direction.
What will come in handy for you:
-IFERROR (the condition in case the link is incorrect. will be at the very beginning)
-IF (general condition, will go after IFERROR)
-LEFT(RIGHT(RIGHT)(DLSTR-SEARCH("?"...-(number cut off characters)
Then similar conditions that cut off unnecessary
text.In general, first cut off and get 2 values: - What
's before?
http://testingipb.ipb.su/index.php
- And what's after?
act=ST&f=2&t=2068

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question