Results 1 to 3 of 3

Thread: Drop table

  1. #1
    Join Date
    Nov 2003

    Unanswered: Drop table


    I am trouble dropping a table. When I go to drop it I get the error:

    [IBM][CLI Driver][DB2/NT] SQL0478N The object type "TABLE" cannot be dropped because there is an object "DB2ADMIN.SQL030331180300279", of type "FUNCTION", which depends on it. SQLSTATE=42893

    which is fine, went into syscat.functions, found the function name indicated by the object. Then did 'drop function functionname' at command and it said that the function had been dropped. All Good. Soo, went back to drop the table and it came up with exactly the same error as previously. Went back to syscat.functions and the function is still there. So I tried to delete/drop the object and it won't go! any ideans on this?



    - also, I checked my function scripts and this function does make any reference to the table I am trying to remove. Peculiar?

  2. #2
    Join Date
    Aug 2001

    Re: Drop table

    Use control centre to view dependencies for the table and function ...

    (BTW, does anyone have a standard SQL to list the dependencies on an object ?)

    Visit the new-look IDUG Website , register to gain access to the excellent content.

  3. #3
    Join Date
    Nov 2003

    Thanks for the reply, I figured it out this morning and got it working and was about to update the thread but you beat me to it! Also turned out that person who had created the function had copied and pasted from an old one and left an invalid reference to the table I was trying to drop. Didn't affect the function but prevented me from dropping it! Grrr!

    Thanks anyway,


Posting Permissions

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