cancel
Showing results for 
Search instead for 
Did you mean: 

Run SQL command in AS/400 and DBACOCKPIT for note 1347302

Former Member
0 Kudos

Hi,

There is this hot news in note 1347302,

a.) I wonder how many of you manage to run the SQL ?

b.) How do I execute the long sql statement in as/400 green screen ? As per the steps mentioned i save the long statement in a file "tbsp_size_issue.sql" and store in /home , then i execute

qsh
db2 -tvf "/home/tbsp_size_issue.sql"

Then i got below message

EXECUTING: select t1.tbsp_name, t1.tbsp_id, t1.tbsp_total_pages, ( t

1.tbsp_total_pages * ( t0.tbsp_page_size / 1024 ) ) as tbsp_total_

size_kb, t1.tbsp_page_top, ( t1.tbsp_page_top * ( t0.tbsp_p

age_size / 1024 ) ) as tbsp_hwm_kb, t0.tbsp_page_size, t1

.dbpartitionnum from sysibmadm.snaptbsp t0, sysibmadm.snaptbsp_part t1 wh

ere t0.tbsp_name = t1.tbsp_name and t0.dbpartitionnum = t1.dbpartiti

onnum and ( ( t1.tbsp_total_pages * ( t0.tbsp_page_size / 1024 ) )

> ( 0.9 * power( bigint( 2 ), 32 ) ) or ( t1.tbsp_page_top * ( t

0.tbsp_page_size / 1024 ) ) > ( 0.8 * power( bigint( 2 ), 32 )

) ) order by t1.tbsp_name, t1.dbpartitionnum

        • CLI ERROR *****

SQLSTATE: 42601

NATIVE ERROR CODE: -199

Keyword FROM not expected. Valid tokens: (.

c.) In the notes, it mention we can execute SQL in tcode DBACOCKPIT also, but i don't find the "SQL command" entry for me to put the SQL statement. Anyone executed SQL in DBACOCKPIT before ?

Please advise.

Your comment and advise will be appreciated.

Thanks.

Regards,

Kent

Accepted Solutions (1)

Accepted Solutions (1)

JanStallkamp
Employee
Employee
0 Kudos

Hi.

Did you notice that the mentioned SAP Note 1347302 is DB6 specific? If you are running SAP on IBM i there should be no necessity to implement it. The mentioned DBACOCKPIT functionality is DB6 specific too.

Regards,

Jan Stallkamp

Former Member
0 Kudos

Hi Jan,

I see, so I will just ignore the note since i am running on DB2 AS/400

Thanks.

Regards,

Kent

Answers (0)