Hello,
I=B4m trying to add a new column in SQL Server 2000, but=20
in the specific table I don=B4t get, in other tables I get.=20
This table has 7000 rows and when I try, the server get=20
processing and dont=B4t finish. I already wait for 20=20
minutes and nothing.=20
Anyone can help me?
Thanks,
DanielaDaniela
I assume you did it by EM and not by QA
This is T-SQL example how to add a new column
CREATE TABLE Test
(
col INT
)
GO
INSERT INTO Test VALUES (1)
GO
ALTER TABLE Test ADD col1 CHAR(1) NOT NULL DEFAULT 'A'
GO
SELECT * FROM Test
go
DROP TABLE Test
"Daniela" <daniela@.perfilcs.com.br> wrote in message
news:113de01c41015$b05c1980$a501280a@.phx
.gbl...
Hello,
Im trying to add a new column in SQL Server 2000, but
in the specific table I dont get, in other tables I get.
This table has 7000 rows and when I try, the server get
processing and dontt finish. I already wait for 20
minutes and nothing.
Anyone can help me?
Thanks,
Daniela|||I did it by QA. In other tables I get, but only one I=20
don=B4t get. This table has many relations.=20
I don=B4t know what to do... Help.
Thanks,
Daniela
>--Original Message--
>Daniela
>I assume you did it by EM and not by QA
>This is T-SQL example how to add a new column
>CREATE TABLE Test
>(
> col INT
> )
>GO
>INSERT INTO Test VALUES (1)
>GO
>ALTER TABLE Test ADD col1 CHAR(1) NOT NULL DEFAULT 'A'
>GO
>SELECT * FROM Test
>go
>DROP TABLE Test
>
>"Daniela" <daniela@.perfilcs.com.br> wrote in message
> news:113de01c41015$b05c1980$a501280a@.phx
.gbl...
>Hello,
> I=B4m trying to add a new column in SQL Server 2000, but
>in the specific table I don=B4t get, in other tables I get.
>This table has 7000 rows and when I try, the server get
>processing and dont=B4t finish. I already wait for 20
>minutes and nothing.
> Anyone can help me?
> Thanks,
>Daniela
>
>.
>|||Perhaps you are bang blocked by another process. Check current activity
with sp_who.
Hope this helps.
Dan Guzman
SQL Server MVP
"Daniela" <daniela@.perfilcs.com.br> wrote in message
news:113de01c41015$b05c1980$a501280a@.phx
.gbl...
Hello,
Im trying to add a new column in SQL Server 2000, but
in the specific table I dont get, in other tables I get.
This table has 7000 rows and when I try, the server get
processing and dontt finish. I already wait for 20
minutes and nothing.
Anyone can help me?
Thanks,
Daniela|||Hi,
Uri can probably confirm this, but I've always understood that if you change
a table with Enterprise Manager, what it actually does is to copy the data
to a temp table, delete the original, then create a new table with the same
name as the old one, but with the changed properties, then copy all the data
back. This is why a) it can take so long, and b) when you later try to pick
up the table's properties in Query Analyzer it says that the object has been
dropped and re-created, so you have to refresh at the database level.
The most time-effective day I ever spent was learning how to use the ALTER
TABLE commands :-)
Richard
"Daniela" <daniela@.perfilcs.com.br> wrote in message
news:113de01c41015$b05c1980$a501280a@.phx
.gbl...
Hello,
Im trying to add a new column in SQL Server 2000, but
in the specific table I dont get, in other tables I get.
This table has 7000 rows and when I try, the server get
processing and dontt finish. I already wait for 20
minutes and nothing.
Anyone can help me?
Thanks,
Danielasql
Subscribe to:
Post Comments (Atom)
No comments:
Post a Comment