Subject | Re: [ib-support] Changing charset in domains |
---|---|
Author | Ali Gokcen |
Post date | 2001-01-29T12:54:22Z |
yes, langref.pdf page
28.
----- Original Message -----From: Riho-Rene EllermaaSent: Monday, January 29, 2001 2:36 PMSubject: RE: [ib-support] Changing charset in domainsWhat about something in lines
ALTER TABLE mytable ALTER mycolumn ....
to change from mydomain into varchar(20) charset win1252
Riho-Rene Ellermaa
senior programmer
Hansabank
>
>
> 0- drop index of this field if exists
> 1- add a new column
> alter table tx add newcol varchar(20) character set none;
> 2- copy the data to it.
> update tx set newcol = oldcol;
> 3- drop old column
> alter table tx drop oldcol;
> 4- recreate oldcol with new char set that you need
> alter table tx add oldcol varchar(20) character set none;
> 5- copy back the data.
> update tx set oldcol = newcol;
> 6- drop the temporary column
> alter table tx drop column newcol;
> 7- recreate index of this field if you need.
>
> Write a script like this and run it. (or write a SP and call )
> There is may be other way to do it via playing system
> tables, but i dont
> know how.
>
> I hope help this.
>
> Hi!
>
> I have domain varchar(20) which is used in couple of tables.
> I want to change it's charset from none to win1252. How can I
> do it without
> dropping any tables. I must do it in my customers database, so I would
> prefer to autorun some script inside my program.
>
> Riho-Rene Ellermaa
> senior programmer
> Hansabank
>
To unsubscribe from this group, send an email to:
ib-support-unsubscribe@egroups.com