ASG
IBM
Zystems
Cressida
Icon
Netflexity
 
  MQSeries.net
Search  Search       Tech Exchange      Education      Certifications      Library      Info Center      SupportPacs      LinkedIn  Search  Search                                                                   FAQ  FAQ   Usergroups  Usergroups
 
Register  ::  Log in Log in to check your private messages
 
RSS Feed - WebSphere MQ Support RSS Feed - Message Broker Support

MQSeries.net Forum Index » WebSphere Message Broker (ACE) Support » Store and Log COBOL in Oracle DB

Post new topic  Reply to topic
 Store and Log COBOL in Oracle DB « View previous topic :: View next topic » 
Author Message
EricCox
PostPosted: Mon Jul 08, 2013 5:53 am    Post subject: Store and Log COBOL in Oracle DB Reply with quote

Master

Joined: 08 Apr 2011
Posts: 292

To all,

We are currently logging request and response XML to an Oracle XMLType column. That is working nicely.

We have a new requirement to log COBOL request and response messages to Oracle.

What Oracle column datatype is the best to house the COBOL messages? And is there any example/sample snipet of how to handle that in the ESQL as we commit the data to the db via Stored Procedure?

We are on:
Oracle Database 11g Enterprise Edition Release 11.1.0.7.0 - 64bit Production
PL/SQL Release 11.1.0.7.0 - Production
"CORE 11.1.0.7.0 Production"
TNS for IBM/AIX RISC System/6000: Version 11.1.0.7.0 - Production
NLSRTL Version 11.1.0.7.0 - Production

Thanks very much as always,
EMC
Back to top
View user's profile Send private message
lancelotlinc
PostPosted: Mon Jul 08, 2013 6:02 am    Post subject: Reply with quote

Jedi Knight

Joined: 22 Mar 2010
Posts: 4941
Location: Bloomington, IL USA

What WMB version?
_________________
http://leanpub.com/IIB_Tips_and_Tricks
Save $20: Coupon Code: MQSERIES_READER
Back to top
View user's profile Send private message Send e-mail
EricCox
PostPosted: Mon Jul 08, 2013 6:06 am    Post subject: WMB Version Reply with quote

Master

Joined: 08 Apr 2011
Posts: 292

Our version is WMB 6.0.0.9...no laughing.

We will be on WMB 8.0.0.2 by early 2014.

This might be developed in WMB 6.0.0.9 and the ported shortly to 8.0.0.2.

Thanks,
Eric
Back to top
View user's profile Send private message
lancelotlinc
PostPosted: Mon Jul 08, 2013 6:19 am    Post subject: Reply with quote

Jedi Knight

Joined: 22 Mar 2010
Posts: 4941
Location: Bloomington, IL USA

If you're asking for design recommendations, I would create an XML XSD that describes the COBOL structure, and store the XML payload of this COBOL structure in a CLOB.
_________________
http://leanpub.com/IIB_Tips_and_Tricks
Save $20: Coupon Code: MQSERIES_READER
Back to top
View user's profile Send private message Send e-mail
kimbert
PostPosted: Mon Jul 08, 2013 6:34 am    Post subject: Reply with quote

Jedi Council

Joined: 29 Jul 2003
Posts: 5542
Location: Southampton

Quote:
What Oracle column datatype is the best to house the COBOL messages?
One that can hold the type of data in the COBOL messages...
lancelotinc said:
Quote:
I would create an XML XSD that describes the COBOL structure, and store the XML payload of this COBOL structure in a CLOB
That would be a bad idea if the COBOL data contained ( or might ever contain ) packed decimals, binary integers or other non-text data.
Quote:
And is there any example/sample snipet of how to handle that in the ESQL as we commit the data to the db via Stored Procedure?
It depends entirely on what you want to do with the COBOL data before storing it. If anything.
Back to top
View user's profile Send private message
lancelotlinc
PostPosted: Mon Jul 08, 2013 6:37 am    Post subject: Reply with quote

Jedi Knight

Joined: 22 Mar 2010
Posts: 4941
Location: Bloomington, IL USA

kimbert wrote:
Quote:
What Oracle column datatype is the best to house the COBOL messages?
One that can hold the type of data in the COBOL messages...
lancelotinc said:
Quote:
I would create an XML XSD that describes the COBOL structure, and store the XML payload of this COBOL structure in a CLOB
That would be a bad idea if the COBOL data contained ( or might ever contain ) packed decimals, binary integers or other non-text data.
Quote:
And is there any example/sample snipet of how to handle that in the ESQL as we commit the data to the db via Stored Procedure?
It depends entirely on what you want to do with the COBOL data before storing it. If anything.


As a point of clarification, the message flow that transforms the data into the XML payload is responsible for encoding-decoding any data. XML data is easier to read by dashboard programs rather than requiring the dashboard programs to encode-decode the data. The ESB is a great place to transform payload from one format to another.
_________________
http://leanpub.com/IIB_Tips_and_Tricks
Save $20: Coupon Code: MQSERIES_READER
Back to top
View user's profile Send private message Send e-mail
EricCox
PostPosted: Mon Jul 08, 2013 6:42 am    Post subject: COBOL message Reply with quote

Master

Joined: 08 Apr 2011
Posts: 292

The requirement is to store the native COBOL message in a column. We will decorate the row with key fields for searching and finding specific rows.
Back to top
View user's profile Send private message
lancelotlinc
PostPosted: Mon Jul 08, 2013 6:47 am    Post subject: Re: COBOL message Reply with quote

Jedi Knight

Joined: 22 Mar 2010
Posts: 4941
Location: Bloomington, IL USA

EricCox wrote:
The requirement is to store the native COBOL message in a column. We will decorate the row with key fields for searching and finding specific rows.


The downside to this approach is that it requires the dashboard programs to be aware of your decorations and formats.

XML self-describes fields and therefore is very portable. Custom decorated fields are not portable.
_________________
http://leanpub.com/IIB_Tips_and_Tricks
Save $20: Coupon Code: MQSERIES_READER
Back to top
View user's profile Send private message Send e-mail
EricCox
PostPosted: Mon Jul 08, 2013 6:50 am    Post subject: COBOL Field Values Stored Reply with quote

Master

Joined: 08 Apr 2011
Posts: 292

We will interogate the COBOL for fields to be used as keys to find related rows.

What is the best column datatype in Oracle to store COBOL? Yes, the COBOL is expected to hold PIC S9 type data.
Back to top
View user's profile Send private message
EricCox
PostPosted: Mon Jul 08, 2013 6:57 am    Post subject: Dashboard Reply with quote

Master

Joined: 08 Apr 2011
Posts: 292

The dashboard program will just need to query the Oracle db to find the row(s). With the row(s) identified the dashboard will then need to select the data out of the CLOB or BLOB column to grab the entire original COBOL message from the column, save it to a file and merge it with the Copybook to inspect it and perform analysis.
Back to top
View user's profile Send private message
fjb_saper
PostPosted: Mon Jul 08, 2013 8:49 pm    Post subject: Re: Dashboard Reply with quote

Grand High Poobah

Joined: 18 Nov 2003
Posts: 20756
Location: LI,NY

EricCox wrote:
The dashboard program will just need to query the Oracle db to find the row(s). With the row(s) identified the dashboard will then need to select the data out of the CLOB or BLOB column to grab the entire original COBOL message from the column, save it to a file and merge it with the Copybook to inspect it and perform analysis.


There are some assumptions here:
  • you will never have to search the blob or clob
  • you will always save ccsid and encoding with the blob/clob
  • The broker will evaluate and save the colums uses for searching
Should be doable.
The challenge here is the definition of the searcheable columns (defining the data in the blob/clob).

if the cobol is all text (pic S9(x) can be assimilated to text) I would nearly suggest that you add the XML format to your message set and save the content as XML...

Have fun
_________________
MQ & Broker admin
Back to top
View user's profile Send private message Send e-mail
Display posts from previous:   
Post new topic  Reply to topic Page 1 of 1

MQSeries.net Forum Index » WebSphere Message Broker (ACE) Support » Store and Log COBOL in Oracle DB
Jump to:  



You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum
Protected by Anti-Spam ACP
 
 


Theme by Dustin Baccetti
Powered by phpBB © 2001, 2002 phpBB Group

Copyright © MQSeries.net. All rights reserved.