<?xml version="1.0" encoding="UTF-8"?>
<rss version="2.0"
	xmlns:content="http://purl.org/rss/1.0/modules/content/"
	xmlns:wfw="http://wellformedweb.org/CommentAPI/"
	xmlns:dc="http://purl.org/dc/elements/1.1/"
	xmlns:atom="http://www.w3.org/2005/Atom"
	xmlns:sy="http://purl.org/rss/1.0/modules/syndication/"
	xmlns:slash="http://purl.org/rss/1.0/modules/slash/"
	>

<channel>
	<title>I&#039;m CaLendarW Blog &#187; batch</title>
	<atom:link href="http://wongkalun.idv.hk/tag/batch/feed/" rel="self" type="application/rss+xml" />
	<link>http://wongkalun.idv.hk</link>
	<description>任何時間，都要用內心既一點光，照亮世界</description>
	<lastBuildDate>Tue, 17 Aug 2010 15:00:02 +0000</lastBuildDate>
	<language>en</language>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
	<generator>http://wordpress.org/?v=3.0.1</generator>
		<item>
		<title>Sqlcmd</title>
		<link>http://wongkalun.idv.hk/2009/04/27/sqlcmd/</link>
		<comments>http://wongkalun.idv.hk/2009/04/27/sqlcmd/#comments</comments>
		<pubDate>Mon, 27 Apr 2009 14:41:22 +0000</pubDate>
		<dc:creator>calendarw</dc:creator>
				<category><![CDATA[database]]></category>
		<category><![CDATA[batch]]></category>

		<guid isPermaLink="false">http://wongkalun.idv.hk/?p=494</guid>
		<description><![CDATA[Project Development Phase 已經開始, 但因為部份 Design 未全面, 所以仲有好多 Drop Table, Create Table 及 Initialize Value 既動作要做, 因為係咁, 所以就上網搵左點樣在 command prompt 行 SQL file. Usage: Sqlcmd [-U login id] [-P password] [-S server] [-H hostname] [-E trusted connection] [-d use database name] [-l login timeout] [-t query timeout] [-h headers] [-s colseparator] [-w screen width] [-a [...]]]></description>
			<content:encoded><![CDATA[<p>Project Development Phase 已經開始, 但因為部份 Design 未全面, 所以仲有好多 Drop Table, Create Table 及 Initialize Value 既動作要做, 因為係咁, 所以就上網搵左點樣在 command prompt 行 SQL file.</p>
<blockquote><p>Usage: Sqlcmd [-U login id] [-P password] [-S server] [-H hostname] [-E trusted connection] [-d use database name] [-l login timeout]     [-t query timeout] [-h headers] [-s colseparator] [-w screen width] [-a packetsize] [-e echo input] [-I Enable Quoted Identifiers] [-c cmdend] [-L list servers[clean output]] [-q "cmdline query"] [-Q "cmdline query" and exit] [-m errorlevel] [-V severitylevel] [-W remove trailing spaces] [-u unicode output] [-r[0|1] msgs to stderr] [-i inputfile] [-o outputfile] [-z new password] [-f <codepage> | i:<codepage>[,o:<codepage>]] [-Z new password and exit] [-k[1|2] remove[replace] control characters] [-y variable length type display width] [-Y fixed length type display width] [-p[1] print statistics[colon format]] [-R use client regional setting] [-b On error batch abort] [-v var = "value"...] [-A dedicated admin connection] [-X[1] disable commands, startup script, environment variables [and exit]] [-x disable variable substitution] [-? show syntax summary]</p></blockquote>
<p>而自己就寫左個 batch 係 rebuild database:</p>
<pre class="brush: bash;">
sqlcmd -U calendarw -P password -S 192.168.1.10 -d testing_database -i Drop_Table.sql
sqlcmd -U calendarw -P password -S 192.168.1.10 -d testing_database -i Create_Table.sql
sqlcmd -U calendarw -P password -S 192.168.1.10 -d testing_database -i Init_Default_Value.sql
</pre>



		<!-- Added by WP-DragToShare-eXtended Plugin -->
		<script type="text/javascript">
			dtsv.dtse_post_494_permalink = 'http://wongkalun.idv.hk/2009/04/27/sqlcmd/';
			dtsv.dtse_post_494_title = 'Sqlcmd';
		</script>
		<!-- End of WP-DragToShare-eXtended Plugin -->]]></content:encoded>
			<wfw:commentRss>http://wongkalun.idv.hk/2009/04/27/sqlcmd/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
	</channel>
</rss>
