2013年11月25日 星期一

在在Eclipse Editor中切換大小寫

Lower case: CTRL+SHIFT+Y

Upper case: CTRL+SHIFT+X

2013年11月5日 星期二

找出符合某些條件的檔案,加以刪除

找出/tmp下,建立時間超過30天,由dsas這個user所建,而且是SAS開頭的檔案,把它刪除掉。
find /tmp -type f -name 'SAS*' -user dsas -ctime +30 -print -exec rm -f '{}' \;

2013年9月17日 星期二

Changing SQL Server collation to case insensitive from case sensitive

Check if the database is case insensitive:
select 1 where 'sql' = 'SQL' ;
If it returns 1, it is a case insensitive database

Alter to case insensitive:
ALTER DATABASE MyDatabase COLLATE Chinese_Taiwan_Stroke_CI_AS

Alter to case sensitive:
ALTER DATABASE MyDatabase COLLATE Chinese_Taiwan_Stroke_CS_AS

http://stackoverflow.com/questions/3296428/changing-sql-server-collation-to-case-insensitive-from-case-sensitive

2013年8月25日 星期日

從別的Table複製資料及欄位到新Table

Oracle寫法
create table  Table_New as select * from  Table_Old

SQL Server寫法
select   *   into   Table_New    from   Table_Old

2013年3月11日 星期一

crontab

Crontab command:
crontab –e

Crontab syntax:
A crontab file has five fields for specifying day , date and time followed by the command to be run at that interval.

*     *   *  *   *  command to be executed

-     -    -   -  -

|     |     |   |    |

|     |     |   |    +----- day of week (0 - 6) (Sunday=0)

|     |     |   +------- month (1 - 12)

|     |     +--------- day of month (1 - 31)

|     +----------- hour (0 - 23)

+------------- min (0 - 59)

* in the value field above means all legal values as in braces for that column.
The value column can have a * or a list of elements separated by commas. An element is either a number in the ranges shown above or two numbers in the range separated by a hyphen (meaning an inclusive range).
Notes
A. ) Repeat pattern like /2 for every 2 minutes or /10 for every 10 minutes is not supported by all operating systems. If you try to use it and crontab complains it is probably not supported.

B.) The specification of days can be made in two fields: month day and weekday. If both are specified in an entry, they are cumulative meaning both of the entries will get executed .

Crontab Example:
A line in crontab file like below removes the tmp files from /home/someuser/tmp each day at 6:30 PM.

30     18     *     *     *         rm /home/someuser/tmp/*

http://www.adminschoice.com/crontab-quick-reference

2013年1月13日 星期日

刪除skype訊息記錄

主視窗上點選"檔案">>"隱私"
跳出之對話框右邊點選"顯示進階選項"
"保存即時訊息紀錄時間"
選擇"無紀錄"每次登出後即刪除記錄
按一下"刪除記錄"刪除在這之前的紀錄
在 通話記錄 欄內
可以刪除
可以刪除單一記錄
也可以刪除多筆或特定對象的記錄(用 Ctrl 按著)

2012年11月18日 星期日

Tomcat 6 SSL

1. 產生keystore
C:\SSS\tomcat-6.0.36-x64\ssl>keytool -genkey -alias tomcat -keyalg RSA -keystore C:/SSS/tomcat-6.0.36-x64/ssl/server.keystore -validity 365
輸入 keystore 密碼:
重新輸入新密碼:
您的名字與姓氏為何?
  [Unknown]:  sign flow
您的編制單位名稱為何?
  [Unknown]:  it
您的組織名稱為何?
  [Unknown]:  ccc
您所在的城市或地區名稱為何?
  [Unknown]:  taipei
您所在的州及省份名稱為何?
  [Unknown]:  taiwan
該單位的二字國碼為何
  [Unknown]:  tw
CN=sign flow, OU=it, O=ccc, L=taipei, ST=taiwan, C=tw 正確嗎?
  [否]:  y
輸入 <tomcat> 的主密碼
        (RETURN 如果和 keystore 密碼相同):
C:\SSS\tomcat-6.0.36-x64\ssl>dir
磁碟區 C 中的磁碟是 System
磁碟區序號:  FEAC-AB27
C:\SSS\tomcat-6.0.36-x64\ssl 的目錄
2012/11/19  下午 01:45    <DIR>          .
2012/11/19  下午 01:45    <DIR>          ..
2012/11/19  下午 01:45             1,337 server.keystore
               1 個檔案           1,337 位元組
               2 個目錄  30,926,913,536 位元組可用
2. 修改C:\SSS\tomcat-6.0.36-x64\conf\server.xml
    <Connector port="8443" protocol="org.apache.coyote.http11.Http11Protocol" SSLEnabled="true"
               maxThreads="150" scheme="https" secure="true"
               keystoreFile="C:/SSS/tomcat-6.0.36-x64/ssl/server.keystore" keystorePass="changeit"
               clientAuth="false" sslProtocol="TLS" />
3. 重新啟動Tomcat,在網址列輸入https://localhost:8443
4. How to make IE8 trust a self-signed certificate in 20 irritating steps
http://stackoverflow.com/questions/681695/what-do-i-need-to-do-to-get-internet-explorer-8-to-accept-a-self-signed-certific

完整指令:
keytool -keystore server.jks -genkey -alias your.domain.name -keyalg RSA -dname "CN=%1,OU=IT,O=CMT,L=Taipei,S=Taiwan,C=TW" -keypass password -storepass password -validity 9999

2012年11月1日 星期四

SAS Bookmarks

Community

tagg
SWW Chatter
SWW Bulletin Board
Foundry

Product

Software Search
Software Downloads
Install Depot
SAS® Banking Intelligence Solutions
SAS Planning Application 2.0
AppDev Studio
SAS BI Tips
Primary SAS Catalog Categories
SAS Terminology
Products by Platform
IKE Global Packaging and Distribution Information
COS - Internal Order Request

Staff

Course List by Job Role
iNeed
Helpdesk Tips
Parts Database
SAS Virtual Learning Environment (VLE)

Tech

Deployment

JBoss Port Matrix
JBoss Port List
ENV File
SAS Resource Sharing System
SAS cookbook
SAS BI Java API
SAS API JavaDoc
JMP With Java
JDBC cookbook
SAS/SHARE JDBC Driver
SAS Graphics in Action!
SAS Documentation
Technical Support Search Application (TESSA)
Citrix XenApp
Architecture Community
Artifactory@ACL
SAS Library
Java Cross Reference Tool
TermWeb Professional
SDW Troubleshooting FAQ
Solutions Deployment FAQ
Troubleshooting Object Spawner
PROC Groovy By Example
Metadata Integration Technologies
DWT
DWT Metadata
Stored Process Web Application FAQ
SAS Stored Processes: Configurion
Log4SAS DBAppender: Quick Start Guide
Log4SAS Conversion Specifiers

IOM

PROC IOMOPERATE for IOM 9.3 - saspedia
Status/Monitoring Service Developer's Guide - saspedia
Status/Monitoring Service - saspedia
SAS 9.2 Spring Configuration Standards - saspedia
PlatformTestCase Groovy Class - saspedia
Authentication Service Developer's Guide - saspedia
Object Type Dictionary - Logical workspace server
getting 'no host credentials exist' error for sasadm@saspw user - Flat

TableServer

Create Firebird Databases
SAS Table Server
Firebird and SAS
Firebird - saspedia
Best Practices - saspedia
FAQ - saspedia
Table Server - saspedia
TKTS Internal Tech Docs
Embedded Jaybird JDBC Driver
Table Server Driver for JDBC: Reference Guide - saspedia
Table Server Driver for JDBC: Quick Start Guide - saspedia
Vulcan/Firebird
Transactional (Firebird) Table Driver: Reference Guide - saspedia

XML

XML cookbook - saspedia
XML Mapper - saspedia
XML department home page

Metadata

ACT & Security

The Paper 321-2009
Functions for Metadata Security Adm
SAS Common Metadata Model

Useful

Code Snippets
RubyMonk - Home
Ruby on Rails 實戰手冊
Ruby Taiwan 文件
RailsConf 2010
RegExr
Recent codes
Groovy - COM Scripting
Memory Limits for Windows
Programming in Scala, First Edition
Color Trends + Palettes :: COLOURlovers
Hacker News
Rails Searchable API Doc
Learn Python The Hard Way, 2nd Edition — Learn Python The Hard Way, 2nd Edition
NLP Python Book
Learn Ruby The Hard Way | Learn Ruby The Hard Way
Dive Into Python 3
The Art of Assembly Language Programming
Subtle Patterns | Free textures for your next web project
Interpreted Languages: PHP, Perl, Python, Ruby (Sheet One) - Hyperpolyglot
Colorbrewer: Color Advice for Maps
Point In Polygon - SQL
Point in Polygon - C
DuckDuckGo
Yesod Web Framework Book
The Architecture of Open Source Applications

WebDev

Paper.js — Paper.js
spin.js
d3.js
stack.js
font awesome
Ember.js - Documentation
Jasmine: BDD for your JavaScript
jsFiddle
JS Bin
Datejs - An open-source JavaScript Date Library
jQAPI - Alternative jQuery Documentation
HTTP Status Codes
Handlebars.js: Minimal Templating on Steroids
All The Cheat Sheets An Up To Date Web Designer Needs: CSS3, HTML5 and jQuery
jQuery Knob
css arrow
Octicons
JSHint
flotr2
Caching Tutorial
DailyJS
CSSDeck
Font Awesome, the iconic font designed for use with Twitter Bootstrap
Handsontable
Kickstrap

Extension Settings

TooManyTabs Settings

2012年6月21日 星期四

How to run windows photo viewer with command line

To start Windows Photo Viewer from command line you would have to use Code:

%SystemRoot%\System32\rundll32.exe "%ProgramFiles%\Windows Photo Viewer\PhotoViewer.dll", ImageView_Fullscreen %1

2012年6月19日 星期二

Print PDF with VBScript

Set WshShell = CreateObject("WScript.Shell")    
WshShell.Run chr(34) & "C:\Program Files (x86)\Adobe\Reader 10.0\Reader\AcroRd32.exe" _    
    & Chr(34) & " /p /h " & chr(34) & "d:\Temp\p0.600633652182296.pdf" & chr(34), 0    
Set WshShell = Nothing

2012年1月4日 星期三

SAS Useful Links


http://support.sas.com/documentation/onlinedoc/guide/customtasks/ EG addin


bugdb http://soul2.unx.sas.com:9090/TESSA/main/index2.jsp
training material http://swwafs.unx.sas.com/edu/depts/bcd/ctm.shtml
toolpool http://sww.sas.com/toolpool/