SYSPROC.ADMIN_COMMAND_DB2 (was Check tables not in RW mode)

Philip Sevetson

SYSPROC.ADMIN_COMMAND_DB2 (was Check tables not in RW mode)
Larry,

If you understand how to use that, you should consider giving a talk at the nearby regional UGs. I've spent several fruitless hours trying to make it divulge useful results.

-phil

From: Jardine, Lawrence J [mailto:[login to unmask email]
Sent: Friday, May 10, 2019 12:34 PM
To: [login to unmask email]
Subject: [DB2-L] - RE: Check tables not in RW mode

Another option is to issue the command via the SYSPROC.ADMIN_COMMAND_DB2 stored procedure.

Larry Jardine
Database Advisor
[1_Heart_Aetna_logo_reg_rgb_vio]



Proprietary
From: Boxwell, Roy <[login to unmask email]>
Sent: Friday, May 10, 2019 12:09 PM
To: [login to unmask email]
Subject: [EXTERNAL] [DB2-L] - RE: Check tables not in RW mode

**** External Email - Use Caution ****
Well, I use SSAR (soon not any more!) to cross memory access the DBET from an APF authorized load module. Dump the contents down to a little COBOL program that decodes it all and Bibs your uncle!
No need for complex REXX or pesky DISPLAY commands...
Roy Boxwell
SOFTWARE ENGINEERING GmbH and SEGUS Inc.
-Product Development-
Heinrichstrasse 83-85
40239 Düsseldorf/Germany
Tel. +49 (0)211 96149-675
Fax +49 (0)211 96149-32
Email: [login to unmask email]<mailto:[login to unmask email]>
http://www.seg.de https://urldefense.proofpoint.com/v2/url?u=http-3A__www.seg.de&d=DwMGaQ&c=wluqKIiwffOpZ6k5sqMWMBOn0vyYnlulRJmmvOXCFpM&r=wfE0VOZJYg9uIjc5BuTMYexNGrByDwh1giBA3sSm6qo&m=hUauOtEzc_FEgC2h2TrQ8zCb6W4EpeOsWq90IXvBHMM&s=2jQtJFiONCmFRu_kr6JDzMB8GjHTRYDjW1tPSV85FlE&e=
Link zur Datenschutzerklärung https://urldefense.proofpoint.com/v2/url?u=https-3A__www.seg.de_corporate_rechtliche-2Dhinweise_datenschutz_&d=DwMGaQ&c=wluqKIiwffOpZ6k5sqMWMBOn0vyYnlulRJmmvOXCFpM&r=wfE0VOZJYg9uIjc5BuTMYexNGrByDwh1giBA3sSm6qo&m=hUauOtEzc_FEgC2h2TrQ8zCb6W4EpeOsWq90IXvBHMM&s=iHw85kNRzlzQavJXa5CBFqZoXb1s4G-RMRh4BqZpd_M&e=

Software Engineering GmbH
Amtsgericht Düsseldorf, HRB 37894
Geschäftsführung: Gerhard Schubert, Ulf Heinrich

On 10 May 2019, at 15:37, Sevetson, Phil <[login to unmask email]<mailto:[login to unmask email]>> wrote:
:) Got it. Thanks. Signing off before the mods club me into submission...

From: Paul Ogborne [mailto:[login to unmask email]
Sent: Friday, May 10, 2019 9:31 AM
To: [login to unmask email]<mailto:[login to unmask email]>
Subject: [DB2-L] - RE: Check tables not in RW mode

Hi Phil,

I assumed that Raymond had misspelt and I was actually referring to a Mr 'Sivertsen' and not your good self.

Best regards,
Paul

On 10 May 2019, at 14:25, Sevetson, Phil <[login to unmask email]<mailto:[login to unmask email]>> wrote:

Paul O.,

I can't tell whether that was to me, with my name misspelled (Sivertsen being phonetically similar to Sevetson), or to someone else. I also don't recall discussing ACBLIBs outside of my team, so it's even more puzzling... Is there a quick and easy explanation somewhere?

-phil (sevetson)

From: Paul Ogborne [mailto:[login to unmask email]
Sent: Friday, May 10, 2019 9:17 AM
To: [login to unmask email]<mailto:[login to unmask email]>
Subject: [DB2-L] - RE: Check tables not in RW mode

Raymond,

I used the REPAIR utility to sort the DBD out. There are more options these days, but it still works I believe.
It has probably become less popular though as the DBD no longer needs to be stored contiguously in the EDM Pool as it once did.

As for Mr Sivertsen, lest he has forgotten, please remind him that ACBLIB is optional for batch jobs.
(If you can pass that on in a Canadian accent then he'll understand!).

P.S. I tend to avoid liquid lunches these days, as at my age, the snoring tends to distract people in the afternoon ;)

Regards,
Paul



On 10 May 2019, at 13:56, Bell, Raymond (Hosting Services, Technology) <[login to unmask email]<mailto:[login to unmask email]>> wrote:

Paul,

Liquid lunch still on-going? Yes, you did what? Or were you talking to young Mr. Sevetson?

Fortunately I don't have to worry about QMF these days. ;o)

Cheers,


Raymond

From: Paul Ogborne [mailto:[login to unmask email]
Sent: 10 May 2019 13:51
To: [login to unmask email]<mailto:[login to unmask email]>
Subject: [DB2-L] - RE: Check tables not in RW mode


*********************************************
" This message originates from outside our organisation. Consider carefully whether you should click on any links, open any attachments or reply. If in doubt, forward to ~ Phishing"
*********************************************


Raymond,

Yes I did although some time ago.
If memory serves, I ended up REPAIRing the DBD to shrink it down again.
For QMF it's better to update users' profiles so that they use their own table space for QMF objects; otherwise this problem tends to reoccur.

Regards,
Paul



On 10 May 2019, at 13:27, Sevetson, Phil <[login to unmask email]<mailto:[login to unmask email]>> wrote:

Roy,

How long you been doing DB2, there, neighbor? :-D

I've been doing -DIS DB(*) SP(*) RES LIMIT(*) since 1992, V2.2 for MVS/XA. Never had a problem with it. Worked on a couple of fairly small-memory systems.

Has anyone run into this? Is it potentially a problem when a DBD is large (say, for an unmaintained DSQDBDEF.DSQTSDEF)?

-phil

From: Boxwell, Roy [mailto:[login to unmask email]
Sent: Friday, May 10, 2019 2:04 AM
To: [login to unmask email]<mailto:[login to unmask email]>
Subject: [DB2-L] - RE: Check tables not in RW mode

Doesn't that have the "problem" of destroying the EDMPOOL by loading *all* DBD's into memory? I vaguely remember that a -DIS DB(*) SP(*) was *not* recommended...
Or has this disappeared over the years and releases??

Roy Boxwell

SOFTWARE ENGINEERING GmbH and SEGUS Inc.
-Product Development-

Heinrichstrasse 83-85
40239 Duesseldorf/Germany
Tel. +49 (0)211 96149-675
Fax +49 (0)211 96149-32
Email: [login to unmask email]<mailto:[login to unmask email]>
Web http://www.seg.de https://urldefense.proofpoint.com/v2/url?u=http-3A__www.seg.de_&d=DwMGaQ&c=wluqKIiwffOpZ6k5sqMWMBOn0vyYnlulRJmmvOXCFpM&r=wfE0VOZJYg9uIjc5BuTMYexNGrByDwh1giBA3sSm6qo&m=hUauOtEzc_FEgC2h2TrQ8zCb6W4EpeOsWq90IXvBHMM&s=MVHntsC4YbTWzSNPsjI6bm8avtJj1merxR74Z5dMc8U&e=
Link zur Datenschutzerklärung https://urldefense.proofpoint.com/v2/url?u=https-3A__www.seg.de_corporate_rechtliche-2Dhinweise_datenschutz_&d=DwMGaQ&c=wluqKIiwffOpZ6k5sqMWMBOn0vyYnlulRJmmvOXCFpM&r=wfE0VOZJYg9uIjc5BuTMYexNGrByDwh1giBA3sSm6qo&m=hUauOtEzc_FEgC2h2TrQ8zCb6W4EpeOsWq90IXvBHMM&s=iHw85kNRzlzQavJXa5CBFqZoXb1s4G-RMRh4BqZpd_M&e=

Software Engineering GmbH
Amtsgericht Düsseldorf, HRB 37894
Geschäftsführung: Gerhard Schubert, Ulf Heinrich

From: Srinivas Adupa [mailto:[login to unmask email]
Sent: Friday, May 10, 2019 7:04 AM
To: [login to unmask email]<mailto:[login to unmask email]>
Subject: [DB2-L] - RE: Check tables not in RW mode

Hey Ron,
-DIS DB(*) SP(*) RES

RES here means REStrict. All the objects that are NOT in RW status will be shown to you. I suggest you to use LIMIT(*) also as the last parameter so that Db2 will not limit the output to lesser objects while result is being displayed.

-DIS DB(*) SP(*) RES LIMIT(*)

Best regards,
Srini.

On Fri, May 10, 2019 at 1:37 AM Ron Thomas <[login to unmask email]<mailto:[login to unmask email]>> wrote:

Hi all.
we have 200 + tables in a schema , i would like to know whether there is any method to query to check the db2 system catalog and see what all tables are not in read write mode.
Thanks
Ron T

-----End Original Message-----
**This e-mail, including any attachments, may be confidential, privileged, or otherwise legally protected. It is intended only for the addressee. If you received this e-mail in error or from someone who was not authorized to send it to you, do not disseminate, copy, or otherwise use this e-mail or its attachments. Please notify the sender immediately by reply e-mail and delete the e-mail from your system.**
-----End Original Message-----
-----End Original Message-----
-----End Original Message-----
-----End Original Message-----
-----End Original Message-----
-----End Original Message-----
-----End Original Message-----
This e-mail may contain confidential or privileged information. If you think you have received this e-mail in error, please advise the sender by reply e-mail and then delete this e-mail immediately. Thank you. Aetna

-----End Original Message-----
**This e-mail, including any attachments, may be confidential, privileged, or otherwise legally protected. It is intended only for the addressee. If you received this e-mail in error or from someone who was not authorized to send it to you, do not disseminate, copy, or otherwise use this e-mail or its attachments. Please notify the sender immediately by reply e-mail and delete the e-mail from your system.**

J&#248;rn Thyssen

RE: SYSPROC.ADMIN_COMMAND_DB2 (was Check tables not in RW mode)
(in response to Philip Sevetson)

Hi Phil,

What are your problems with ADMIN_COMMAND_DB2?

I can call the procedure without issues and get the output from the command back in the first result set or the parsed output in the second result set if I specify PARSE_TYPE. Note that you have to spell the command out fully if you use PARSE_TYPE.

For example, I call with DB2_CMD = '-DISPLAY DATABASE(*) SP(*) RES', LEN_CMD = 40 and PARSE_TYPE = 'DB' I get +466 and two result sets. The second result set contains a list of the databases and the (first, doh!) status

 

L ROWNUM      DBNAME   SPACENAM TYPE PART   STATUS 
* * * * * *
- ----------- -------- -------- ---- ------ ------
1 XXXXXXX DB 0 RW
2 JSNDB2 DB 0 RW
3 DSN00196 DB 0 RW
4 CZKTDEMO DB 0 RW
5 DEMODB03 DB 0 RW
6 BOBDEMO2 DB 0 RW

In Reply to Philip Sevetson:
Larry,

If you understand how to use that, you should consider giving a talk at the nearby regional UGs. I've spent several fruitless hours trying to make it divulge useful results.

-phil

 

Best regards,

Jørn Thyssen

Rocket Software
77 Fourth Avenue • Waltham, MA • 02451 • USA
E: [login to unmask email] • W: www.rocketsoftware.com 

2019 IBM Champion.

Views are personal. 

Daniel Luksetich

SYSPROC.ADMIN_COMMAND_DB2 (was Check tables not in RW mode)
(in response to Jørn Thyssen)
I’ve had success with ADMIN_COMMAND_DB2 as well, don’t know what the issues are.



Daniel L Luksetich

DanL Database Consulting



IBM GOLD Consultant

IBM Champion for Analytics

IDUG Content Committee Past-Chairman

IDUG DB2-L Administrator

IBM Certified Database Adminstrator – DB2 11 DBA for z/OS

IBM Certified System Administrator – DB2 11 for z/OS

IBM Certified Application Developer – DB2 11 for z/OS

IBM Certified Advanced Database Administrator – DB2 10.1 for Linux UNIX and Windows



From: Jørn Thyssen <[login to unmask email]>
Sent: Monday, May 13, 2019 8:12 AM
To: [login to unmask email]
Subject: [DB2-L] - RE: SYSPROC.ADMIN_COMMAND_DB2 (was Check tables not in RW mode)



Hi Phil,

What are your problems with ADMIN_COMMAND_DB2?

I can call the procedure without issues and get the output from the command back in the first result set or the parsed output in the second result set if I specify PARSE_TYPE. Note that you have to spell the command out fully if you use PARSE_TYPE.

For example, I call with DB2_CMD = '-DISPLAY DATABASE(*) SP(*) RES', LEN_CMD = 40 and PARSE_TYPE = 'DB' I get +466 and two result sets. The second result set contains a list of the databases and the (first, doh!) status



L ROWNUM DBNAME SPACENAM TYPE PART STATUS
* * * * * *
- ----------- -------- -------- ---- ------ ------
1 XXXXXXX DB 0 RW
2 JSNDB2 DB 0 RW
3 DSN00196 DB 0 RW
4 CZKTDEMO DB 0 RW
5 DEMODB03 DB 0 RW
6 BOBDEMO2 DB 0 RW

In Reply to Philip Sevetson:

Larry,

If you understand how to use that, you should consider giving a talk at the nearby regional UGs. I've spent several fruitless hours trying to make it divulge useful results.

-phil



Best regards,

Jørn Thyssen

Rocket Software
77 Fourth Avenue • Waltham, MA • 02451 • USA
E: [login to unmask email] <mailto:[login to unmask email]> • W: www.rocketsoftware.com http://www.rocketsoftware.com

2019 IBM Champion.

Views are personal.



-----End Original Message-----

Marcus Davage

SYSPROC.ADMIN_COMMAND_DB2 (was Check tables not in RW mode)
(in response to Philip Sevetson)
I have a Rexx (called in batch) which does some nice stuff with that SP. Mentioned it (briefly) in my talk in IDUG Malta last year.

Regards,
Marcus Davage
Lead Product Developer
AMI-DevOps for Db2 - SQL Performance
Direct

+44 118 921 8517

[cid:[login to unmask email]



Mobile

+44 7840 023 560



Email

[login to unmask email]<mailto:[login to unmask email]>





From: Sevetson, Phil <[login to unmask email]>
Sent: 10 May 2019 18:54
To: '[login to unmask email]' <[login to unmask email]>
Subject: [EXTERNAL] [DB2-L] - SYSPROC.ADMIN_COMMAND_DB2 (was RE: Check tables not in RW mode)

Larry,

If you understand how to use that, you should consider giving a talk at the nearby regional UGs. I've spent several fruitless hours trying to make it divulge useful results.

-phil

From: Jardine, Lawrence J [mailto:[login to unmask email]
Sent: Friday, May 10, 2019 12:34 PM
To: [login to unmask email]<mailto:[login to unmask email]>
Subject: [DB2-L] - RE: Check tables not in RW mode

Another option is to issue the command via the SYSPROC.ADMIN_COMMAND_DB2 stored procedure.

Larry Jardine
Database Advisor
[1_Heart_Aetna_logo_reg_rgb_vio]



Proprietary
From: Boxwell, Roy <[login to unmask email]<mailto:[login to unmask email]>>
Sent: Friday, May 10, 2019 12:09 PM
To: [login to unmask email]<mailto:[login to unmask email]>
Subject: [EXTERNAL] [DB2-L] - RE: Check tables not in RW mode

**** External Email - Use Caution ****
Well, I use SSAR (soon not any more!) to cross memory access the DBET from an APF authorized load module. Dump the contents down to a little COBOL program that decodes it all and Bibs your uncle!
No need for complex REXX or pesky DISPLAY commands...
Roy Boxwell
SOFTWARE ENGINEERING GmbH and SEGUS Inc.
-Product Development-
Heinrichstrasse 83-85
40239 Düsseldorf/Germany
Tel. +49 (0)211 96149-675
Fax +49 (0)211 96149-32
Email: [login to unmask email]<mailto:[login to unmask email]>
http://www.seg.de https://urldefense.proofpoint.com/v2/url?u=http-3A__www.seg.de&d=DwMGaQ&c=wluqKIiwffOpZ6k5sqMWMBOn0vyYnlulRJmmvOXCFpM&r=wfE0VOZJYg9uIjc5BuTMYexNGrByDwh1giBA3sSm6qo&m=hUauOtEzc_FEgC2h2TrQ8zCb6W4EpeOsWq90IXvBHMM&s=2jQtJFiONCmFRu_kr6JDzMB8GjHTRYDjW1tPSV85FlE&e=
Link zur Datenschutzerklärung https://urldefense.proofpoint.com/v2/url?u=https-3A__www.seg.de_corporate_rechtliche-2Dhinweise_datenschutz_&d=DwMGaQ&c=wluqKIiwffOpZ6k5sqMWMBOn0vyYnlulRJmmvOXCFpM&r=wfE0VOZJYg9uIjc5BuTMYexNGrByDwh1giBA3sSm6qo&m=hUauOtEzc_FEgC2h2TrQ8zCb6W4EpeOsWq90IXvBHMM&s=iHw85kNRzlzQavJXa5CBFqZoXb1s4G-RMRh4BqZpd_M&e=

Software Engineering GmbH
Amtsgericht Düsseldorf, HRB 37894
Geschäftsführung: Gerhard Schubert, Ulf Heinrich

On 10 May 2019, at 15:37, Sevetson, Phil <[login to unmask email]<mailto:[login to unmask email]>> wrote:
:) Got it. Thanks. Signing off before the mods club me into submission...

From: Paul Ogborne [mailto:[login to unmask email]
Sent: Friday, May 10, 2019 9:31 AM
To: [login to unmask email]<mailto:[login to unmask email]>
Subject: [DB2-L] - RE: Check tables not in RW mode

Hi Phil,

I assumed that Raymond had misspelt and I was actually referring to a Mr 'Sivertsen' and not your good self.

Best regards,
Paul

On 10 May 2019, at 14:25, Sevetson, Phil <[login to unmask email]<mailto:[login to unmask email]>> wrote:

Paul O.,

I can't tell whether that was to me, with my name misspelled (Sivertsen being phonetically similar to Sevetson), or to someone else. I also don't recall discussing ACBLIBs outside of my team, so it's even more puzzling... Is there a quick and easy explanation somewhere?

-phil (sevetson)

From: Paul Ogborne [mailto:[login to unmask email]
Sent: Friday, May 10, 2019 9:17 AM
To: [login to unmask email]<mailto:[login to unmask email]>
Subject: [DB2-L] - RE: Check tables not in RW mode

Raymond,

I used the REPAIR utility to sort the DBD out. There are more options these days, but it still works I believe.
It has probably become less popular though as the DBD no longer needs to be stored contiguously in the EDM Pool as it once did.

As for Mr Sivertsen, lest he has forgotten, please remind him that ACBLIB is optional for batch jobs.
(If you can pass that on in a Canadian accent then he'll understand!).

P.S. I tend to avoid liquid lunches these days, as at my age, the snoring tends to distract people in the afternoon ;)

Regards,
Paul




On 10 May 2019, at 13:56, Bell, Raymond (Hosting Services, Technology) <[login to unmask email]<mailto:[login to unmask email]>> wrote:

Paul,

Liquid lunch still on-going? Yes, you did what? Or were you talking to young Mr. Sevetson?

Fortunately I don't have to worry about QMF these days. ;o)

Cheers,


Raymond

From: Paul Ogborne [mailto:[login to unmask email]
Sent: 10 May 2019 13:51
To: [login to unmask email]<mailto:[login to unmask email]>
Subject: [DB2-L] - RE: Check tables not in RW mode


*********************************************
" This message originates from outside our organisation. Consider carefully whether you should click on any links, open any attachments or reply. If in doubt, forward to ~ Phishing"
*********************************************



Raymond,

Yes I did although some time ago.
If memory serves, I ended up REPAIRing the DBD to shrink it down again.
For QMF it's better to update users' profiles so that they use their own table space for QMF objects; otherwise this problem tends to reoccur.

Regards,
Paul




On 10 May 2019, at 13:27, Sevetson, Phil <[login to unmask email]<mailto:[login to unmask email]>> wrote:

Roy,

How long you been doing DB2, there, neighbor? :-D

I've been doing -DIS DB(*) SP(*) RES LIMIT(*) since 1992, V2.2 for MVS/XA. Never had a problem with it. Worked on a couple of fairly small-memory systems.

Has anyone run into this? Is it potentially a problem when a DBD is large (say, for an unmaintained DSQDBDEF.DSQTSDEF)?

-phil

From: Boxwell, Roy [mailto:[login to unmask email]
Sent: Friday, May 10, 2019 2:04 AM
To: [login to unmask email]<mailto:[login to unmask email]>
Subject: [DB2-L] - RE: Check tables not in RW mode

Doesn't that have the "problem" of destroying the EDMPOOL by loading *all* DBD's into memory? I vaguely remember that a -DIS DB(*) SP(*) was *not* recommended...
Or has this disappeared over the years and releases??

Roy Boxwell

SOFTWARE ENGINEERING GmbH and SEGUS Inc.
-Product Development-

Heinrichstrasse 83-85
40239 Duesseldorf/Germany
Tel. +49 (0)211 96149-675
Fax +49 (0)211 96149-32
Email: [login to unmask email]<mailto:[login to unmask email]>
Web http://www.seg.de https://urldefense.proofpoint.com/v2/url?u=http-3A__www.seg.de_&d=DwMGaQ&c=wluqKIiwffOpZ6k5sqMWMBOn0vyYnlulRJmmvOXCFpM&r=wfE0VOZJYg9uIjc5BuTMYexNGrByDwh1giBA3sSm6qo&m=hUauOtEzc_FEgC2h2TrQ8zCb6W4EpeOsWq90IXvBHMM&s=MVHntsC4YbTWzSNPsjI6bm8avtJj1merxR74Z5dMc8U&e=
Link zur Datenschutzerklärung https://urldefense.proofpoint.com/v2/url?u=https-3A__www.seg.de_corporate_rechtliche-2Dhinweise_datenschutz_&d=DwMGaQ&c=wluqKIiwffOpZ6k5sqMWMBOn0vyYnlulRJmmvOXCFpM&r=wfE0VOZJYg9uIjc5BuTMYexNGrByDwh1giBA3sSm6qo&m=hUauOtEzc_FEgC2h2TrQ8zCb6W4EpeOsWq90IXvBHMM&s=iHw85kNRzlzQavJXa5CBFqZoXb1s4G-RMRh4BqZpd_M&e=

Software Engineering GmbH
Amtsgericht Düsseldorf, HRB 37894
Geschäftsführung: Gerhard Schubert, Ulf Heinrich

From: Srinivas Adupa [mailto:[login to unmask email]
Sent: Friday, May 10, 2019 7:04 AM
To: [login to unmask email]<mailto:[login to unmask email]>
Subject: [DB2-L] - RE: Check tables not in RW mode

Hey Ron,
-DIS DB(*) SP(*) RES

RES here means REStrict. All the objects that are NOT in RW status will be shown to you. I suggest you to use LIMIT(*) also as the last parameter so that Db2 will not limit the output to lesser objects while result is being displayed.

-DIS DB(*) SP(*) RES LIMIT(*)

Best regards,
Srini.

On Fri, May 10, 2019 at 1:37 AM Ron Thomas <[login to unmask email]<mailto:[login to unmask email]>> wrote:

Hi all.
we have 200 + tables in a schema , i would like to know whether there is any method to query to check the db2 system catalog and see what all tables are not in read write mode.
Thanks
Ron T

-----End Original Message-----
**This e-mail, including any attachments, may be confidential, privileged, or otherwise legally protected. It is intended only for the addressee. If you received this e-mail in error or from someone who was not authorized to send it to you, do not disseminate, copy, or otherwise use this e-mail or its attachments. Please notify the sender immediately by reply e-mail and delete the e-mail from your system.**
-----End Original Message-----
-----End Original Message-----
-----End Original Message-----
-----End Original Message-----
-----End Original Message-----
-----End Original Message-----
-----End Original Message-----
This e-mail may contain confidential or privileged information. If you think you have received this e-mail in error, please advise the sender by reply e-mail and then delete this e-mail immediately. Thank you. Aetna

-----End Original Message-----
**This e-mail, including any attachments, may be confidential, privileged, or otherwise legally protected. It is intended only for the addressee. If you received this e-mail in error or from someone who was not authorized to send it to you, do not disseminate, copy, or otherwise use this e-mail or its attachments. Please notify the sender immediately by reply e-mail and delete the e-mail from your system.**
-----End Original Message-----
BMC Software Limited Registered Office: Building E2, Eskdale Road, Winnersh, Wokingham, Berkshire, United Kingdom, RG41 5TS Registered in England No. 1927903 The content of this email is confidential. If you are not the addressee, you may not distribute, copy or disclose any part of it. If you receive this message in error, please delete this from your system and notify the sender immediately.
Attachments

  • image002.png (12.8k)

Philip Sevetson

SYSPROC.ADMIN_COMMAND_DB2 (was Check tables not in RW mode)
(in response to Jørn Thyssen)
Jørn,

If you can, then, would you inform me of the cause of my error here?

CALL SYSPROC.ADMIN_COMMAND_DB2('-DISPLAY UTILITY(*)',19,'UT');

NO AUTHORIZED PROCEDURE NAMED SYSPROC.ADMIN_COMMAND_DB2 HAVING COMPATIBLE ARGUMENTS WAS FOUND. SQLCODE=-440, SQLSTATE=42884, DRIVER=3.68.61


From: Jørn Thyssen [mailto:[login to unmask email]
Sent: Monday, May 13, 2019 9:12 AM
To: [login to unmask email]
Subject: [DB2-L] - RE: SYSPROC.ADMIN_COMMAND_DB2 (was Check tables not in RW mode)


Hi Phil,

What are your problems with ADMIN_COMMAND_DB2?

I can call the procedure without issues and get the output from the command back in the first result set or the parsed output in the second result set if I specify PARSE_TYPE. Note that you have to spell the command out fully if you use PARSE_TYPE.

For example, I call with DB2_CMD = '-DISPLAY DATABASE(*) SP(*) RES', LEN_CMD = 40 and PARSE_TYPE = 'DB' I get +466 and two result sets. The second result set contains a list of the databases and the (first, doh!) status



L ROWNUM DBNAME SPACENAM TYPE PART STATUS
* * * * * *
- ----------- -------- -------- ---- ------ ------
1 XXXXXXX DB 0 RW
2 JSNDB2 DB 0 RW
3 DSN00196 DB 0 RW
4 CZKTDEMO DB 0 RW
5 DEMODB03 DB 0 RW
6 BOBDEMO2 DB 0 RW

In Reply to Philip Sevetson:
Larry,

If you understand how to use that, you should consider giving a talk at the nearby regional UGs. I've spent several fruitless hours trying to make it divulge useful results.

-phil



Best regards,

Jørn Thyssen

Rocket Software
77 Fourth Avenue • Waltham, MA • 02451 • USA
E: [login to unmask email] • W: www.rocketsoftware.com

2019 IBM Champion.

Views are personal.

-----End Original Message-----
**This e-mail, including any attachments, may be confidential, privileged, or otherwise legally protected. It is intended only for the addressee. If you received this e-mail in error or from someone who was not authorized to send it to you, do not disseminate, copy, or otherwise use this e-mail or its attachments. Please notify the sender immediately by reply e-mail and delete the e-mail from your system.**

J&#248;rn Thyssen

RE: SYSPROC.ADMIN_COMMAND_DB2 (was Check tables not in RW mode)
(in response to Philip Sevetson)

Hi Phil,

From a Data Studio "SQL scripts" try:

 CALL SYSPROC.ADMIN_COMMAND_DB2('-DISPLAY UTILITY(*)',19,'UT',NULL,?,?,?,?,?,?,?,?)

Alternatively, navigate to the SYSPROC schema in "Data Source Explorer", find procedures, right-click ADMIN_COMMAND_DB2 and select "Run"


In Reply to Philip Sevetson:

Jørn,

If you can, then, would you inform me of the cause of my error here?

CALL SYSPROC.ADMIN_COMMAND_DB2('-DISPLAY UTILITY(*)',19,'UT');

NO AUTHORIZED PROCEDURE NAMED SYSPROC.ADMIN_COMMAND_DB2 HAVING COMPATIBLE ARGUMENTS WAS FOUND. SQLCODE=-440, SQLSTATE=42884, DRIVER=3.68.61


From: Jørn Thyssen [mailto:[login to unmask email]
Sent: Monday, May 13, 2019 9:12 AM
To: [login to unmask email]
Subject: [DB2-L] - RE: SYSPROC.ADMIN_COMMAND_DB2 (was Check tables not in RW mode)


Hi Phil,

What are your problems with ADMIN_COMMAND_DB2?

I can call the procedure without issues and get the output from the command back in the first result set or the parsed output in the second result set if I specify PARSE_TYPE. Note that you have to spell the command out fully if you use PARSE_TYPE.

For example, I call with DB2_CMD = '-DISPLAY DATABASE(*) SP(*) RES', LEN_CMD = 40 and PARSE_TYPE = 'DB' I get +466 and two result sets. The second result set contains a list of the databases and the (first, doh!) status



L ROWNUM DBNAME SPACENAM TYPE PART STATUS
* * * * * *
- ----------- -------- -------- ---- ------ ------
1 XXXXXXX DB 0 RW
2 JSNDB2 DB 0 RW
3 DSN00196 DB 0 RW
4 CZKTDEMO DB 0 RW
5 DEMODB03 DB 0 RW
6 BOBDEMO2 DB 0 RW

In Reply to Philip Sevetson:
Larry,

If you understand how to use that, you should consider giving a talk at the nearby regional UGs. I've spent several fruitless hours trying to make it divulge useful results.

-phil



Best regards,

Jørn Thyssen

Rocket Software
77 Fourth Avenue • Waltham, MA • 02451 • USA
E: [login to unmask email] • W: www.rocketsoftware.com

2019 IBM Champion.

Views are personal.

-----End Original Message-----
**This e-mail, including any attachments, may be confidential, privileged, or otherwise legally protected. It is intended only for the addressee. If you received this e-mail in error or from someone who was not authorized to send it to you, do not disseminate, copy, or otherwise use this e-mail or its attachments. Please notify the sender immediately by reply e-mail and delete the e-mail from your system.**



 

Best regards,

Jørn Thyssen

Rocket Software
77 Fourth Avenue • Waltham, MA • 02451 • USA
E: [login to unmask email] • W: www.rocketsoftware.com 

2019 IBM Champion.

Views are personal. 

Philip Sevetson

SYSPROC.ADMIN_COMMAND_DB2 (was Check tables not in RW mode)
(in response to Jørn Thyssen)
That worked – thank you. I think I can do some experimenting from here :-)

From: Jørn Thyssen [mailto:[login to unmask email]
Sent: Tuesday, May 21, 2019 9:36 AM
To: [login to unmask email]
Subject: [DB2-L] - RE: SYSPROC.ADMIN_COMMAND_DB2 (was Check tables not in RW mode)


Hi Phil,

From a Data Studio "SQL scripts" try:

CALL SYSPROC.ADMIN_COMMAND_DB2('-DISPLAY UTILITY(*)',19,'UT',NULL,?,?,?,?,?,?,?,?)

Alternatively, navigate to the SYSPROC schema in "Data Source Explorer", find procedures, right-click ADMIN_COMMAND_DB2 and select "Run"

In Reply to Philip Sevetson:
Jørn,

If you can, then, would you inform me of the cause of my error here?

CALL SYSPROC.ADMIN_COMMAND_DB2('-DISPLAY UTILITY(*)',19,'UT');

NO AUTHORIZED PROCEDURE NAMED SYSPROC.ADMIN_COMMAND_DB2 HAVING COMPATIBLE ARGUMENTS WAS FOUND. SQLCODE=-440, SQLSTATE=42884, DRIVER=3.68.61


From: Jørn Thyssen [mailto:[login to unmask email]
Sent: Monday, May 13, 2019 9:12 AM
To: [login to unmask email]
Subject: [DB2-L] - RE: SYSPROC.ADMIN_COMMAND_DB2 (was Check tables not in RW mode)


Hi Phil,

What are your problems with ADMIN_COMMAND_DB2?

I can call the procedure without issues and get the output from the command back in the first result set or the parsed output in the second result set if I specify PARSE_TYPE. Note that you have to spell the command out fully if you use PARSE_TYPE.

For example, I call with DB2_CMD = '-DISPLAY DATABASE(*) SP(*) RES', LEN_CMD = 40 and PARSE_TYPE = 'DB' I get +466 and two result sets. The second result set contains a list of the databases and the (first, doh!) status



L ROWNUM DBNAME SPACENAM TYPE PART STATUS
* * * * * *
- ----------- -------- -------- ---- ------ ------
1 XXXXXXX DB 0 RW
2 JSNDB2 DB 0 RW
3 DSN00196 DB 0 RW
4 CZKTDEMO DB 0 RW
5 DEMODB03 DB 0 RW
6 BOBDEMO2 DB 0 RW

In Reply to Philip Sevetson:
Larry,

If you understand how to use that, you should consider giving a talk at the nearby regional UGs. I've spent several fruitless hours trying to make it divulge useful results.

-phil



Best regards,

Jørn Thyssen

Rocket Software
77 Fourth Avenue • Waltham, MA • 02451 • USA
E: [login to unmask email] • W: www.rocketsoftware.com

2019 IBM Champion.

Views are personal.

-----End Original Message-----
**This e-mail, including any attachments, may be confidential, privileged, or otherwise legally protected. It is intended only for the addressee. If you received this e-mail in error or from someone who was not authorized to send it to you, do not disseminate, copy, or otherwise use this e-mail or its attachments. Please notify the sender immediately by reply e-mail and delete the e-mail from your system.**





Best regards,

Jørn Thyssen

Rocket Software
77 Fourth Avenue • Waltham, MA • 02451 • USA
E: [login to unmask email] • W: www.rocketsoftware.com

2019 IBM Champion.

Views are personal.

-----End Original Message-----
**This e-mail, including any attachments, may be confidential, privileged, or otherwise legally protected. It is intended only for the addressee. If you received this e-mail in error or from someone who was not authorized to send it to you, do not disseminate, copy, or otherwise use this e-mail or its attachments. Please notify the sender immediately by reply e-mail and delete the e-mail from your system.**