InBox DynamicFieldSelectDB

Version 6.3.9

Date of criation 02/07/2019


Create SelectDB dynamic field

This module makes it possible to create dynamic fields of the SelectDB type, which allows a connection to several databases.



The following versions of the OTRS framework are supported:

  • 6.x.x


The following modules are required:

  • InBox Core 6.22.7 or superior

Operational system

The following operating systems are required:

  • ODBC connection module of the desired bank.

Third Party Software

The following third party software is required:

  • [None]


bin/ Admin::Package::Install /path/to/InBox\ DynamicFieldSelectDB-6.3.9.opm


This module has no system settings, only the dynamic field configuration.


Dynamic field creation

After installing the module it will be possible to create dynamic fields of the SelectDB type, for that it is enough to go to Administration->Dynamic Fields and choose the SelectDB field, as in the image below:


When selecting the type of field to be added, it will present the field configuration screen:

In general configurations, it should be defined:

  • Field name (this name must be unique).
  • Field display name (text displayed to the user).
  • Field order (optional).
  • Shelf life.


Field Settings


In the field settings, the following must be defined:

  • Minimum query size (minimum size to start the query).
  • Maximum consultation result (number of results in consultation).
  • Standard Connection (If using the standard connection, it will connect to the local database, for remote database cases, select 'No' and the fields for configuration will be displayed)
  • Bank DSN (Specify the DSN for the database used. Example: DBI: mysql: database = otrs; host = localhost).
  • Bank user.
  • Bank password (optional).
  • Bank type (mssql, mysql, oracle and postgresql).
  • Bank table (table where the query will be made).
  • Identification key (unique query identifier).
  • Table columns (columns that will be returned in the query).
  • Search by (field of the table that will be used in the search).
  • SELECT AND search (table column and dynamic field to perform an AND search).
  • Cache stay time.
  • Possible Cache Values.
  • Maximum quantity (maximum number of entries available).
  • Default value (optional).

You will need to add "Table columns" for the field to work correctly by mapping the table columns.


You will only need to add the key.


This value can be the same identification key if you don't have one.


If you want to use the functionality of adding column values in dynamic fields, the settings are not necessary.

The important thing is to have at least one key (column) configured in the Table columns option.

O campo irá realizar a consulta ao banco configurado com a condição ... WHERE = DatabaseFieldSearch. É possível adicionar uma outra condição AND no campo abaixo. Basta informar o nome da tabela e o campo dinâmico que irá conter o valor.

OBS: O campo dinâmico configurado deverá aparecer na mesma tela em que o campo SelectDB estiver.


Caso seja necessário adicionar um trecho SQL, basta usar o campo abaixo. O trecho SQL será adicionado após o WHERE e antes do ORDER BY. Para utilizar valores de campo dinâmico em tela, adicione a TAG <DynamicField_name> no campo



Use of the field

With the field, configured on the desired screens. The field is a text box, which allows the user to search for terms, already pre-established, in the field configuration step. So the user can search for what he wants, and he will display what was found according to the search performed:


If the mapping of select values in other dynamic fields is configured, when selecting a value, it will automatically set value to the configured fields.

If the AND search is configured, the field will bring values based on another dynamic field already filled in.