× The internal search function is temporarily non-functional. The current search engine is no longer viable and we are researching alternatives.
As a stop gap measure, we are using Google's custom search engine service.
If you know of an easy to use, open source, search engine ... please contact support@midrange.com.




Hi Jeff, while it is neat to see that COBOL could handle this, I think I would get shot if I proposed involving COBOL in this new process.

I have done very limited maintenance on the few COBOL things we still have, so I don't think it would be an option. I do have the XML DB2 Extender information tested for composing, so that is the working choice right now, just wondering if there was anything else out there I was not aware of.

Thanks for your interest Jeff!


Sharon

From: jlcrosby@xxxxxxxxxxxxxxxx
To: rpg400-l@xxxxxxxxxxxx
Subject: RE: Composing XML and RPG
Date: Wed, 19 Nov 2008 16:54:25 -0500

I haven't looked at COBOL since college, 30 years ago, and remember
virtually nothing about it. This excited me enough that I installed the
COBOL compiler and ran it. It works.

If I would want to use it, I need to figure out CCSID though as WRKLNK read
the XML file OK, but Windows, via explorer, saw gibberish.

Thanks for this Peter.

--
Jeff Crosby
UniPro FoodService/Dilgard
P.O. Box 13369
Ft. Wayne, IN 46868-3369
260-422-7531
www.dilgardfoods.com

The opinions expressed are my own and not necessarily the opinion of my
company. Unless I say so.

-----Original Message-----
From: rpg400-l-bounces@xxxxxxxxxxxx [mailto:rpg400-l-bounces@xxxxxxxxxxxx]
On
Behalf Of Peter Connell
Sent: Wednesday, November 19, 2008 2:08 PM
To: RPG programming on the AS400 / iSeries
Subject: RE: Composing XML and RPG

Sharon,
Given that IBM ships a COBOL compiler with the iSeries, this means that
it is available for specific ILE modules other than RPGLE just as you
might incorporate a CLP or C program.
Since RPGLE does provide built-in operations for generating XML, it is
not difficult to roll your own.
While RPGLE is great, you may be surprised to know that COBOL has also
entered the new age.

As the code below reveals, COBOL is a step ahead (at least in this
respect) since the compiler now provides for operations that generate
XML.
This code simply dumps the data structure for EmployeeRec to a stream
file.
I found the temptation to investigate this difficult to resist.
To prove it just paste this into a source member in a QCBLLESRC file and
run PDM option 14.
However, it would take a little more COBOL skill to determine if this
could effectively be integrated as a procedure to be called from RPGLE.

PROCESS OPTIONS.
IDENTIFICATION DIVISION.
PROGRAM-ID. VERIFY.
AUTHOR. PROGRAMMER NAME.
INSTALLATION. VEDAADVANTAGE.
DATE-WRITTEN. SEPTEMBER 10, 2008.
DATE-COMPILED.
ENVIRONMENT DIVISION.
CONFIGURATION SECTION.
SOURCE-COMPUTER. IBM-AS400.
OBJECT-COMPUTER. IBM-AS400.
DATA DIVISION.
WORKING-STORAGE SECTION.
01 EmployeeRec.
03 Name pic X(25).
03 MailAddress.
05 Street pic X(20).
05 City pic X(12).
05 State pic X(2).
03 Personal.
05 MaritalStatus pic X.
05 BirthDate pic X(8).
01 XMLMsg pic X(1000).
01 IFSFile pic x(50) value "/tmp/SomeIFSFile.xml"
PROCEDURE DIVISION.
POPULATE-EmployeeRec.
MOVE 'John Doe' TO Name.
MOVE '5th Avenue' TO Street.
MOVE 'Manhattan' TO City.
MOVE 'NY' TO State.
MOVE 'Y' TO MaritalStatus.
MOVE '19651231' TO BirthDate.

XML GENERATE FILE-STREAM IFSFile
FROM EmployeeRec
END-XML.
STOP RUN.


Cheers, Peter


-----Original Message-----
From: rpg400-l-bounces@xxxxxxxxxxxx
[mailto:rpg400-l-bounces@xxxxxxxxxxxx] On Behalf Of Sharon
Sent: Thursday, 20 November 2008 2:25 a.m.
To: rpg400-l@xxxxxxxxxxxx
Subject: Composing XML and RPG


Good morning all,



I have been working on how to decompose xml onto our ISeries for a
couple weeks now, the two XML opcodes have saved the day.



I am just wondering about the other side of the spectrum, composing XML
documents. I have learned how to use the DB2 XML Extender, is that the
preferable way to compose an XML document today? Are there any new
features in the same realm as these new opcodes for composing?



Thanks in advance,



Sharon
_________________________________________________________________
Windows Live Hotmail now works up to 70% faster.
http://windowslive.com/Explore/Hotmail?ocid=TXT_TAGLM_WL_hotmail_acq_fas
ter_112008
--
This is the RPG programming on the AS400 / iSeries (RPG400-L) mailing
list To post a message email: RPG400-L@xxxxxxxxxxxx To subscribe,
unsubscribe, or change list options,
visit: http://lists.midrange.com/mailman/listinfo/rpg400-l
or email: RPG400-L-request@xxxxxxxxxxxx
Before posting, please take a moment to review the archives at
http://archive.midrange.com/rpg400-l.


############################################################################
#
########
This correspondence is for the named person's use only. It may contain
confidential or legally privileged information, or both. No
confidentiality
or privilege is waived or lost by any mistransmission. If you receive this
correspondence in error, please immediately delete it from your system and
notify the sender. You must not disclose, copy or rely on any part of this
correspondence if you are not the intended recipient. Any views expressed
in
this message are those of the individual sender, except where the sender
expressly, and with authority, states them to be the views of Veda
Advantage.
If you need assistance, please contact Veda Advantage on either :-
Australia
133124 or New Zealand +64 9 367 6200
--
This is the RPG programming on the AS400 / iSeries (RPG400-L) mailing list
To post a message email: RPG400-L@xxxxxxxxxxxx
To subscribe, unsubscribe, or change list options,
visit: http://lists.midrange.com/mailman/listinfo/rpg400-l
or email: RPG400-L-request@xxxxxxxxxxxx
Before posting, please take a moment to review the archives
at http://archive.midrange.com/rpg400-l.



--
This is the RPG programming on the AS400 / iSeries (RPG400-L) mailing list
To post a message email: RPG400-L@xxxxxxxxxxxx
To subscribe, unsubscribe, or change list options,
visit: http://lists.midrange.com/mailman/listinfo/rpg400-l
or email: RPG400-L-request@xxxxxxxxxxxx
Before posting, please take a moment to review the archives
at http://archive.midrange.com/rpg400-l.


_________________________________________________________________
Get more done, have more fun, and stay more connected with Windows Mobile®.
http://clk.atdmt.com/MRT/go/119642556/direct/01/

As an Amazon Associate we earn from qualifying purchases.

This thread ...

Follow-Ups:
Replies:

Follow On AppleNews
Return to Archive home page | Return to MIDRANGE.COM home page

This mailing list archive is Copyright 1997-2024 by midrange.com and David Gibbs as a compilation work. Use of the archive is restricted to research of a business or technical nature. Any other uses are prohibited. Full details are available on our policy page. If you have questions about this, please contact [javascript protected email address].

Operating expenses for this site are earned using the Amazon Associate program and Google Adsense.