🚀 go-pugleaf

RetroBBS NetNews Server

Inspired by RockSolid Light RIP Retro Guy

Article View: bit.databases.mssql-l
Article #96

Re: how to alter table?

#96
From: Dan Guzman
Date: Fri, 26 May 2000 00:00
32 lines
2213 bytes
Try:  ALTER TABLE register ALTER COLUMN STATE char(50)

You can find details in Transact-SQL help or the Books Online.

Please don't post to so many newsgroups.


Hope this helps.

Yeh Hung Tan <hung79@tm.net.my> wrote in message
news:392e4181.0@news2.tm.net.my...
> I am develop web site using ASP and SQL server.
> Anyone tell me how to do modify the datatype of a table field?
>
> I using the following command but it doesn't work.
>
> sqlStatement = "ALTER TABLE register MODIFY STATE char(50)"
> rs.open sqlStatement,conn,1,3
>
> the error message return:
>
> Microsoft OLE DB Provider for ODBC Drivers error '80040e14'
>
> [Microsoft][ODBC SQL Server Driver][SQL Server]Line 1: Incorrect syntax
near
> 'STATE'.
>
>
>
>
>
>
Technical Details
Message-ID: <0duX4.14950$Sx.65879@newsread2.prod.itd.earthlink.net>
Path: arc1-ca.pugleaf.net!unknown!not-for-mail
References: <392e4181.0@news2.tm.net.my>

Show Full Headers
Complete Article Headers
X-Google-Language: ENGLISH,ASCII-7-bit
X-Google-Thread: fb9aa,9bffa6505087adae
X-Google-Attributes: gidfb9aa,public
X-Google-Thread: 107c4e,9bffa6505087adae
X-Google-Attributes: gid107c4e,public
X-Google-Thread: f6611,9bffa6505087adae
X-Google-Attributes: gidf6611,public
X-Google-Thread: fa31c,9bffa6505087adae
X-Google-Attributes: gidfa31c,public
X-Google-Thread: 10cb39,9bffa6505087adae
X-Google-Attributes: gid10cb39,public
X-Google-Thread: 107d7d,9bffa6505087adae
X-Google-Attributes: gid107d7d,public
X-Google-Thread: 104de1,9bffa6505087adae
X-Google-Attributes: gid104de1,public
From: "Dan Guzman" <DGuzman@nospamplease-earthlink.net>
Subject: Re: how to alter table?
Date: 2000/05/26
Message-ID: <0duX4.14950$Sx.65879@newsread2.prod.itd.earthlink.net>
X-Deja-AN: 627563641
References: <392e4181.0@news2.tm.net.my>
X-Priority: 3
X-MimeOLE: Produced By Microsoft MimeOLE V5.00.2314.1300
X-Complaints-To: abuse@earthlink.net
X-Trace: newsread2.prod.itd.earthlink.net 959344572 24.217.45.157 (Fri, 26 May 2000 05:36:12 PDT)
Organization: EarthLink Inc. -- http://www.EarthLink.net
X-MSMail-Priority: Normal
NNTP-Posting-Date: Fri, 26 May 2000 05:36:12 PDT
Newsgroups: bit.databases.mssql-l,comp.databases.ms-sqlserver,microsoft.public.inetserver.asp.components,microsoft.public.inetserver.asp.db,microsoft.public.inetserver.asp.faq,microsoft.public.inetserver.asp.general,microsoft.public.sqlserver.connect,microsoft