ODBC connection and IP address

245 pts.
Tags:
AS/400
CL Program
IP address
ODBC
Is there a way to get the IP address of a client/server job attached to QZDASOINIT?  I can see message CPIAD02 in the QZDASOINIT job log which lists the user and IP address and I need to get this information into a CL program which runs each time the user connects to the QZDASOINIT process. 

Thanks ,

Bisht   



Software/Hardware used:
AS/400
ASKED: March 6, 2011  11:42 AM
UPDATED: March 8, 2011  1:12 AM

Answer Wiki

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

1. Obtain the ip from the joblog via DSPJOBLOG *PRINT or from the history log DSPLOG OUTPUT(*PRINT) JOB(JOBNUM/JOBUSER/JOBNAME) MSGID(CPIAD09)
2. Take the splf and copy to physical file CPYSPLF
3. Your CL can now read the file and substring the IP info

Discuss This Question: 2  Replies

 
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
  • TomLiotta
    If your program is called during QZDASOINIT, then you should be able to retrieve the IP address by calling the Retrieve Job Information (QUSRJOBI) API with format JOBI0600. The client IP address is at offset 307. That's only a partial solution because it covers only IPv4 addresses. For IPv6 or for combinations of IPv4 and IPv6, you'll want to do some studying of how the Work Management APIs work overall. It can get complicated quickly. Tom
    125,585 pointsBadges:
    report
  • BISHT321
    [...] See more here:  ODBC connection and IP address [...]
    0 pointsBadges:
    report

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