# New here: How do I...

**URL:** https://community.mp3tag.de/t/new-here-how-do-i/3201
**Category:** General Discussion
**Created:** [April 17, 2006, 7:19pm UTC](https://community.mp3tag.de/t/new-here-how-do-i/3201 "2006-04-17T19:19:21Z")
**Posts on this page:** 8
**Page:** 1

<div class="post-metadata">

### Author: ![Viper](https://community.mp3tag.de/letter_avatar_proxy/v4/letter/v/b3f665/32.png) [@Viper](https://community.mp3tag.de/u/Viper)
#### Post date: [April 17, 2006, 7:19pm UTC](https://community.mp3tag.de/t/new-here-how-do-i/3201/1 "2006-04-17T19:19:21Z")

</div>

I looked at the ACTIONS shared by some users and I think one of them may(??) do what I want but the way the solution was presented makes no sense to me as to how to implement it.

Anyway, here's what I would like to do:

1. Replace all occurrences of two or more contiguous spaces with only one.
2. Given the following: MADONNA-^MATERIAL GIRL (where ^ is my representation of a blank space), change it to MADONNA^-^MATERIAL GIRL
3. Conversely, given the following: MADONNA^-MATERIAL GIRL (where ^ is my representation of a blank space), change it to MADONNA^-^MATERIAL GIRL
4. For requests 2 & 3 above, the end result is to always have the dash character with one leading and one trailing blank space

Can someone help this novice out with very specific instructions on how to do it?

Many thanks in advance...

---

<div class="post-metadata">

### Author: ![dano](https://community.mp3tag.de/user_avatar/community.mp3tag.de/dano/32/6_2.png) [@dano](https://community.mp3tag.de/u/dano)
#### Post date: [April 17, 2006, 9:09pm UTC](https://community.mp3tag.de/t/new-here-how-do-i/3201/2 "2006-04-17T21:09:58Z")

</div>

Use **Replace with regular expression** as action type:

1. 

_Regular expression_: **\s{2,}**  
_Replace matches with_: " "

1. 
  - 
    1. 

_Regular expression_: **\s?-\s?**  
_Replace matches with_: " - "

(This would also turn MADONNA-MATERIAL GIRL into MADONNA^-^MATERIAL GIRL, if you don't want this, use (\s-|-\s) as expression)

---

<div class="post-metadata">

### Author: ![Viper](https://community.mp3tag.de/letter_avatar_proxy/v4/letter/v/b3f665/32.png) [@Viper](https://community.mp3tag.de/u/Viper)
#### Post date: [April 20, 2006, 10:49pm UTC](https://community.mp3tag.de/t/new-here-how-do-i/3201/3 "2006-04-20T22:49:03Z")

</div>

> [@](#):
>
> Use **Replace with regular expression** as action type:
> 
> 1. 
> 
> _Regular expression_: **\s{2,}**  
> _Replace matches with_: " "
> 
> 1. 
> - 
> 1. 
> 
> _Regular expression_: **\s?-\s?**  
> _Replace matches with_: " - "
> 
> (This would also turn MADONNA-MATERIAL GIRL into MADONNA^-^MATERIAL GIRL, if you don't want this, use (\s-|-\s) as expression)
> 
> \<{POST\_SNAPBACK}\>

Thanks for your reply...

Your first expression worked great, the second did not.

I guess that what I'm looking for is for a way to place only one leading and only one trailing space when a dash is found no matter how many spaces or lack of spaces there are around that dash character.

Thanks once again!!!

---

<div class="post-metadata">

### Author: ![dano](https://community.mp3tag.de/user_avatar/community.mp3tag.de/dano/32/6_2.png) [@dano](https://community.mp3tag.de/u/dano)
#### Post date: [April 20, 2006, 11:03pm UTC](https://community.mp3tag.de/t/new-here-how-do-i/3201/4 "2006-04-20T23:03:54Z")

</div>

Try **\s\*-\s\*** as expression.

---

<div class="post-metadata">

### Author: ![Viper](https://community.mp3tag.de/letter_avatar_proxy/v4/letter/v/b3f665/32.png) [@Viper](https://community.mp3tag.de/u/Viper)
#### Post date: [April 22, 2006, 11:59am UTC](https://community.mp3tag.de/t/new-here-how-do-i/3201/5 "2006-04-22T11:59:43Z")

</div>

> [@](#):
>
> Try **\s\*-\s\*** as expression.
> 
> \<{POST\_SNAPBACK}\>

It worked!!!

Thanks Dano...

---

<div class="post-metadata">

### Author: ![Viper](https://community.mp3tag.de/letter_avatar_proxy/v4/letter/v/b3f665/32.png) [@Viper](https://community.mp3tag.de/u/Viper)
#### Post date: [April 23, 2006, 1:46pm UTC](https://community.mp3tag.de/t/new-here-how-do-i/3201/6 "2006-04-23T13:46:27Z")

</div>

> [@](#):
>
> It worked!!!
> 
> Thanks Dano...
> 
> \<{POST\_SNAPBACK}\>

Dano,

I have another somewhat related question, why won't this expression work: Replace "\_FILENAME": "^.mp3" -\> ".mp3", where ^ represents a space?

I also tried selecting "only as whole word" and/or "case-sensitive comparrison"... also didn't work.

Thanks in advance for your time and efforts.

---

<div class="post-metadata">

### Author: ![dano](https://community.mp3tag.de/user_avatar/community.mp3tag.de/dano/32/6_2.png) [@dano](https://community.mp3tag.de/u/dano)
#### Post date: [April 23, 2006, 2:10pm UTC](https://community.mp3tag.de/t/new-here-how-do-i/3201/7 "2006-04-23T14:10:01Z")

</div>

I think in "Replace" the \_FILENAME does not include the extension.

I wrote [here](https://community.mp3tag.de/t/967/1) how to do it with regular expressions.

---

<div class="post-metadata">

### Author: ![Viper](https://community.mp3tag.de/letter_avatar_proxy/v4/letter/v/b3f665/32.png) [@Viper](https://community.mp3tag.de/u/Viper)
#### Post date: [April 23, 2006, 5:02pm UTC](https://community.mp3tag.de/t/new-here-how-do-i/3201/8 "2006-04-23T17:02:49Z")

</div>

> [@](#):
>
> I think in "Replace" the \_FILENAME does not include the extension.
> 
> I wrote [here](https://community.mp3tag.de/t/967/1) how to do it with regular expressions.
> 
> \<{POST\_SNAPBACK}\>

What more can I say than _ **THANKS AGAIN!** _
