Forum
Keyword
× Discuss about Archiving, Close of Business, Delivery Setup, Security Management System, Global Processing etc…

Unix script to execute OFS strings

  • simoys
  • simoys's Avatar Topic Author
  • Offline
  • New Member
  • New Member
  • Posts: 1
  • Thank you received: 0

simoys created the topic: Unix script to execute OFS strings

Hi All,

I have a requirement where a file contains over 1000 OFS strings. A shell script is to be written to read the file and execute the OFS strings. Any idea how this can be achieved? I know this can be done through a service routine but want to understand how is it done using a script. The release using is R14 TAFC. Thanks in Advance.
#21630

Please Log in or Create an account to join the conversation.

  • VK
  • VK's Avatar
  • Offline
  • Platinum Member
  • Platinum Member
  • R13|TAFC|jBASE|windoze
  • Posts: 541
  • Karma: 9
  • Thank you received: 78

VK replied the topic: Unix script to execute OFS strings

Hi
It's not a problem to transform incoming text file to OFS format but how you're going to submit it?
To use more convenient ways - OFS.BULK.MANAGER or OFS.POST.MESSAGE - you need jBC code.

If you just transform the text to OFS using a shell script then you can use batch file listener to post OFS messages. This looks the best way in your case...

Cheers
VK
#21632

Please Log in or Create an account to join the conversation.

  • Posts: 28
  • Karma: -5
  • Thank you received: 0

tester111 replied the topic: Unix script to execute OFS strings

any code refernce on how to execute bulk ofs?
#21687

Please Log in or Create an account to join the conversation.

  • VK
  • VK's Avatar
  • Offline
  • Platinum Member
  • Platinum Member
  • R13|TAFC|jBASE|windoze
  • Posts: 541
  • Karma: 9
  • Thank you received: 78

VK replied the topic: Unix script to execute OFS strings

Hi
Not sure this will work on your release but you can try something like:

(ofs_msg1 and ofs_msg2 are variables where your OFS messages are to be put)
ofs_msg_all = '<requests><request>' : ofs_msg1 : '</request><request>' : ofs_msg2 : '</request></requests>'
commit_successful = 1
CALL OFS.BULK.MANAGER(ofs_msg_all, ofs_output, commit_successful)
IF NOT(commit_successful) THEN ... raise the error

Cheers
VK
#21689

Please Log in or Create an account to join the conversation.

Time to create page: 0.114 seconds