By using this site, you agree to our updated Privacy Policy and our Terms of Use. Manage your Cookies Settings.
438,514 Members | 1,693 Online
Bytes IT Community
+ Ask a Question
Need help? Post your question and get tips & solutions from a community of 438,514 IT Pros & Developers. It's quick & easy.

cryptic error in after the Column involved in PK was dropped

P: n/a
Hi,
I am facing an issue here.

I had to drop a number of columns (around 20) from a table, which I
tried to do all at the same time using the following command.

Alter table table_name drop column <column1drop column <column2>
drop column <column3>.............................drop column <column20>

The above command was successful.

The table had a composite primary key consisting of two columns, one
of which was dropped in the above statement.

The subsequent Reorg on that table, gave the warning saying "SQL1279W
Some indexes may not have been recreated."

Any subsequent operation on that table(select, insert etc) disconnects
the user from the database giving a tcp/ip error, while any alter on
that table gives the error DB21034E "The Database is damaged" and
disconnects the user.

Further, trying to drop that table gives the error, "SQL0204N "1" is
an undefined name."
And recreating gives the error "Name is already used by an existing
object".

Further, dropping the Primary key index also disconnects the user from
the database.

What could be the possible fix for it?

please reply ASAP, it's urgent

Rahul

Nov 21 '07 #1
Share this Question
Share on Google+
5 Replies


P: n/a
Rahul Babbar wrote:
What could be the possible fix for it?
please reply ASAP, it's urgent
Call support, get a PMR opened with a priority fitting your urgency.

Cheers
Serge

--
Serge Rielau
DB2 Solutions Development
IBM Toronto Lab
Nov 21 '07 #2

P: n/a
On Nov 21, 7:30 pm, Serge Rielau <srie...@ca.ibm.comwrote:
Rahul Babbar wrote:
What could be the possible fix for it?
please reply ASAP, it's urgent

Call support, get a PMR opened with a priority fitting your urgency.

Cheers
Serge

--
Serge Rielau
DB2 Solutions Development
IBM Toronto Lab
Isn't there something that can be done right now?
the basic problem is this

I have accidently dropped a column that was part of the primary
key....It was dropped successfully, but the the index related to it
became invalid, and only because of that whole database is considered
'damaged'. The table can neither be dropped, nor queried, which really
is unexpected.....

I am looking to fix this problem right now..

Can anybody help?

Rahul
Nov 21 '07 #3

P: n/a
Rahul Babbar wrote:
On Nov 21, 7:30 pm, Serge Rielau <srie...@ca.ibm.comwrote:
>Rahul Babbar wrote:
>>What could be the possible fix for it?
please reply ASAP, it's urgent
Call support, get a PMR opened with a priority fitting your urgency.

Cheers
Serge

--
Serge Rielau
DB2 Solutions Development
IBM Toronto Lab

Isn't there something that can be done right now?
the basic problem is this

I have accidently dropped a column that was part of the primary
key....It was dropped successfully, but the the index related to it
became invalid, and only because of that whole database is considered
'damaged'. The table can neither be dropped, nor queried, which really
is unexpected.....

I am looking to fix this problem right now..
Obviously something went wrong... seriously wrong!
So you have the choice of poking at it randomly making it worse or
getting expert advise. It's your database! If RIGHT NOW goes wrong. What
will your boss say? RIGHT NOW you're wasting time.

Cheers
Serge
--
Serge Rielau
DB2 Solutions Development
IBM Toronto Lab
Nov 21 '07 #4

P: n/a
I am looking to fix this problem right now..
>
Can anybody help?
Yes, IBM technical support can. Call them. That's the fastest thing
you can do.

You aren't likely to find either a fast or a correct solution to your
problem on a newsgroup.
Nov 21 '07 #5

P: n/a
Rahul Babbar wrote:
Hi,
I am facing an issue here.

I had to drop a number of columns (around 20) from a table, which I
tried to do all at the same time using the following command.

Alter table table_name drop column <column1drop column <column2>
drop column <column3>.............................drop column <column20>

The above command was successful.

The table had a composite primary key consisting of two columns, one
of which was dropped in the above statement.

The subsequent Reorg on that table, gave the warning saying "SQL1279W
Some indexes may not have been recreated."

Any subsequent operation on that table(select, insert etc) disconnects
the user from the database giving a tcp/ip error, while any alter on
that table gives the error DB21034E "The Database is damaged" and
disconnects the user.

Further, trying to drop that table gives the error, "SQL0204N "1" is
an undefined name."
And recreating gives the error "Name is already used by an existing
object".

Further, dropping the Primary key index also disconnects the user from
the database.

What could be the possible fix for it?

please reply ASAP, it's urgent

Rahul
You could always restore the database and roll forward to just before it got
damaged.

Colin
Nov 21 '07 #6

This discussion thread is closed

Replies have been disabled for this discussion.