2008-12-19

Oracle XE


Oracle Database 10g Express Edition / Oracle XE / OracleXE

Oracle Database 10g Express Edition (Oracle Database XE) is an entry-level, small-footprint database based on the Oracle Database 10g Release 2 code base that's free to develop, deploy, and distribute; fast to download; and simple to administer.



更改 admin password (ID: SYS or SYSTEM) 必須在本機上使用 SQLPLUS:

C:\WINDOWS>sqlplus /nolog

SQL*Plus: Release 10.2.0.1.0 - Production

Copyright (c) 1982, 2005, Oracle. All rights reserved.

SQL> connect / as sysdba
已連線.
SQL> ALTER USER SYS IDENTIFIED BY newpassword
2
SQL> run
1* ALTER USER SYS IDENTIFIED BY newpassword

已更改使用者.

SQL>

2008-12-17

JavaScript DateTime Local/UTC/TPE

注意剪貼後請將 "< " 空白移除
< script language=javaScript>
< ! -- Beginning of JavaScript ------------------------------------------------------
// -------- Get PC Local datetime --------
var Now = new Date()
var month = Now.getMonth() + 1
var day = Now.getDate()
var year = Now.getFullYear()
//document.write(month + "/" + day + "/" + year)
var hours=Now.getHours()
var minutes=Now.getMinutes()
var seconds=Now.getSeconds()
if (hours==0) hours=12
if (minutes<=9) minutes="0"+minutes
if (seconds<=9) seconds="0"+seconds
LocalDatetime= year+"/"+month+"/"+day+" "+hours+":"+minutes+":"+seconds
// -------- Get UTC datetime --------
var month = Now2.getUTCMonth() + 1
var day = Now2.getUTCDate()
var year = Now2.getUTCFullYear()
var hours=Now2.getUTCHours()
var minutes=Now2.getUTCMinutes()
var seconds=Now2.getUTCSeconds()
if (hours==0) hours=12
if (minutes<=9) minutes="0"+minutes
if (seconds<=9) seconds="0"+seconds
UTCdatetime= year+"/"+month+"/"+day+" "+hours+":"+minutes+":"+seconds
//-------- Get TPE datetime
var Now = new Date()
//var TPE = (Now.getTime() + (Now.getTimezoneOffset() * 60000) )
var utc_int = (Now.getTime() + (Now.getTimezoneOffset() * 60000) ) //msec integer
var NowUTC = new Date(utc_int )
var NowTPE = new Date(utc_int + (3600000* 8 )) // NowUTC add 8 hours
var month = NowTPE.getMonth() + 1
var day = NowTPE.getDate()
var year = NowTPE.getFullYear()
var hours=NowTPE.getHours()
var minutes=NowTPE.getMinutes()
var seconds=NowTPE.getSeconds()
if (hours==0) hours=12
if (minutes<=9) minutes="0"+minutes
if (seconds<=9) seconds="0"+seconds
TPEdatetime= year+"/"+month+"/"+day+" "+hours+":"+minutes+":"+seconds
// - End of JavaScript ------------------------------------------------------------ -->
< /script>