Solved

Custom Data Provider alternative in latest TX version

  • 20 June 2023
  • 5 replies
  • 64 views

Hi everybody,

Our client uses a SOAP API from a supplier. While TX supports SOAP the extraction requires multiple steps and string manipulation. The complete process is:

  • For each table in the list of tables:
    • Call the first SOAP endpoint to retrieve the names of the fields in the table
    • Call the second SOAP endpoint to retrieve a page of data for the table
      • Split the data into individual rows by splitting the string on the ^ character
      • Split the rows into individual colums by splitting the string on the | character
      • Fetch until the number of rows returned is less than the page size
    • Move to next table

We created a custom data provider for the TX custom data connector. This works fine in TX 20.10, but is not supported in 6221, so we need to create an alternative. I’m aware that you can use RSD files for more advanced logic, but as far as I can see this doesn’t include an option to perform the string manipulation (splitting). For the time being, we’ve ported the logic to a Python script, but as this is external to TX it’s not a desirable solution.

What course of action do you suggest to implement this logic?

icon

Best answer by rory.smith 22 June 2023, 09:11

View original

5 replies

Userlevel 5
Badge +5

A RSD file can do string manipulation, there is a few functions that can manipulate what comes from a call. It will be a lot of work to set up though especially splitting out the whole result out into individual fields.

The option to use custom tables has not been applied yet, but it could be, it has been discussed internally. I think it is a bit in the future though.

If you can make a python script that generates a usable file, it could be a workaround for now.

A RSD file can do string manipulation, there is a few functions that can manipulate what comes from a call. It will be a lot of work to set up though especially splitting out the whole result out into individual fields.

I'd love to take a swing at this, even if it is a lot of work. Is there a comprehensive list of all the functions available for use in RSD files, besides the two tutorials?

And yes, a Python script is the next option as a workaround but not ideal since that's outside of TX. 

Userlevel 5
Badge +7

Hi @MorganHeijdemann ,

for CData Connectors if you click the ? in the CData connection window, you get linked to the relevant CData documentation page for the CData provider you are using. These have a heading ‘API Script Reference’ which contains all the calls you can do. There are some examples in the CData documentation to get you started.

Userlevel 5
Badge +5

Hi @MorganHeijdemann 

For reference I have the link to the ? guide in the REST tutorial as well.

 

Hi @MorganHeijdemann 

For reference I have the link to the ? guide in the REST tutorial as well.

 

Thanks, looks like I missed that. 

Reply