Solved

Convert varchar to text

Posted on 1998-10-13
3
549 Views
Last Modified: 2008-02-26
I need to convert a field from Varchar(255) to a Text field. How is that done in MSSQL 6.5 ?

(The table contains data)

Thanks for your help...
0
Comment
Question by:cisDK
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
  • 2
3 Comments
 

Author Comment

by:cisDK
ID: 1090531
Edited text of question
0
 
LVL 7

Accepted Solution

by:
spiridonov earned 100 total points
ID: 1090532
It can be done only in the following steps:
Rename old table
create new table with type changed
insert data into a new table
drop old table
There is no way in SQL server to change datatype in existing table.
0
 

Author Comment

by:cisDK
ID: 1090533
Ok, too bad... :/
0

Featured Post

Ransomware: The New Cyber Threat & How to Stop It

This infographic explains ransomware, type of malware that blocks access to your files or your systems and holds them hostage until a ransom is paid. It also examines the different types of ransomware and explains what you can do to thwart this sinister online threat.  

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

The Delta outage: 650 cancelled flights, more than 1200 delayed flights, thousands of frustrated customers, tens of millions of dollars in damages – plus untold reputational damage to one of the world’s most trusted airlines. All due to a catastroph…
I have a large data set and a SSIS package. How can I load this file in multi threading?
Via a live example, show how to set up a backup for SQL Server using a Maintenance Plan and how to schedule the job into SQL Server Agent.
Via a live example, show how to setup several different housekeeping processes for a SQL Server.

719 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question