Product documentation
In This Topic
    Dynamics Advanced Search - Search Configuration
    In This Topic

    The Search configuration is the container that holds all the operational search setup. The Search configuration enables the Dynamics Advanced Search solution to support multi-language, multi-company and multi-hierarchy search setups.

    A company can only be linked to 1 Search configuration at a time, but the same Search configuration can be linked to multiple companies, multiple indexes (for multiple languages) and multiple Category hierarchies. Note that it is also possible to use multiple Search configurations within an environment; if different companies require different search result lay-outs and/or different field data for example, or just a completely different search setup. 

    This topic describes how to set up a Search configuration.

     

    Search Configuration setup

    Navigate to Product information management > Setup > Advanced search > Search configuration

    Create new Search configuration

    Create a new Search configuration by clicking on the +New button and give the Search configuration a name. The module is pre-filled based on the module from where the configuration is created (so for Product information management it will say 'Product') and this cannot be edited. So make sure to create the Search configuration from the right module when using Search for multiple entities.

    Indexes

    Use the +Add button to add a new index record. A dialog will appear containing the following fields to be filled in:

    Field Description
    Search service

    Type the name of your Azure search service (this can be found in the Azure portal). 

    Key storage type

    Select Plain text to specify the admin key itself on this record, or select KeyVault to use the MS Key Vault functionality (more info on Key Vault can be found here). 

    Admin key Type (or copy+paste) the (primary) admin key of your Azure search service (when using Plain text as the Key storage type). 
    Key Vault certificate Select the KayVault certificate to be used for authentication if using it as the Key storage type (more info on Key Vault can be found here). 
    Status Checks if the service can be reached based on the given information (green check for yes, red cross for no).
    Search index

    Type the Name for your index. Note that the index name can only consist of lower case letters, dashes and numbers. The max. length for a Search index name is 128 characters.

    Please make sure to use a unique name (as any existing search index with the same name within the same Azure Search service will be overwritten).

    Create index

    Type the Name for your index. Note that the index name can only consist of lower case letters, dashes and numbers. The max. length for a Search index name is 128 characters.

    Please make sure to use a unique name (as any existing search index with the same name will be overwritten).

    Index valid Indicates if the index is valid by checking if it exists in the Azure search service. On a first creation this field will not yet contain the green tick, as it can only appear after the next step (which creates the index in the Azure search service). 
    Language

    Select the language for this index. Note that any langugae can only be used once within a Search configuration

    Once these fields have been specified, click 'OK' to create the index record and the actual index as well if the setting was activated. If the 'Create index' setting is not activated, the Manage button on the index line menu can be used as well to actually create the index by selecting (Re)create index.  

    Please make sure the index is created via these steps (either via the Create new index dialog or the Manage button), as the index is then created with several standard fields and index structures needed for proper operation. So allthough it is possible to create an index in the Azure search service itself, we do not support this method of creation.

    It is possible to add multiple indexes to the same Search configuration to support a multi-language setup, simply repeat the steps above. Each language in which the data needs to be stored (so it can be searched and displayed) needs their own index. Note that a language can only be used once within a search configuration.

    Edit

    If details on an index record need to be updated (for example when importing a database copy from a different environment or when the Search service moves to a different tenant or region), this button can be used. It will open up the 'Reassign Azure search service' dialog containing all the same fields as described in the 'Add' button, but allows for information to be edited. This will update the record and also reassign references for the saved searches.

    Please note that the reassign function does not validate if scheme's are the same etc., it is purely a reassign without any additional validations to be able to support the scenario's mentioned.  

    Remove

    Removes index record(s). Note that there are validations regarding the default index when removing a record, see below.

    Set default

    On the index record there is a checkmark that determines if this index is the default index. The first created record will automaticaly be set as the default.

    The default index record cannot be removed if there are other index records remaining; a different record will need to be marked as the default first with this 'Set default' button. The default index record can only be removed if it is the only record.

    Manage

    This button gives the option to either update the scheme of the index (any additions in the set up get added to the index fields, no data is lost) or to (re)create the index. The (re)create option should be used when first creating the index and afterwards when a recreate is needed/advisable (if for example fields were removed from the setup, the only way to also remove the field from the index is by recreating it.) Note that with this option the index and its all data gets deleted before the index itself is then recreated, so all data is lost untill the data is updated again as well (with the Update search data job).

    Validate

    Gives the option to either validate the Search service or the Search index.

    For the Search service it checks if the connection can be made succesfully based on the given service name and credentials. Note that the connection may also fail when the Azure service itself has disruptions.

    For the Search index it checks if the selected index exists and is complete (scheme) in the Azure portal.

    Advanced setup 

    The layout, filter and sorting definitions that have been published can be checked here, together with the used JSON. These options are mostly used for troubleshooting purposes.

     

    Companies

    Use the +Add button to add a record and select the Company that will use this Search configuration. Repeat this step if multiple companies will be using it. Note that a Company can only be linked to 1 Search configuration at a time.

    The first record created will automatically be marked as the default but this can be altered if needed. Note that the default company record cannot be removed if there are more records remaining; a different record will need to be marked as the default first with the 'Set default' button. The default company record can only be removed if it is the only record.

     

    Category hierarchies

    Note that Category hierarchies need to have been associated with the Product search type role before they can be selected as part of a Search configuration. Visit the Category hierarchy role association paragraph for more information on how to do this.

    Use the +Add button to add a record and select the Category hierarchy that is part of this Search configuration. Repeat this step if multiple hierarchies will be used. Note that a Category hierarchy can be linked to multiple Search configurations at the same time (with its own setup on the hierarchy per Search configuration).

    The first record created will automatically be marked as the default but this can be altered if needed. Note that the default Category hierarchy record cannot be removed if there are more records remaining; a different record will need to be marked as the default first with the 'Set default' button. The default Categroy hierarchy record can only be removed if it is the only record remaining.

    Once a Category hierarchy has been added, it can be opened to add the Search specific setup. This can only be done by opening the Category hierarchy from the Search configuration, as it's the only way the Search specific tabs will be shown. Opening the hierarchy from other locations will only show the standard tabs. The hierarchy can be opened from the search configuration by clicking on the hierarchy name, or by selecting the record and clicking the Configure search hierarchy button on the line menu. More information on the setup can be found in the Category hierarchy search configuration topic.

     

    Search configuration index fields

    The Search configuration index fields tab shows all fields that are part of the Azure index, giving you additional information and the option to set the Field label that is to be used when displaying the field in the Search form.

    The following functions are available:

    Button Description
    Remove Removes the selected record(s). This is usefull when fields have been removed from the setup and (as a consequence) from the index. A deleted index field cannot sync its deletion to D365 as it simply no longer exists, so these records can be removed manually in D365 with this button.   
    Sync Azure fields Synchronizes the fields found in Azure for the default index to this overview. 
    Language: (xx) Shows which language is currently being displayed and offers the option to switch to the other available languages.
    Filter Search field to be able to easily search/find a specific field in the overview.

     

    The following fields are available, note that most are for information purposes only, the label fields are the only exceptions: 

    Field Description
    Translations complete When all translations are complete for this field, a green check mark is shown. If translations are missing in one or more languages, a warning sign is shown.
    Field exists When the field exists in the Azure index, a green check mark is shown. If the field does not exist (anymore), a warning sign is shown. (Fields can dissapear from the index due to changes in the setup, if that is the case (and a sync has been performed), these are the fields that can be removed from this overview.) 
    Name Name of the field (in D365).
    Azure search field Name of the field in the Azure Search Index. 
    Field label The label to be used when displaying this field. This field is editable.
    Short field label Shortened label to be used when displaying this field in places with little room. This field is editable.
    Type Shows the field type of the field in the Azure Search Index.
    Is array Shows if the field in the Azure Search Index is an array.
    Retrievable Shows if the field in the Azure Search Index is retrievable, in which case it can be used in the Search layout.
    Searchable Shows if the field in the Azure Search Index is searchable, in which case Text searches can be performed on this infomation.
    Filterable Shows if the field in the Azure Search Index is filterable, in which the field can be used as a Search filter.
    Sortable Shows if the field in the Azure Search Index is sortable, in which case the field can be used as a Sorting order within Search.

     

    Highlight fields

    By adding index fields here, any matches found based on a text search within those fields will be highlighted on the result card.

    This makes it easy to identify how the match was made.

     

     

    Configuration parameters

    There are multiple parameters available for a search configuration; they control both functional and technical aspects of the search functionality. Note that there is an option to reset these parameters to their default settings; we recommend to use these default settings especially for the 'Execution' and 'Upload' groups when first setting up Search and to only adjust those if needed. More information on how these settings affect the update process can be found here.

    Search text
    Use advanced syntax

    Defines the default setting for this option on the Search form:

    No: The advanced syntax option is never used and the setting is not available to the user.

    User defined (default No): The advanced syntax option is not used by default, but the setting is available to the user to be changed.

    User defined (default Yes): The advanced syntax option is used by default, but the setting is available to the user to be changed.

    Yes: The advanced syntax option is always used and the setting is not available to the user.   

    Match all words

    Defines the default setting for this option on the Search form:

    No: The match all words option is never used and the setting is not available to the user.

    User defined (default No): The match all words option is not used by default, but the setting is available to the user to be changed.

    User defined (default Yes): The match all words option is used by default, but the setting is available to the user to be changed.

    Yes: The match all words option is always used and the setting is not available to the user.  

    Auto-wildcards

    Defines the default setting for this option on the Search form:

    No: The auto-wildcards option is never used and the setting is not available to the user.

    User defined (default No): The auto-wildcards option is not used by default, but the setting is available to the user to be changed.

    User defined (default Yes): The  auto-wildcards option is used by default, but the setting is available to the user to be changed.

    Yes: The  auto-wildcards option is always used and the setting is not available to the user.  

    Filters
    Expand automatically

    Defines the default setting for this option on the Search form:

    No: The expand automatically option is never used and the setting is not available to the user.

    User defined (default No): The expand automatically option is not used by default, but the setting is available to the user to be changed.

    User defined (default Yes): The  expand automatically is used by default, but the setting is available to the user to be changed.

    Yes: The expand automatically option is always used and the setting is not available to the user. 

    Filtering mode Sets the default filtering mode when a new filter record is set up that is linked to a multi-value attribute.
    Values sorting Determines how the values within a filter are sorted, either alphabetically or by record count (highest first). 
    Fetched values

    Defines the maximum number of unique values that will be fetched from Azure Search to display for a filter. Increasing this count from the default 1500 may result in slower performance.

    Please note that when no value is entered (0) a maximum of 10 filter values are fetched.

    More button threshold If a filter has more values than the number specified here, a 'more' button will be displayed to display them 
    Search-as-you-type
    Fuzzy When activated, fuzzy method is used when fetching suggestions during a text search. This allows suggestions to be made on near matches, allowing for spelling differences and typo's for example.
    Categories
    Num. of categories with count

    Defines the maximum number of categories that are displayed with a record count. When multiple hierarchies are being used (in Search) this count probably needs to be increased from the default 1500. Increasing this count may result in slower performance.

    Please note that when no value si entered (0) a maximum of 10 category record counts is fetched. As this number can be fetched from across all hierarchies, this may result in not showing any counts at all on a selected hierarchy.

    Use friendly name When activated, the tree uses the friendly names for the category names on the Search form.  
    Data update dialog
    Show 'Execution' and 'Upload' When activated, the execution and upload parameter groups show on the 'Update search data' dialog, making it possible to adjust these settings from their defaults specified here for a specific run.
    Execution
    Clean up tasks When activated, tasks of the Update search data job get deleted once ended.
    Show debug info When activated, a log is created when running the Update search data job to assist with debugging.
    Upload jobs Defines how many upload jobs can run in parallel as part of the Update search data job.
    Generator jobs Defines how many generator jobs can run in parallel as part of the Update search data job.
    Wait time The time (in seconds) the batch task waits to check for a new task.
    Max. wait time The maximum time (in seconds) the batch task waits for a new task.
    Upload
    Max. documents The maximum number of records to be uploaded to Azure per single batch. The total number of records will be split into multiple batches with this number as the maximum amount per batch.
    Max. num of retries The maximum amount of times an upload gets retried in case of failures.
    Retry wait time The time (in seconds) before retrying an upload.

     

    Search configuration ribbon

    Apart from the standard Edit, New and Delete buttons (with which Search configurations can be created, edited and deleted) and the Microsoft standard Options , the ribbon also contains buttons for the following functions:  

    Update search data

    This button opens the dialog to start the Update search data batch job. A detailed description of the available options on the dialog can be found here.

    Data update batches

    This button opens a form showing all the Data update batches related to the Search configuration. More detailed information on the Data update batches form can be found here.

    Publish definitions

    This button opens a dialog to publish the definitions of the Search form. This job creates the layout, filter and sorting definitions that determine what the Search form displays.  

    Note that if no (layout) setup has been made and/or published, a (very) basic fall-back layout is used.