<?xml version="1.0" encoding="UTF-8" standalone="yes" ?>
<!DOCTYPE bugzilla SYSTEM "https://bugs.kde.org/page.cgi?id=bugzilla.dtd">

<bugzilla version="5.0.6"
          urlbase="https://bugs.kde.org/"
          
          maintainer="sysadmin@kde.org"
>

    <bug>
          <bug_id>432494</bug_id>
          
          <creation_ts>2021-02-04 05:52:10 +0000</creation_ts>
          <short_desc>Advanced search album does not search subfolders nothing</short_desc>
          <delta_ts>2021-02-06 12:47:12 +0000</delta_ts>
          <reporter_accessible>1</reporter_accessible>
          <cclist_accessible>1</cclist_accessible>
          <classification_id>2</classification_id>
          <classification>Applications</classification>
          <product>digikam</product>
          <component>Searches-Advanced</component>
          <version>7.2.0</version>
          <rep_platform>macOS (DMG)</rep_platform>
          <op_sys>macOS</op_sys>
          <bug_status>RESOLVED</bug_status>
          <resolution>WORKSFORME</resolution>
          
          
          <bug_file_loc></bug_file_loc>
          <status_whiteboard></status_whiteboard>
          <keywords></keywords>
          <priority>NOR</priority>
          <bug_severity>normal</bug_severity>
          <target_milestone>---</target_milestone>
          
          
          <everconfirmed>0</everconfirmed>
          <reporter name="Joseph Chang">yuchia</reporter>
          <assigned_to name="Digikam Developers">digikam-bugs-null</assigned_to>
          <cc>metzpinguin</cc>
          
          <cf_commitlink></cf_commitlink>
          <cf_versionfixedin>7.2.0</cf_versionfixedin>
          <cf_sentryurl></cf_sentryurl>
          <votes>0</votes>

      

      

      

          <comment_sort_order>oldest_to_newest</comment_sort_order>  
          <long_desc isprivate="0" >
    <commentid>2000102</commentid>
    <comment_count>0</comment_count>
    <who name="Joseph Chang">yuchia</who>
    <bug_when>2021-02-04 05:52:10 +0000</bug_when>
    <thetext>SUMMARY
When trying to search a filename using advanced search, digikam only returns the results if exact folder is selected. If the parent folder is selected, digikam return nothing.

STEPS TO REPRODUCE
1. Album structure:
   2020/01/test1.jpg
       /02/test2.jpg
2. In advanced search: album: 2020--&gt;01, search field: test1.jpg --&gt; return the file
3. In advanced search: album field: 2020, search field: test1.jpg --&gt; return nothing.


OBSERVED RESULT


EXPECTED RESULT
I would expect we can select a folder in ablum field, digikam will search all subfolders.

SOFTWARE/OS VERSIONS
Windows: 
macOS: Big Sur 11.2
Linux/KDE Plasma: 
(available in About System)
KDE Plasma Version: 
KDE Frameworks Version: 
Qt Version: 

ADDITIONAL INFORMATION</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>2000107</commentid>
    <comment_count>1</comment_count>
    <who name="Maik Qualmann">metzpinguin</who>
    <bug_when>2021-02-04 06:58:33 +0000</bug_when>
    <thetext>This behavior is so intended. Only the selected albums are searched. You can right-click the parent album and choose to select automatically also the child albums as well.

Maik</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>2000535</commentid>
    <comment_count>2</comment_count>
    <who name="Joseph Chang">yuchia</who>
    <bug_when>2021-02-06 02:07:34 +0000</bug_when>
    <thetext>Thanks for the information. 

It just seems natural to me if a folder is selected, all the subfolders are also searched. Otherwise, I can just select the subfolder itself, not the parent folder. 

The only situation I can think of to exclude the subfolders is if the parent folder also contain photos, then it makes sense to select the folder but excludes the subfolders.

Thanks,
Joseph</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>2000586</commentid>
    <comment_count>3</comment_count>
    <who name="Maik Qualmann">metzpinguin</who>
    <bug_when>2021-02-06 12:47:12 +0000</bug_when>
    <thetext>The behavior is the same in all album selectors in digiKam. Surely we could reverse the behavior and one would have to deselect children&apos;s albums. But long-time digiKam users know the behavior no different.

Maik</thetext>
  </long_desc>
      
      

    </bug>

</bugzilla>