Bacula-users

Re: [Bacula-users] How to find all file .avi from full tape

2010-05-31 07:12:54
Subject: Re: [Bacula-users] How to find all file .avi from full tape
From: "Mike Holden" <bacula AT mikeholden DOT org>
To: bacula-users AT lists.sourceforge DOT net
Date: Mon, 31 May 2010 12:09:59 +0100
Simone Martina wrote:
> Thanks for your suggestions, I propose a query made with help of a
> friend of mine:
> SELECT CONCAT(Path.Path,Filename.Name) FROM Filename Inner Join File
> ON
> Filename.FilenameId = File.FilenameId Inner Join Path ON File.PathId
> =
> Path.PathId where (Filename.Name LIKE "%avi") OR (Filename.Name LIKE
> "%AVI") OR (Filename.Name LIKE "%mpeg") OR (Filename.Name LIKE
> "%MPEG")
> OR (Filename.Name LIKE "%mpg") OR (Filename.Name LIKE "%MPG");

You can simplify the multiple instances of the same extension in
different cases by using UPPER() like this:

OR UPPER((Filename.Name LIKE "%MPG"))

-- 
Mike Holden

http://www.by-ang.com - the place to shop
for all manner of hand crafted items,
including Jewellery, Greetings Cards and Gifts


------------------------------------------------------------------------------

_______________________________________________
Bacula-users mailing list
Bacula-users AT lists.sourceforge DOT net
https://lists.sourceforge.net/lists/listinfo/bacula-users

<Prev in Thread] Current Thread [Next in Thread>