INTERACT FORUM

More => Old Versions => JRiver Media Center 19 for Windows => Topic started by: spiggytopes on August 18, 2014, 04:32:14 am

Title: Spanning two NAS drives
Post by: spiggytopes on August 18, 2014, 04:32:14 am
Hi All,

I use the attached method to display folders in Video, like Films, History etc based on the Windows folder name. Works really well.

Note that only drive V: is covered.

How can I extend this to include say, drive B:?

Cheers.
Title: Re: Spanning two NAS drives
Post by: Arindelle on August 18, 2014, 05:02:39 am
http://wiki.jriver.com/index.php/Seach_Expressions#Grouping_and_Combining (http://wiki.jriver.com/index.php/Seach_Expressions#Grouping_and_Combining) is a good place to start :)

looks like you would just use AND in the expression and parentheses

you can't to my knowledge do this through the wizard though (as in your second screen shot. You should hit the import/export box (through the customize view dialogue) and type or paste the expression. Afterwards in the wizard pop-up you will see parentheses added around the applicable rules.

Title: Re: Spanning two NAS drives
Post by: spiggytopes on August 18, 2014, 05:18:55 am
Hi and thanks for the reply.

I tried to replace:

replace([Filename (path)], V:\)&datatype=[Filename (path)], V:\ AND B:\)&datatype=[/list]
Title: Re: Spanning two NAS drives
Post by: spiggytopes on August 19, 2014, 11:44:43 pm
Anyone?

NAS 1 nearly full!

So I need to include NAS 2 now ...
Title: Re: Spanning two NAS drives
Post by: Vincent Kars on August 20, 2014, 03:12:53 pm
If I understand you correctly
you have a NAS mapped to a drive e..g V:\
you add a second NAS also mapped to a drive letter e.g. W:\
You want to get rid of the drive letter in the view

Try RemoveLeft([Filename (path)],3)
Title: Re: Spanning two NAS drives
Post by: robydago on August 20, 2014, 03:35:43 pm
Hi and thanks for the reply.

I tried to replace:

replace([Filename (path)], V:\)&datatype=
    with

    replace(
[Filename (path)], V:\ AND B:\)&datatype=
    But it doesn't work.

    Is that what you meant?  :)

[/list]

why don't you use just ":\"?
":" is not allowed in folder name so you should be able to get rid of any drive letter

EDIT my suggestion won't eliminate the drive letter itself... you would need some sort of regex for that to work I guess. don'remember if MC has any regex capabilities

EDIT2 it does: http://wiki.JRiver.com/index.php/Media_Center_expression_language#Regex.28.E2.80.A6.29:_Regular_expression_pattern_matching_and_capture
so it should be doable with a regex search for any single char followed by ":\"

EDIT3
I should have read Vincent suggestion before: looks a lot easier...
Title: Re: Spanning two NAS drives
Post by: spiggytopes on August 21, 2014, 06:11:28 am
If I understand you correctly
you have a NAS mapped to a drive e..g V:\
you add a second NAS also mapped to a drive letter e.g. W:\
You want to get rid of the drive letter in the view

Try RemoveLeft([Filename (path)],3)

Not exactly.

I would like to add Drive B:\ to the existing Drive V:\ under the title "Films" ............
Title: Re: Spanning two NAS drives
Post by: robydago on August 21, 2014, 07:02:08 am
Hi and thanks for the reply.

I tried to replace:

replace([Filename (path)], V:\)&datatype=
    with

    replace(
[Filename (path)], V:\ AND B:\)&datatype=
    But it doesn't work.

    Is that what you meant?  :)

[/list]

You should try with OR since no filepath will have both driveletters at the same time.
No idea if your syntax is correct though
Title: Re: Spanning two NAS drives
Post by: Arindelle on August 21, 2014, 10:25:55 am
Hi and thanks for the reply.

I tried to replace:

replace([Filename (path)], V:\)&datatype=
    with

    replace(
[Filename (path)], V:\ AND B:\)&datatype=
    But it doesn't work.

    Is that what you meant?  :)

[/list]

not really because you didn't put in the parenthesis (and don't use the wizard, use the import box)

Code: [Select]
(replace([Filename (path)], V:\)  AND (B:\)&datatype=[list])
this seems to get converted to this (look at the pane which includes parentheses outside of the dropdown boxes)
(http://i.imgur.com/QFPEGFp.png)

now this could be wrong LOL I can't test this right now, should be pretty close -- hope you have backups and the number of parenthesis are correct ;D