Search by File Name

Thanks for your time!

I'm using:

WDS 3.0
UNCFATPHInstaller.msi
NetWare 6.0 SP5, volume in NSS pool, running NSS 3.05, no compression, level 2 oplocks and client file caching both off.

I'm trying to search by file name. Can you help

Example: The indexed folder contains a file named: 120007AL.DWG

How do I search for this file by name I've tried:

file:120007AL.DWG (result: not found)
filename:120007AL.DWG (result: not found)
120007AL.DWG (result: found)
file:120007AL (result: not found)
filename:120007AL (result: not found)
120007AL (result: found)

Code:

Function query_flnm(ByVal str_flnm As String) As String

Dim mSearchClass As New Query.SearchDesktopClass
Dim resultSet As Query._Recordset
Dim str_qry As String

str_qry = "file:" & str_flnm

resultSet = mSearchClass.ExecuteQuery(str_qry, "System.ItemFolderPathDisplay", "", Nothing)

Try
query_flnm = resultSet(0).Value
Catch
query_flnm = ""
End Try

mSearchClass = Nothing

resultSet = Nothing

End Function



Answer this question

Search by File Name

  • RedKMan

    try this:

    resultSet = mSearchClass.ExecuteSQLQuery("SELECT System.FileName FROM systemindex..scope() WHERE System.FileName='12007AL.DWG' ORDER BY System.FileName")

     


  • Dean Curtin

    I check AQS help, filename:12007AL.DWG is right. So maybe some other reason make it failed.
    Property: Use: Example
    Title title, subject, about title:sample
    Status status status:sample
    Date date date:last week
    Date modified datemodified, modified modified:last week
    Importance importance, priority importance:high
    Size size size:> 50
    Deleted deleted,isdeleted is:deleted
    Is attachment isattachment is:attachment
    To to, toname to:sample
    Cc cc, ccname cc:sample
    Company company company:sample
    Location location location:sample
    Category category category:sample
    Keywords keywords keywords:sample
    Album album album:sample
    File name filename, file filename:sample
    Genre genre genre:sample
    Author author, by author:sample
    People people, with with (sonja mo david)
    Folder folder, under, path folder:sample
    Ext ext, fileext ext:sample
    File name filename, file filename:sample

  • Search by File Name