home *** CD-ROM | disk | FTP | other *** search
/ NetNews Usenet Archive 1992 #20 / NN_1992_20.iso / spool / comp / database / informix / 1911 < prev    next >
Encoding:
Internet Message Format  |  1992-09-10  |  2.4 KB

  1. Path: sparky!uunet!decwrl!infopiz!lupine!motcsd!udc!mcdphx!ennews!anasaz!qip!naomi
  2. Newsgroups: comp.databases.informix
  3. Subject: Database Drop PROBLEM SOLVED!
  4. Message-ID: <1992Sep9.144956.13892@anasaz>
  5. From: naomi@anasaz (Naomi Walker)
  6. Date: 9 Sep 92 14:49:56 GMT
  7. Organization: Anasazi, Inc. Phoenix, AZ, USA
  8. Lines: 68
  9.  
  10.  
  11.  
  12. Our mailer is having problems, so i'll just post this, since many people
  13. seem to have to same problem.  
  14.  
  15. naomi
  16.  
  17.  
  18.  
  19.  
  20.  
  21. Thanks to some golden advice from Bob Baskett (thank you), I have fixed
  22. the problem with the bad database and table I could not drop.
  23.  
  24. This is not for the weak of heart, expecially when working on a production
  25. system, and I do not encourage this mucking about if you are not desperate
  26. (disclaimer).
  27.  
  28. Here is what I did, following Bob's directions:
  29.  
  30. 1. create a table with the exact schema as the one giving you trouble.
  31.    (for this example - use new_tab)
  32.  
  33.    NOTE: I could not do a schema on the bad database.  I created the
  34.          schema from a similar test database.
  35.  
  36. 2. get the partnum for new_tab and the old_tab (one causing problems)
  37.    from the systables.
  38. 3. update systables - switching the partnums for the two tables.
  39. 4. delete from systables,syscolumns,sysindexs for tabid = tabid of
  40.    new_tab
  41. 5. drop old_tab.
  42.  
  43.    This should have worked, but I got the error:
  44.    "311 - Cannot Open System Catalogs (syscolumns)"
  45.  
  46. 6.  I unloaded the rows from syscolumns from the similar database, same table.
  47.  
  48. 7.  I changed the tabid's to match the table in the bad database.
  49.  
  50. 8.  Again I tried to delete the table, but this time got:
  51.    "311 - Cannot Open System Catalogs (sysindexes)"
  52.    
  53.     So I followed the procedure I used in step 6 and 7 and dumped the 
  54.     sysindexes rows, and loaded them in the bad database.
  55.  
  56. 9.  At this point, I was able to drop the table, and then the database.
  57.  
  58. Oh, boy!  I had fun, and am dangerous now that I am more confident 
  59. changing system catalogs (ONLY if I have to, of course).
  60.  
  61. Thanks again, Bob, for your help (and Simon David).  I did not look 
  62. forward to unloading all the databases in the partition.
  63.  
  64. Naomi
  65.  
  66. -- 
  67.   Naomi Walker  (aka N7FSA)     naomi%anasaz.UUCP@asuvax.eas.asu.edu
  68.  
  69.   Enthusiasm is caught,         In tennis, 
  70.   not taught.                   love means nothing.
  71.  
  72.  
  73. -- 
  74.   Naomi Walker  (aka N7FSA)
  75.   Anasazi Inc.  Phoenix, Arizona 602-395-1731
  76.  
  77.   {uunet!pyramid},{sun!sunburn!gtx!},{asuvax} !anasaz!qip!naomi 
  78.