想在存储过程的参数timestamp定义为非默认6位小数长度的,可是遇到下面问题,请大家帮忙看看。 SQL> create or replace procedure SP_TS_IO(arg in out timestamp(8)) as 2 begin 3 update sp set ts=arg where param='I'; 4 select ts into arg from sp where param='O'; 5 commit; 6 end; 7 / Warning: Procedure created with compilation errors. SQL> show errors; Errors for PROCEDURE SP_TS_IO: LIN...
by benh - Oracle - 2008-08-13 14:17:09 阅读(2442) 回复(1)
請問 Sybase 有沒有像 DB2 的 current timestamp 這種特殊字串啊? 因為我用 current timestamp 結果就變成 "current timestamp"字串而不是當時的時間戳記(但是DB2是可以的) thx 有先用 timestamp 搜尋過版面了,但是找不到資料只好發帖來問... 在線等待 :)
create table test (id int(3) unsigned auto_increment, date1 timestamp(10),primary key(id)); insert into test set id = 1; select * from test; 请问显示结果为什么还是2009-04-07 13:48:07这种格式,而不是2009040713,timestamp已经定义为(10)了
大家好! 小弟有个问题,我现在做数据移植,之前老表中有一个char(26)型的字段保存着日期时间(例如:2008-07-14-07.47.49.931784),现在需要移植到一张新表中,该字段对应的是个timestamp 类型的字段,我该如何处理?谢谢.还有那为兄弟能帮我解释下timestamp类型吗?查了很多都说的不清楚.
我用这个SQL语句,a 是timestamp 类型 insert into test1 ( a) values('2007-01-01 01:01:01') 抛出如下错误: SQL State: 22007 Vendor Code: -180 Message: [SQL0180] Syntax of date, time, or timestamp value not valid. Cause . . . . . : The string representation of a date, time, or timestamp value does not conform to the syntax for the specified or implied data type and format. *N is either the charact...
ASE里面的timestamp 有什么作用啊? 看了一些资料好象 是每次添加或修改记录时系统自动生成的. timestamp和datetime的格式是一样的吗? 为什么我查询出来是 1> select timestamp from song_info 2> go timestamp ------------------ 0x00000000000245a9 这样奇怪的东东? 怎么转换成日期时间呢? 请哪位前辈指点一下.
平台 WAS 5.0.2.17 jdk 1.3.1 jdbc classes12.jar oracle 9.2.0.7 ResultSet rset=null; java.sql.Connection conn = null; Class.forName("oracle.jdbc.driver.OracleDriver"); conn = DriverManager.getConnection(url,"user","pwd"); stmt= conn.createStatement(); strQuerySql="select CUST_ID,LAST_UPDATE_TIME from CUST"; //LAST_UPDATE_TIME是timestamp类型 rset = stmt.executeQuery(strQuerySql);//这一...
db2的timestamp类型怎样转换成'YYYYMMDD'格式的字符串阿? char()只能指定ISO(YYYY-MM-DD)、USA(MM/DD/YYYY)等格式。 to_char()只有一种有效格式:'YYYY-MM-DD HH24:MI:SS'。 :em20: 我想要的是:'YYYYMMDDHH24MISS'。 怎样转换阿?求助大虾指点。 IBM做的东西不至于这么弱智吧。