|
|
|
Junior Member
      
Group: Forum Members
Last Login: 8/25/2008 5:46:43 PM
Posts: 23,
Visits: 73
|
|
I changed the user default characterset to LATIN. But whenever I am using CREATE TABLE AS statement, the default characterset for string fields are still unicode. For example:
create table test as
(
select year, state, county,
'abc' as flg
from table1
group by 1,2,3,4) with data
unique primary index (year, state, county, flg);
show table test;
The field 'flg' is
flg VARCHAR(3) CHARACTER SET UNICODE NOT CASESPECIFIC
How can I change the default characterset to 'LATIN'
Ivy
|
|
|
|
|
Forum Newbie
      
Group: Forum Members
Last Login: 11/3/2008 11:41:34 AM
Posts: 3,
Visits: 7
|
|
String literals are always Unicode strings in the Teradata database. The user default characterset does not apply to string literals.
You could add the char latin column after the 'create table as' with an 'alter table' using a default value of 'abc'.
--i18nguy
|
|
|
|
|
Supreme Being
      
Group: Forum Members
Last Login: 11/12/2008 9:19:53 PM
Posts: 469,
Visits: 463
|
|
|
One trick is to use the translate function in the select to explicitly state the fields as LATIN
|
|
|
|