small doubt

0 pts.
Tags:
Backup & recovery
DB2
Hardware
i5
iSeries
OS/400
Security
tips and tricks
Tools
UDB for iSeries/i5
Hi, I have a small doubt in AS400 programming. This is regarding receiving journal entries. I am using ILE C to write the exit program. I am using RJNE0200 format on the RCVJRNE command. I am getting the entries in the exit program. But I have a few questions: - in the RJNE0200 format, there are data types for fields like BINARY(8) UNSIGNED. Now if i want to store the entries in my own DB2 table, what is the corresponding data type I need to use? Right now I am using BIGINT, but how to specify unsigned BIGINT? - in the RJNE0200 format, the timestamp is unformatted BINARY(8) UNSIGNED format. How do I get date and time out of this? I mean, are there any APIs which can be used to deal with unformatted BINARY(8) UNSIGNED timestamp? I want to do this in ILE C. - also I get garbage or just null in the remote address field but at the same time I get a valid value in the remote port field as well as in the address family field. I am getting valid values in all the fields except remote address and journal identifier fields. Any clues? Thanks in advance, P.Prasad
ASKED: July 18, 2005  7:26 AM
UPDATED: July 18, 2005  3:03 PM

Answer Wiki

Thanks. We'll let you know when a new response is added.

For unsigned BIGINT items, I’d probably use a CHAR(8) column in my tables. There’s nothing that can be done by DB2 for these values; all must be done by programs, so the database doesn’t need to know anything about the contents.

I don’t know the date format for those journal entries. My first guess would be that they are system date/timestamp fields since they’re 8-bytes in length. I would first try the Convert Date and Time Format (QWCCVTDT) API to see if they converted with an input type of *DTS. Again, store them as CHAR(8) in any tables. The numeric values are essentially meaningless; treat them as binary (or hex) values.

If I saw values for remote address that weren’t meaningful, I’d first check the value in the Address family (JOADF) field in the returned entry. What value do you get in that field?

Tom

Discuss This Question:  

 
There was an error processing your information. Please try again later.
Thanks. We'll let you know when a new response is added.
Send me notifications when members answer or reply to this question.

REGISTER or login:

Forgot Password?
By submitting you agree to receive email from TechTarget and its partners. If you reside outside of the United States, you consent to having your personal data transferred to and processed in the United States. Privacy

Forgot Password

No problem! Submit your e-mail address below. We'll send you an e-mail containing your password.

Your password has been sent to:

To follow this tag...

There was an error processing your information. Please try again later.

REGISTER or login:

Forgot Password?
By submitting you agree to receive email from TechTarget and its partners. If you reside outside of the United States, you consent to having your personal data transferred to and processed in the United States. Privacy

Thanks! We'll email you when relevant content is added and updated.

Following