Using Saved searches/

How can we tell if an entry in the SavedFilter table is a saved search or a saved report?

And how do you tell if the saved search is for a contact or a company?

Hi @Dom_Cassone, unfortunately I don’t think there’s a way to distinguish between a saved search or a saved report in the SavedFilter table.

Are you asking how can you tell if the search search is for a contact search versus a company search? I think you’re only option for that would be to look at the ReportStoredname. A contact search will be AdvContactSearch while a company search will be CompanySearch.

Hi Nicholas,

Thanks for the reply!

Actually, I want to know both, in general.

  1. is it a saved search or a saved report
  2. is it for a company or a contact.

Specifically, for this project, I want to build a drop-down list of human-readable names of company saved search (mapped to ID of course) for the user to pick the one he wants to use.

Hmm, if all you need to do is pull a list of company saved searches I believe you could do something like this.

<?xml version='1.0' encoding='UTF-8'?>
<methodCall>
  <methodName>DataService.query</methodName>
  <params>
    <param>
      <value><string>{{privateKey}}</string></value>
    </param>
    <param>
      <value><string>SavedFilter</string></value>
    </param>
    <param>
      <value><int>100</int></value>
    </param>
    <param>
      <value><int>0</int></value>
    </param>
    <param>
      <value>
        <struct>
          <member>
            <name>ReportStoredname</name>
            <value>CompanySearch</value>
          </member>
        </struct>
      </value>
    </param>
    <param>
      <value>
        <array>
          <data>
            <value><string>Id</string></value>
            <value><string>FilterName</string></value>
            <value><string>ReportStoredname</string></value>
            <value><string>UserId</string></value>
          </data>
        </array>
      </value>
    </param>
  </params>
</methodCall>
2 Likes