0

Is it possible to configure the implicit typing rule in Oracle Server (at least version 10g) ? If not a link to the documentation of the rules and how Oracle parameters impact the rules would be great.

For exemple when executing this query :

SELECT '' AS A FROM DUAL

Oracle will report that column A has VARCHAR(0) type on Oracle 10g and VARCHAR(32) on Oracle 9i.

Thanks

4

2 回答 2

1

你可以明确地说,它适用于所有版本的 Oracle:

SQL> CREATE VIEW test AS SELECT CAST(NULL AS VARCHAR2(32)) var32 FROM DUAL;

View created

SQL> desc test
Name  Type         Nullable Default Comments 
----- ------------ -------- ------- -------- 
VAR32 VARCHAR2(32) Y                         
于 2010-02-09T21:16:04.900 回答
0

正如 Gary 所说,默认数据类型是 CHAR....

SQL> create view v23 as select '' a from dual
  2  /

View created

SQL> desc a
Name               Null?    Type
------------------ -------- --------------- 
A                           CHAR             

你想解决什么问题?

于 2010-02-10T06:15:22.477 回答