Search Repository
This activity searches for entries in a Laserfiche repository. The entries the search finds can be accessed with the For Each Entry activity. See the tokens this activity produces.
Note: After this activity runs, the Messages Tab of the workflow instance details will list how many entries the search returned.
To add this activity to a workflow definition
- Drag it from the Toolbox Pane and drop it in the Designer Pane.
To configure this activity
- Select the activity in the Designer Pane to configure the following property boxes in the Properties Pane.
- Activity Name
- Activity Description
- Search Query
-
Note: If you have more than one connection profile for your workflow definition, the Connection Profile property box lets you specify which connection profile this activity will use.
Tokens for Search Repository
The Search Repository activity produces tokens for the first result found, and tokens for the current entry when used with the For Each Entry activity.
Tokens for the first result found
The tokens for the first result found are identical to those for each entry found in the Find Entries activity, except that the token names begin with First_Result
rather than CurrentEntry
, and the syntax for each token begins with %(SearchRepository_FirstResult
rather than %(ForEachEntry_CurrentEntry
.
Example: Where the Find Entries activity has the token CurrentEntry_CreationDate
with syntax %(ForEachEntry_CurrentEntry_CreationDate)
, the Search Repository activity has the token FirstResult_CreationDate
with syntax %(SearchRepository_FirstResult_CreationDate)
.
The following table provides more examples of tokens for the first result found. This is an incomplete listing: All tokens for each entry found in the Find Entries activity have a counterpart in the Search Repository activity.
Name | Description | Sample Syntax* |
---|---|---|
FirstResult_Name | The name of the first entry found by the Search Repository activity. | %(SearchRepository_FirstResult_Name) |
FirstResult_ID | The Laserfiche ID number of the first entry found by the Search Repository activity. | %(SearchRepository_FirstResult_Id) |
FirstResult_Path | The folder path of the first entry found by the Search Repository activity. | %(SearchRepository_FirstResult_Path) |
FirstResult_FullPath | The folder path of the first entry found by the Search Repository activity, including the entry's name in the path. | %(SearchRepository_FirstResult_FullPath) |
FirstResult_Repository | The repository that contains the first entry found by the Search Repository activity. | %(SearchRepository_FirstResult_Repository) |
FirstResult_Server | The Laserfiche Server that contains the first entry found by the Search Repository activity. | %(SearchRepository_FirstResult_Server) |
FirstResult_Guid | The GUID (Globally Unique Identifier) of the first entry found by the Search Repository activity. | %(SearchRepository_FirstResult_Guid) |
Result Count | The number of entries found by the Search Repository activity. | %(SearchRepository_Result Count) |
*The "SearchRepository" portion of the syntax changes to match the activity's name as specified in the Activity Name property box. Note that all non-alphanumeric characters, except underscores, are removed from the name. For example, if you rename the activity "LookforHR_Fields", the syntax for the FirstResult_Id
token will be %(LookforHR_Fields_FirstResult_Id)
.
Tokens for each entry found
More tokens are available when the Search Repository activity is used with the For Each Entry activity. The For Each Entry activity runs one time per entry. Each time it runs, the token values reflect the information relevant to the entry it is currently processing.
The tokens available for each entry found are identical to those for each entry found in the Find Entries activity. The following table provides some examples of them. For a complete listing, look at the token list for each entry found in the Find Entries activity.
Name | Description | Sample Syntax* |
---|---|---|
CurrentEntry_Name | The name of the current entry. | %(ForEachEntry_CurrentEntry_Name) |
CurrentEntry_Id | The Laserfiche ID number of the current entry. | %(ForEachEntry_CurrentEntry_Id) |
CurrentEntry_Path | The folder path of the current entry. | %(ForEachEntry_CurrentEntry_Path) |
CurrentEntry_FullPath | The folder path of the current entry, including the entry's name. | %(ForEachEntry_CurrentEntry_FullPath) |
CurrentEntry_Repository | The repository the current entry is in. | %(ForEachEntry_CurrentEntry_Repository) |
CurrentEntry_Server | The Laserfiche Server that contains the current entry. | %(ForEachEntry_CurrentEntry_Server) |
CurrentEntry_Guid | The GUID (Globally Unique Identifier) of the current entry. | %(ForEachEntry_CurrentEntry_Guid) |
*The "ForEachEntry" portion of the syntax changes to match the activity's name as specified in the Activity Name property box. Note that all non-alphanumeric characters, except underscores, are removed from the name. For example, if you rename the activity Apply [Settings] to Each, the syntax for the CurrentEntry_Id token will be %(ApplySettingstoEach_CurrentEntry_Id).