Portal publish error: VariablesService.VariablesResolveAll: Variables resolve all method failed.

Document ID : KB000016257
Last Modified Date : 14/02/2018
Show Technical Document Details
Introduction:

This question covers a publishing difference between Datamaker and the TDM Portal. In this case, the behaviour of the Portal is correct. Variables are always evaluated before data publishing begins.

Question:

There are two scenarios I have seen when using variables in the TDM Portal that causes my publishing job to fail.

1) When I publish a job that is using variables in the Self Service flow or Generator.

2) If I change a variable in the Self Service Catalog.

 

When I take a look at the log files,  I see the following error in the Portal.

2017-10-13 21:09:50.471 UTC [ERROR] [http-nio-8443-exec-5 ] --- [U:][M:][P:] c.c.t.s.TDMServiceException: TDMServiceException: RequestID: 168, Module: TDMSERVICE, Exception: ifnull: evalColRef: No data source for column reference: MyColumn

2017-10-13 21:09:50.471 UTC [ERROR] [http-nio-8443-exec-5 ] --- [U:][M:][P:] c.c.t.s.TDMServiceException: TDMServiceException: RequestID: 168, Module: TDMSERVICE, Exception: resolve_meta_data_item: TDMServiceException: ifnull: evalColRef: No data source for column reference: MyColumn 

2017-10-13 21:09:50.471 UTC [ERROR] [http-nio-8443-exec-5 ] --- [U:][M:][P:] c.c.t.s.e.i.VariablesService: VariablesResolveAll[Ljava.lang.StackTraceElement;@70ee2238 

2017-10-13 21:09:50.471 UTC [ERROR] [http-nio-8443-exec-5 ] --- [U:][M:][P:] c.c.t.s.TDMServiceException: TDMServiceException: RequestID: 168, Module: TDMSERVICE, Exception: VariablesService.VariablesResolveAll: Variables resolve all method failed.

 

I only see this problem in the TDM Portal,  but I don't have this problem in Datamaker.  What is the issue?

Environment:
CA Test Data Manager (TDM)- Datamaker and Portal
Answer:

For this issue,  the problem was that one of the variables that was being published has a column reference ^MyColumn^ in the variable.

MyVar = @string(@ifnull(@execsql(P~DataSource~,select name  from person where address  in (^City^))@,"unknown")@

In this case, this variable is referencing a column value of City which will not work in the portal, since there will be no reference to the column of 'City' when the variable is evaluated before the publish of the generator or self service flow.

Although this worked in DataMaker, it will not work in the Portal since variables are evaluated before the publish of a generator or flow. 

 

You will notice if you open Data Painter from a variable, you will not be able to select ^column^ references in the Data Painter form. If you encounter a similar situation where your ^column^ reference is not available, please check your Data Painter form of your expression to determine if the references in your expression are available and if it will validate.