Unix Technical Forum

Changing the Data Type of a Column(From SmallInt to Decmial)

This is a discussion on Changing the Data Type of a Column(From SmallInt to Decmial) within the DB2 forums, part of the Database Server Software category; --> Hi All, Can anyone tell me how to change the date type of a column from smallint to decimal ...


Go Back   Unix Technical Forum > Database Server Software > DB2

FAQ Members List Calendar Search Today's Posts Mark Forums Read
  #1 (permalink)  
Old 02-27-2008, 07:56 AM
siujean@gmail.com
 
Posts: n/a
Default Changing the Data Type of a Column(From SmallInt to Decmial)

Hi All,

Can anyone tell me how to change the date type of a column from
smallint to decimal in db2?
Thanks

Regards
Siujean

Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
Reply With Quote
  #2 (permalink)  
Old 02-27-2008, 07:56 AM
Knut Stolze
 
Posts: n/a
Default Re: Changing the Data Type of a Column(From SmallInt to Decmial)

siujean@gmail.com wrote:

> Hi All,
>
> Can anyone tell me how to change the date type of a column from
> smallint to decimal in db2?


In V8: recreate the table
In V9: ALTER TABLE ... ALTER COLUMN ... SET DATA TYPE ... + REORG

--
Knut Stolze
DB2 Information Integration Development
IBM Germany
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
Reply With Quote
  #3 (permalink)  
Old 02-27-2008, 07:56 AM
jefftyzzer
 
Posts: n/a
Default Re: Changing the Data Type of a Column(From SmallInt to Decmial)

In addition to the above options, it might be worth your while to
investigate the ALTOBJ stored procedure.

http://www.gatago.com/comp/databases.../24027879.html

--Jeff

Knut Stolze wrote:
> siujean@gmail.com wrote:
>
> > Hi All,
> >
> > Can anyone tell me how to change the date type of a column from
> > smallint to decimal in db2?

>
> In V8: recreate the table
> In V9: ALTER TABLE ... ALTER COLUMN ... SET DATA TYPE ... + REORG
>
> --
> Knut Stolze
> DB2 Information Integration Development
> IBM Germany


Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
Reply With Quote
Reply


Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On
Forum Jump


All times are GMT. The time now is 10:38 AM.


Powered by vBulletin® Version 3.6.5
Copyright ©2000 - 2008, Jelsoft Enterprises Ltd.
SEO by vBSEO 3.2.0
www.UnixAdminTalk.com