Use:
Code:
{title}{series:| - |}{series_index:0>3s| [|]}
Explanation (see
http://manual.calibre-ebook.com/temp...ced-formatting for the gory details):
Everything after the ":" is a modifier. The "|stuff|stuff" are prefixes and suffixes for the parent template (in this case, series) -- as you can see, you already have one for series_index.
This allows for making stuff dependent on the parent template existing. So. I simply moved the space and dash to be dependent on the series field not being empty.