How can we add a column to a table without altering the
same?

Answer Posted / shoaib

you can add new column by using CAST keyword.

Eg:

Suppose your existing table say #EMP contain the following
Columns:

empid,
empname,
empaddr

you want to add empsal columns.

Query:
select
empid,
empname,
empaddr,
(null as decimal(18,2))empsal
from #EMP
into #EMP1;

Is This Answer Correct ?    18 Yes 10 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

How does sybase replication work?

493


What are the advantages that you can get from mainframe connect in sybase?

479


What is the use of 'with check' option in views?

480


Explain mirroring?

490


Why am I running out of locks on the replicate side in sybase ?

526






How do I start sybase control center in windows?

381


How to remove row affected and dashes?

441


Explain update statistics.

500


Differences between clustered and non-clustered in sybase?

419


Is sybase free?

466


How to check sybase database status in linux?

471


What is a coalesce? What is the equivalent of oracle/db2 coalesce function in sybase?

489


Explanation about replication server software?

500


How do I add a sybase driver to sql developer?

471


What measures are there to increase the db space?

483