Advanced searches possible?

31 views
Skip to first unread message

Polarbeer

unread,
Apr 30, 2012, 7:12:50 AM4/30/12
to JPhotoTagger Users English
Now that I have managed to add keywords, descriptions and ratings to
many thousands of photos and videos on my hard drive using
JPhotoTagger, I have started to wonder, if it is possible to combine
several different search criteria to make advanced searches among your
files? Can I search and display in thumbnails area for example all
files that:
- contain keywords "A" and "D"
- are located under folders "Photos2010" or "Photos2011" (and their
sub-folders) on my hard drive
- have a rating of 3-5 stars

Thanks for your help!

-pb

PS. Maybe those small black triangles located between left-hand,
center and right-hand panels should be made a little bigger, although
I haven't used them myself very often?

Elmar Baumann

unread,
Apr 30, 2012, 2:41:18 PM4/30/12
to jphototagger-...@googlegroups.com, Polarbeer
On 30.04.2012 13:12, Polarbeer wrote:
> Can I search and display in thumbnails area for example all
> files that:
> - contain keywords "A" and "D"
> - are located under folders "Photos2010" or "Photos2011" (and their
> sub-folders) on my hard drive
> - have a rating of 3-5 stars

Hello Polarbeer,

currently searching images with multiple Keywords can't be combined with
"Simple SQL". Maybe, I will implement this in a future release.

Using "Simple SQL", an image can't have a keyword X AND Y, it's
exclusive. Simple SQL finds only images with keywords X OR Y. If you
search only for one keyword or keywords with OR, searching for criteria
as obove is possible:

* F3 (displays the Advanced Search dialog)
* Select tab "Simple SQL"
* Press button "Add column"
* "and" "Keyword" "equals" "A"
(or use "matches" "%part of name%" - enclosed within
percent characters)
* Press button "Add column"
* "and" "File name" "matches" "%Photos2010%"
Marked as Bug: Braces have to be enabled to
include other folders ("%Photos2010%")
* Press button "Add column"
* "and" "Rating" "greater or equals" "3"
* Press button "Add column"
* "and" "Rating" "lower or equals" "5"
* Consider saving the search

> PS. Maybe those small black triangles located between left-hand,
> center and right-hand panels should be made a little bigger, although
> I haven't used them myself very often?

I marked that as feature request, it must be configurable (and thus
needs some time to implement).

--
http://www.elmar-baumann.de/fotografie/

Polarbeer

unread,
Apr 30, 2012, 4:44:14 PM4/30/12
to JPhotoTagger Users English
Thanks for your time once again Elmar!

By making just super quick tests in the Advanced Search -dialog (Edit-
menu --> Search F3) I think I was able to make a search I described in
my thread starter message.

I first entered the keywords I wanted to exist on the KEYWORD
COMBINATIONS -tab and after that entered additional search criteria on
the SIMPLE SQL -tab. When I hit the SEARCH NOW -button, JPhotoTagger
used data on both tabs to find the files I wanted to! At least I
believe it did. =)

I don't know if this is somehow "wrong" way of using Advanced Search
-dialog, because when I have saved my search settings and exist and re-
enter Advanced Search -dialog I get a warning:

"Search specifications have to be only whithin one register, e.g. only
whithin "Simple SQL".

This probably means I should have search criteria only on one tab of
the Advanced Search -dialog. Are the searches made by entering data on
two tabs (= registers?) somehow unreliable??

By the way is the word "register" used widely for example in Linux or
Macintosh world, because it is totally new term for me, when referring
to user interface elements of PC programs. (But databases and programs
used to create and manage them are also totally new area for me...)

Just curious!

-pb

Elmar Baumann

unread,
May 1, 2012, 2:17:00 PM5/1/12
to jphototagger-...@googlegroups.com, Polarbeer
On 30.04.2012 22:44, Polarbeer wrote:
> I first entered the keywords I wanted to exist on the KEYWORD
> COMBINATIONS -tab and after that entered additional search criteria on
> the SIMPLE SQL -tab. When I hit the SEARCH NOW -button, JPhotoTagger
> used data on both tabs to find the files I wanted to! At least I
> believe it did. =)

Hello Polarbeer,

I enabled this feature again in the current version 0.24.10. Now You can
create a search as described:

* F3 (displays the Advanced Search dialog)
* Select tab "Keyword combinations"
* Enter the keywords
* Select tab "Simple SQL"
* Press button "Add column"
* "and" "(" "File name" "matches" "%Photos2010%"
* Press button "Add column"
* "or" "File name" "matches" "%Photos2011%" ")"
* Press button "Add column"
* "and" "Rating" "greater or equals" "3"
* Press button "Add column"
* "and" "Rating" "lower or equals" "5"

The point is: The OR searches are enclosed within brackets.

> By the way is the word "register" used widely for example in Linux or
> Macintosh world, because it is totally new term for me, when referring
> to user interface elements of PC programs. (But databases and programs
> used to create and manage them are also totally new area for me...)

Internally I use the term "Tab", I don't know what the user expects. If
they use "Tab" to some occurences has to be replaced within messages.

Regards,
Elmar
--
http://www.elmar-baumann.de/fotografie/

Polarbeer

unread,
May 3, 2012, 12:48:11 PM5/3/12
to JPhotoTagger Users English
On 30 huhti, 21:41, Elmar Baumann <e...@elmar-baumann.de> wrote:

> currently searching images with multiple Keywords can't be combined with
> "Simple SQL". Maybe, I will implement this in a future release.

This is kind of weird, as you can combine several other search
criteria with AND condition on Simple SQL tab. Of course you can now
use "Keyword combinations" tab, but it would be nice if "all" could be
done on Simple SQL tab.

Nevertheless, thanks for helping me out on this!

-pb

Elmar Baumann

unread,
May 3, 2012, 3:21:35 PM5/3/12
to jphototagger-...@googlegroups.com, Polarbeer
On 03.05.2012 18:48, Polarbeer wrote:
> On 30 huhti, 21:41, Elmar Baumann <e...@elmar-baumann.de> wrote:
>
>> currently searching images with multiple Keywords can't be combined with
>> "Simple SQL". Maybe, I will implement this in a future release.
>
> This is kind of weird, as you can combine several other search
> criteria with AND condition on Simple SQL tab. Of course you can now
> use "Keyword combinations" tab, but it would be nice if "all" could be
> done on Simple SQL tab.

Hello,

in version 0.24.10 this is no longer an issue, it's possible to combine
keyword combinations with simple SQL.

Elmar Baumann

unread,
May 3, 2012, 3:37:19 PM5/3/12
to jphototagger-...@googlegroups.com, Polarbeer
On 03.05.2012 18:48, Polarbeer wrote:
> use "Keyword combinations" tab, but it would be nice if "all" could be
> done on Simple SQL tab.

To make clear the intention of "Simple SQL": It's a "really simple" SQL
search, it has limitations: It doesn't use "advanced" features of SQL
such as the "IN" operator. That means, it is not possible, to find an
image containing keyword "A" and keyword "B", because from the
perspective of the "simple SQL" query, a keyword is either "A" or it is
"B", it can't be "A AND B". That can be done with an "advanced" SQL
query done through the separate keyword tab.

If I had more time, I would change that to a "dummy mode", but that is
not easy (i.e. time consuming to implement) and would mean the loss of
the "bracket feature" that is understood fully only with some knowledge
of the SQL syntax.

--
http://www.elmar-baumann.de/fotografie/
Reply all
Reply to author
Forward
0 new messages