Results 1 to 3 of 3
  1. #1
    Join Date
    Oct 2012

    Unanswered: reduce tablespace

    i want to reduce size of below tablespace
    Tablespace ID = 101
    Name = TS_RPP_DATA_DEC_12
    Type = Database managed space
    Contents = All permanent data. Large table space.
    State = 0x0000
    Detailed explanation:
    Total pages = 1444672
    Useable pages = 1444656
    Used pages = 272
    Free pages = 1444384
    High water mark (pages) = 624
    Page size (bytes) = 16384
    Extent size (pages) = 16
    Prefetch size (pages) = 192
    Number of containers = 1

    but when ever i tried to
    db2 "alter tablespace TS_RPP_DATA_DEC_12 reduce (all 100m)"
    it gives me below error
    bash-3.2$ db2 "alter tablespace TS_RPP_DATA_DEC_12 reduce (all 100m)"
    DB21034E The command was processed as an SQL statement because it was not a
    valid Command Line Processor command. During SQL processing it returned:
    SQL20170N There is not enough space in the table space "TS_RPP_DATA_DEC_12"
    for the specified action. Reason code = "1". SQLSTATE=57059

  2. #2
    Join Date
    Apr 2006
    Provided Answers: 11
    what I would try
    alter tablespace tsname resize (all containers 1000 )
    at least above the high water mark..
    Best Regards, Guy Przytula
    Database Software Consultant
    Good DBAs are not formed in a week or a month. They are created little by little, day by day. Protracted and patient effort is needed to develop good DBAs.
    Spoon feeding : To treat (another) in a way that discourages independent thought or action, as by overindulgence.
    DB2 UDB LUW Certified V7-V8-V9-V9.7-V10.1-V10.5 DB Admin - Advanced DBA -Dprop..
    Information Server Datastage Certified

  3. #3
    Join Date
    Apr 2012
    What version of DB2 was this created? Could be wrong but I seem to remember to perform a reduce with an alter command the tablespace must have been created in db2 v9.7 or above

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts