Notice
Recent Posts
Recent Comments
Link
일 | 월 | 화 | 수 | 목 | 금 | 토 |
---|---|---|---|---|---|---|
1 | 2 | 3 | 4 | 5 | ||
6 | 7 | 8 | 9 | 10 | 11 | 12 |
13 | 14 | 15 | 16 | 17 | 18 | 19 |
20 | 21 | 22 | 23 | 24 | 25 | 26 |
27 | 28 | 29 | 30 | 31 |
Tags
- Android
- jsp
- Eclipse
- javascript
- Web Service
- 웹뷰
- Redirect
- 자바
- C#
- varags
- Maven
- Java
- decompiler
- 자바스크립트
- STS
- MANTIS
- Apache Lucene
- 안드로이드
- scrollView
- html
- MSsql
- 이클립스
- TextBox
- Bootstrap
- MS-SQL
- SpringSource Tool Suite
- asp.net
- 웹 서비스
- WebView
- 컬럼명
Archives
- Today
- Total
목록2016/03 (2)
bboks.net™
리눅스 경과시간 출력
※ centOS에서 bc를 사용하기 위해서는 설치를 해야한다. (yum install bc) bash 스크립트로 작업을 처리하고선 그 경과 시간을 측정하고자 하려고 한다. 스크립트 특성상 다양한 방법이 있겠지만, date, bc, awk 를 이용해서 만들어 봤다. #!/bin/bash beginTime=$(date +%s%N) # 여기에 작업 내용을 구현한다 sleep 1 endTime=$(date +%s%N) elapsed=`echo "($endTime - $beginTime) / 1000000" | bc` elapsedSec=`echo "scale=6;$elapsed / 1000" | bc | awk '{printf "%.6f", $1}'` echo TOTAL: $elapsedSec sec date ..
Operating System/Linux
2016. 3. 28. 14:22
How to Execute PostgreSQL Commands Inside Unix Shell Scripts
Question: How do I executed PostgreSQL Commands inside a Linux / UNIX shell script?Answer: With the help of the psql interactive terminal, you can execute the psql commands from the shell script. For this purpose, you should enable the password less login by pg_hba.conf, or .pgpass. Syntax psql DBNAME USERNAME
Operating System/Linux
2016. 3. 28. 13:39