Eiko Willemsen

Use of substitution variables in configstring DataReference

Discussion created by Eiko Willemsen on Jul 12, 2013
Latest reply on Jul 15, 2013 by Eiko Willemsen

Hello,

 

We use a datareference to get data from a WCF service.

 

For modifying the configurationstring we use a custom form that contains a filtering mechanism to finally select one or more rows from a collection.

 

When the configuration form is loaded this collection is filled from a WCF service. The adress of the WCF service is configured in an AF element at a static address. (\\SEVER\DB\\SytemOptions\WebService)

 

To retreive this address we now use the default PISystem to connect to AF and get the address. Now our problem is: The client is used to connect to The TEST, ACCEPTANCE and PRODUCTION environment. When the default Server is PRODUCTION but we are connected to the TEST environment, the datareference will get the address from the default (PRODUCTION) database and filles the collection with data of the PRODUCTION environment.

 

ofcourse we could fill the servername as part of the configuration string but we want the configurationstring to be independent of the connected server because we want to be able to export the elementes from ACCEPTANCE to PRODUCTION without having to modify all configurationsstrings of the datareferences. 

 

My question is:

 

Is there a way to configure a variable (eg %SERVER%) in the config string that is translated to the Server that is connected and not to the default Server? This way we could always fill the collection of the form with the data from the webservice of the connected environment.

 

If this is not possible, is there another way to retreive the connected server or database while we use the form for editing the configurationstring?

 

Regards,  Jeroen Gelderman

Outcomes