# Need help with export

**URL:** https://community.mp3tag.de/t/need-help-with-export/3886
**Category:** Export
**Created:** [October 11, 2006, 8:57am UTC](https://community.mp3tag.de/t/need-help-with-export/3886 "2006-10-11T08:57:18Z")
**Posts on this page:** 7
**Page:** 1

<div class="post-metadata">

### Author: ![rmg](https://community.mp3tag.de/letter_avatar_proxy/v4/letter/r/278dde/32.png) [@rmg](https://community.mp3tag.de/u/rmg)
#### Post date: [October 11, 2006, 8:57am UTC](https://community.mp3tag.de/t/need-help-with-export/3886/1 "2006-10-11T08:57:18Z")

</div>

I'm trying to export in the following format

```
Artist
  Album
    Tracks
  Album
    Tracks
Artist
  Album
    Tracks

```

All is fine when a disc has only one artist.  
The problem arises with the Various Artists albums.  
I have all my albums with the following directory naming schema:  
 - -   
and for VA I have:  
VA - -

Now the question is, if it's possible to get my VA albums (which can be distinguished form the ordinary albums by the directory name which starts with "VA - ") to the same format as mentioned above. And if they were sorted ascending by year then it would add additional bonus to the script 🙂

Thank you in advance  
Romi

---

<div class="post-metadata">

### Author: ![milka](https://community.mp3tag.de/user_avatar/community.mp3tag.de/milka/32/55_2.png) [@milka](https://community.mp3tag.de/u/milka)
#### Post date: [October 12, 2006, 6:09am UTC](https://community.mp3tag.de/t/need-help-with-export/3886/2 "2006-10-12T06:09:06Z")

</div>

See [this](https://community.mp3tag.de/t/3173/1) topic, SquallLeonhart38 have some scripts for VA albums.

---

<div class="post-metadata">

### Author: ![rmg](https://community.mp3tag.de/letter_avatar_proxy/v4/letter/r/278dde/32.png) [@rmg](https://community.mp3tag.de/u/rmg)
#### Post date: [October 12, 2006, 5:06pm UTC](https://community.mp3tag.de/t/need-help-with-export/3886/3 "2006-10-12T17:06:21Z")

</div>

I only saw JavaScript solutions? But I don't want to do a html page. I was looking for some script to handle the VA case when exporting. I know you can do magic with Javascript, VBScript ... just this ain't my case.

So I am asking anyone who knows MP3TAGs scripting capabilities a bit more in detail. Can it be done in this level?

If not, then I'd really like to see a scripting language enhancements in the future verisons that could allow executing a block of script when a condition is met. At the moment I cannot execute the following if statement:

```
$if(condition,
bla bla
 bla %something%
<a loop>
, some other script when the condidion is not met )
```

---

<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: [October 12, 2006, 5:56pm UTC](https://community.mp3tag.de/t/need-help-with-export/3886/4 "2006-10-12T17:56:14Z")

</div>

The simplest solution is when you have a tag for VA albums:  
**$loop($if(%album artist%,%album artist%,%artist%))**

But you can of course insert a check if the direcotry name starts with "VA - "  
**$loop($if($eql($left(%\_directory%,5),VA - ),VA,%artist%))**

---

<div class="post-metadata">

### Author: ![rmg](https://community.mp3tag.de/letter_avatar_proxy/v4/letter/r/278dde/32.png) [@rmg](https://community.mp3tag.de/u/rmg)
#### Post date: [October 13, 2006, 5:04am UTC](https://community.mp3tag.de/t/need-help-with-export/3886/5 "2006-10-13T05:04:07Z")

</div>

I don't know if FLAC supports Album Artist tag. Even if it does I think that my current albums don't have it set.

But I'll try the second script, that looks promising.  
Thanks.

---

<div class="post-metadata">

### Author: ![milka](https://community.mp3tag.de/user_avatar/community.mp3tag.de/milka/32/55_2.png) [@milka](https://community.mp3tag.de/u/milka)
#### Post date: [October 13, 2006, 9:39am UTC](https://community.mp3tag.de/t/need-help-with-export/3886/6 "2006-10-13T09:39:57Z")

</div>

What I was trying to say is that you can do it when you have a tag for VA albums like in SquallLeonhart38 exports.

---

<div class="post-metadata">

### Author: ![rmg](https://community.mp3tag.de/letter_avatar_proxy/v4/letter/r/278dde/32.png) [@rmg](https://community.mp3tag.de/u/rmg)
#### Post date: [October 13, 2006, 12:50pm UTC](https://community.mp3tag.de/t/need-help-with-export/3886/7 "2006-10-13T12:50:06Z")

</div>

Heh, **milka** , you're a genius.

I figured out the check against VA albums ( $if($eql($left(%\_directory%,5),VA - ),VA,%artist%) ) myself too.

But using it inside the loop like **$loop($if($eql($left(%\_directory%,5),VA - ),VA,%artist%))** is brilliant. It works and does just what I need.

I get my albums exported the way I wanted.

```
A artist
  album1
    tracks
  album2
    tracks
B artist
...
VA
  album1
    tracks
  album2
    tracks
W artist
....

```

Yet another plus for MP3Tag.
