Custom Plugin using Custom Java Functions to access to a second table inside the function
search cancel

Custom Plugin using Custom Java Functions to access to a second table inside the function

book

Article ID: 260226

calendar_today

Updated On:

Products

CA Test Data Manager (Data Finder / Grid Tools)

Issue/Introduction

We are developing SEQLOV1 like functions. That is, and in our case, java functions that need to access an Oracle database table in order to have information for getting the masked data. Questions:

1) Is it possible just to access them using libraries like com.oracle.ojdbc8 from the custom function? 

2) If answer to "1" is yes? Which library would you really recommend for this?

3) If it's not possible, is it possible to access a second connection profile in the java function. If yes, how?

 

 

Environment

Release : 4.10

Resolution

The answer is, yes, it is possible - basically you can do anything in the custom function. You should use the same library as FDM is already using (ojdbc8-19.3.0.0.jar).

Warning: You should know that the masking function is called for each row to mask. It means that calling another table should be done in such a way that it effectively runs the first time and any subsequent calls to the method are to access the generated list (assuming the call to the other table will end up with a list created). If not implemented properly, the masking will be inefficient and slow. You do not want to query another table each time you update a row to mask.