Dynamic Services

The dynamic services give you the opportunity to embed from a program code generated SQL in the SQL script. The generated SQL can depend on several parameters. If you want to program a dynamic services yourself, you need skills in C#. You can find more to this topic within the article "Implementation Dynamic Services". Below the usage and specific services are introduced.

Usage

The dynamic services are opened inside of three curly braces. In these curly braces is the name of the service including the namespace (Innosoft.CRM.Core.Service.DynamicObjectsService.DynamicObjects) written. To call the default function, you need to add a question mark (?) behind the services and the parameters that you want to pass to the function (e.g..: Innosoft.CRM.Core.Service.DynamicObjectsService.DynamicObjects.MachineService?Where). To call another function, you need to add a vertical stroke (|) and the name of the function. The parameters are now passed as in the standard function (e.g.: Innosoft.CRM.Core.Service.DynamicObjectsService.DynamicObjects.GeomapService|GetWhereClause). Functions can possibly be called without parameters.

Diverse Services

The following sections present frequently used services.

LanguageTableService

The LanguageTableService implements variables, fields and tables that depend on the user language from the views into the SQL. More on the translation concept can be found in the article "IsRowId". For example, if you want to use or link a table whose columns are partly language-dependent, you can use the standard function of this service. As a parameter you need to enter the table name.

Example:

For the table ADRTYP there are views that translate the column with the name (ADRTYP). If the English-speaking user opens the search, the function returns "ADRTYP_1" while the function returns for a German-speaking user the function "ADRTYP".

DateService

The DateService adds specific date values (correct formatted) into the SQL. The standard function returns the present date with time. You can specify the type of formatting as a parameter. The service also contains the function GetStartOfCurrentYear that returns the first day of the year. For this function you can also specify the type of formatting as a parameter.