This week's book giveaway is in the Clojure forum.
We're giving away four copies of Clojure in Action and have Amit Rathore and Francis Avila on-line!
See this thread for details.
Win a copy of Clojure in Action this week in the Clojure forum!
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

need to increase the sizeof this column

 
deo swaroop
Ranch Hand
Posts: 30
  • 0
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi All,

We are using oracle -10G. We have a table CONF and a particular column is defined as VALUE NVARCHAR2(1024) . I need to increase the sizeof this column as it have to handle more data in future.

Please suggest.


Regards,
deo swaroop
 
Christophe Verré
Sheriff
Pie
Posts: 14691
16
Eclipse IDE Ubuntu VI Editor
  • 0
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
ALTER TABLE CONF MODIFY VALUE NVARCHAR2(XXXX) doesn't work ?
 
deo swaroop
Ranch Hand
Posts: 30
  • 0
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator

we are targeting to insert some 1 lakh caracters. nvarchar2 supports only till 2000.
 
Christophe Verré
Sheriff
Pie
Posts: 14691
16
Eclipse IDE Ubuntu VI Editor
  • 0
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
You could use an NCLOB instead.
 
deo swaroop
Ranch Hand
Posts: 30
  • 0
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Will we be able to modify even when there is data existing in the table? any other data type?
 
Christophe Verré
Sheriff
Pie
Posts: 14691
16
Eclipse IDE Ubuntu VI Editor
  • 0
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
deo swaroop wrote:Will we be able to modify even when there is data existing in the table? any other data type?

I think so. Backup your table, and use an "alter table" like the one above.
 
Christophe Verré
Sheriff
Pie
Posts: 14691
16
Eclipse IDE Ubuntu VI Editor
  • 0
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Mmmh, after some thought, not sure you can. Try it, but if you can't, you can do this instead :
1. Create a new NCLOB column
2. Copy the content of the old column to the new column using UPDATE
3. Drop the old column
4. Rename the new column
 
deo swaroop
Ranch Hand
Posts: 30
  • 0
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi Christophe ,

I really appreciate your help and quick response. Let me iterarte throuth the possible options.

Thanks.
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic