<?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/"
	xmlns:georss="http://www.georss.org/georss" xmlns:geo="http://www.w3.org/2003/01/geo/wgs84_pos#" xmlns:media="http://search.yahoo.com/mrss/"
	>

<channel>
	<title>Option Explicit</title>
	<atom:link href="http://optionexplicit.wordpress.com/feed/" rel="self" type="application/rss+xml" />
	<link>http://optionexplicit.wordpress.com</link>
	<description>Stated Clearly and in Detail, Leaving No Room for Confusion</description>
	<lastBuildDate>Wed, 16 Mar 2011 03:35:16 +0000</lastBuildDate>
	<language>en</language>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
	<generator>http://wordpress.com/</generator>
<cloud domain='optionexplicit.wordpress.com' port='80' path='/?rsscloud=notify' registerProcedure='' protocol='http-post' />
<image>
		<url>http://s2.wp.com/i/buttonw-com.png</url>
		<title>Option Explicit</title>
		<link>http://optionexplicit.wordpress.com</link>
	</image>
	<atom:link rel="search" type="application/opensearchdescription+xml" href="http://optionexplicit.wordpress.com/osd.xml" title="Option Explicit" />
	<atom:link rel='hub' href='http://optionexplicit.wordpress.com/?pushpress=hub'/>
		<item>
		<title>How to change productkey Mac Office 2008</title>
		<link>http://optionexplicit.wordpress.com/2010/10/04/how-to-change-productkey-mac-office-2008/</link>
		<comments>http://optionexplicit.wordpress.com/2010/10/04/how-to-change-productkey-mac-office-2008/#comments</comments>
		<pubDate>Mon, 04 Oct 2010 03:36:05 +0000</pubDate>
		<dc:creator>optionexplicit</dc:creator>
				<category><![CDATA[Mac]]></category>

		<guid isPermaLink="false">http://optionexplicit.wordpress.com/?p=71</guid>
		<description><![CDATA[Untuk menghapus Aplikasi Mac Office gunakan &#8220;Remove Office&#8221; tools di Application &#62; Microsoft Office &#62; Additional Tools &#62; Remove Office Setelah melakukan Remove Office ini, apabila kita re-install Mac Office lagi dengan versi yang sama, maka Mac Office masih mendeteksi product key dari Mac Office sebelumnya. Untuk benar-benar full-reinstall termasuk memasukkan product key baru, maka [...]<img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=optionexplicit.wordpress.com&amp;blog=4074106&amp;post=71&amp;subd=optionexplicit&amp;ref=&amp;feed=1" width="1" height="1" />]]></description>
			<content:encoded><![CDATA[<p>Untuk menghapus Aplikasi Mac Office gunakan &#8220;Remove Office&#8221; tools di Application &gt; Microsoft Office &gt; Additional Tools &gt; Remove Office</p>
<p>Setelah melakukan Remove Office ini, apabila kita re-install Mac Office lagi dengan versi yang sama, maka Mac Office masih mendeteksi product key dari Mac Office sebelumnya. Untuk benar-benar full-reinstall termasuk memasukkan product key baru, maka bisa dilakukan dengan menghapus 2 file sebagai berikut :<br />
~/Library/Preferences/Microsoft/Office 2008/Microsoft Office 2008  Settings.plist<br />
/Applications/Microsoft Office 2008/Office/OfficePID.plist</p>
<p>Ok selamat menikmati Clean Mac Office!</p>
<br />  <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gocomments/optionexplicit.wordpress.com/71/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/comments/optionexplicit.wordpress.com/71/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godelicious/optionexplicit.wordpress.com/71/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/delicious/optionexplicit.wordpress.com/71/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gofacebook/optionexplicit.wordpress.com/71/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/facebook/optionexplicit.wordpress.com/71/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gotwitter/optionexplicit.wordpress.com/71/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/twitter/optionexplicit.wordpress.com/71/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gostumble/optionexplicit.wordpress.com/71/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/stumble/optionexplicit.wordpress.com/71/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godigg/optionexplicit.wordpress.com/71/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/digg/optionexplicit.wordpress.com/71/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/goreddit/optionexplicit.wordpress.com/71/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/reddit/optionexplicit.wordpress.com/71/" /></a> <img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=optionexplicit.wordpress.com&amp;blog=4074106&amp;post=71&amp;subd=optionexplicit&amp;ref=&amp;feed=1" width="1" height="1" />]]></content:encoded>
			<wfw:commentRss>http://optionexplicit.wordpress.com/2010/10/04/how-to-change-productkey-mac-office-2008/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
	
		<media:content url="http://0.gravatar.com/avatar/edeab4aeb5fd4b32e0a095916ca15e88?s=96&#38;d=identicon&#38;r=G" medium="image">
			<media:title type="html">optionexplicit</media:title>
		</media:content>
	</item>
		<item>
		<title>Problem koneksi Navicat-MySQL ke MAMP Pro</title>
		<link>http://optionexplicit.wordpress.com/2010/06/02/problem-koneksi-navicat-mysql-ke-mamp-pro/</link>
		<comments>http://optionexplicit.wordpress.com/2010/06/02/problem-koneksi-navicat-mysql-ke-mamp-pro/#comments</comments>
		<pubDate>Wed, 02 Jun 2010 10:30:10 +0000</pubDate>
		<dc:creator>optionexplicit</dc:creator>
				<category><![CDATA[Database]]></category>
		<category><![CDATA[Mac]]></category>

		<guid isPermaLink="false">http://optionexplicit.wordpress.com/?p=68</guid>
		<description><![CDATA[Aku mempunyai MAMP Pro sudah sudah jalan stabil di Mac Tiger, termasuk MySQL, PhpMyAdmin dan Apache. Aku mencoba memasang Navicat Premium sebagai MySQL GUI. Tetapi muncul masalah, setiap kali mencoba melakukan koneksi ke MySQL di localhost selalu gagal (Can&#8217;t connect bla bla&#8230;) tetapi kalau digunakan untuk melakukan koneksi ke MySQL ke Server Linux berhasil. Setelah [...]<img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=optionexplicit.wordpress.com&amp;blog=4074106&amp;post=68&amp;subd=optionexplicit&amp;ref=&amp;feed=1" width="1" height="1" />]]></description>
			<content:encoded><![CDATA[<p>Aku mempunyai MAMP Pro sudah sudah jalan stabil di Mac Tiger, termasuk MySQL, PhpMyAdmin dan Apache. Aku mencoba memasang Navicat Premium sebagai MySQL GUI. Tetapi muncul masalah, setiap kali mencoba melakukan koneksi ke MySQL di localhost selalu gagal (Can&#8217;t connect bla bla&#8230;) tetapi kalau digunakan untuk melakukan koneksi ke MySQL ke Server Linux berhasil.</p>
<p>Setelah browsing dan mencoba-coba, solusi yang bisa dilakukan dengan cara menggunakan socket file untuk koneksi ke localhost.</p>
<p>Setting di Navicatnya sebagai berikut :</p>
<p>Masuk ke Connection Properties-nya Navicat, klik Tab Advanced, pilih option &#8220;Use socket file for localhost connection&#8221; dan arahkan Socket File Path = /Applications/MAMP/tmp/mysql/mysql.sock</p>
<p><a href="http://optionexplicit.files.wordpress.com/2010/06/picture-230.png"><img class="alignnone size-medium wp-image-69" title="Picture 230" src="http://optionexplicit.files.wordpress.com/2010/06/picture-230.png?w=300&#038;h=264" alt="" width="300" height="264" /></a></p>
<p>Dan tentunya lengkapi juga setting User-Password di General Tab.</p>
<br />  <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gocomments/optionexplicit.wordpress.com/68/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/comments/optionexplicit.wordpress.com/68/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godelicious/optionexplicit.wordpress.com/68/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/delicious/optionexplicit.wordpress.com/68/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gofacebook/optionexplicit.wordpress.com/68/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/facebook/optionexplicit.wordpress.com/68/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gotwitter/optionexplicit.wordpress.com/68/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/twitter/optionexplicit.wordpress.com/68/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gostumble/optionexplicit.wordpress.com/68/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/stumble/optionexplicit.wordpress.com/68/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godigg/optionexplicit.wordpress.com/68/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/digg/optionexplicit.wordpress.com/68/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/goreddit/optionexplicit.wordpress.com/68/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/reddit/optionexplicit.wordpress.com/68/" /></a> <img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=optionexplicit.wordpress.com&amp;blog=4074106&amp;post=68&amp;subd=optionexplicit&amp;ref=&amp;feed=1" width="1" height="1" />]]></content:encoded>
			<wfw:commentRss>http://optionexplicit.wordpress.com/2010/06/02/problem-koneksi-navicat-mysql-ke-mamp-pro/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
	
		<media:content url="http://0.gravatar.com/avatar/edeab4aeb5fd4b32e0a095916ca15e88?s=96&#38;d=identicon&#38;r=G" medium="image">
			<media:title type="html">optionexplicit</media:title>
		</media:content>

		<media:content url="http://optionexplicit.files.wordpress.com/2010/06/picture-230.png?w=300" medium="image">
			<media:title type="html">Picture 230</media:title>
		</media:content>
	</item>
		<item>
		<title>VbCrLf di PHP</title>
		<link>http://optionexplicit.wordpress.com/2010/01/26/vbcrlf-di-php/</link>
		<comments>http://optionexplicit.wordpress.com/2010/01/26/vbcrlf-di-php/#comments</comments>
		<pubDate>Tue, 26 Jan 2010 10:39:06 +0000</pubDate>
		<dc:creator>optionexplicit</dc:creator>
				<category><![CDATA[Programming]]></category>

		<guid isPermaLink="false">http://optionexplicit.wordpress.com/?p=64</guid>
		<description><![CDATA[simple script untuk replace [new line - enter] menjadi &#60;br&#62; di PHP : $tampil = preg_replace(&#8216;/(\r\n&#124;\n&#124;\r&#124;\f)/U&#8217;, &#8220;&#60;br /&#62;&#8221;, $text); example : &#60;?php $t = $_POST['test']; $tampil = preg_replace(&#8216;/(\r\n&#124;\n&#124;\r&#124;\f)/U&#8217;, &#8220;&#60;br /&#62;&#8221;, $t); echo &#8216;test : &#8216;. $tampil; ?&#62; &#60;html&#62; &#60;head&#62; &#60;title&#62;test&#60;/title&#62; &#60;/head&#62; &#60;body&#62; &#60;form name=&#8221;test&#8221; method=&#8221;post&#8221; action=&#8221;test.php&#8221;&#62; ini inputnya : &#60;br&#62; &#60;textarea name=&#8221;test&#8221; rows=&#8221;20&#8243; cols=&#8221;80&#8243;&#62;&#60;/textarea&#62;&#60;br&#62; &#60;input [...]<img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=optionexplicit.wordpress.com&amp;blog=4074106&amp;post=64&amp;subd=optionexplicit&amp;ref=&amp;feed=1" width="1" height="1" />]]></description>
			<content:encoded><![CDATA[<p>simple script untuk replace [new line - enter] menjadi &lt;br&gt; di PHP :</p>
<p>$tampil = preg_replace(&#8216;/(\r\n|\n|\r|\f)/U&#8217;, &#8220;&lt;br /&gt;&#8221;, $text);</p>
<p>example :</p>
<p>&lt;?php</p>
<p>$t = $_POST['test'];</p>
<p>$tampil = preg_replace(&#8216;/(\r\n|\n|\r|\f)/U&#8217;, &#8220;&lt;br /&gt;&#8221;, $t);<br />
echo &#8216;test : &#8216;. $tampil;</p>
<p>?&gt;<br />
&lt;html&gt;<br />
&lt;head&gt;<br />
&lt;title&gt;test&lt;/title&gt;<br />
&lt;/head&gt;<br />
&lt;body&gt;</p>
<p>&lt;form name=&#8221;test&#8221; method=&#8221;post&#8221; action=&#8221;test.php&#8221;&gt;<br />
ini inputnya : &lt;br&gt;<br />
&lt;textarea name=&#8221;test&#8221; rows=&#8221;20&#8243; cols=&#8221;80&#8243;&gt;&lt;/textarea&gt;&lt;br&gt;<br />
&lt;input type=&#8221;submit&#8221; value=&#8221;submit&#8221; name=&#8221;submit&#8221;&gt;&lt;br&gt;&lt;br&gt;&lt;br&gt;<br />
&lt;/form&gt;</p>
<p>ini hasilnya : &lt;br&gt;<br />
&lt;textarea name=&#8221;test2&#8243; rows=&#8221;20&#8243; cols=&#8221;80&#8243;&gt;&lt;?=$tampil?&gt;&lt;/textarea&gt;&lt;br&gt;<br />
&lt;/body&gt;<br />
&lt;/html&gt;</p>
<br />  <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gocomments/optionexplicit.wordpress.com/64/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/comments/optionexplicit.wordpress.com/64/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godelicious/optionexplicit.wordpress.com/64/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/delicious/optionexplicit.wordpress.com/64/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gofacebook/optionexplicit.wordpress.com/64/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/facebook/optionexplicit.wordpress.com/64/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gotwitter/optionexplicit.wordpress.com/64/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/twitter/optionexplicit.wordpress.com/64/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gostumble/optionexplicit.wordpress.com/64/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/stumble/optionexplicit.wordpress.com/64/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godigg/optionexplicit.wordpress.com/64/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/digg/optionexplicit.wordpress.com/64/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/goreddit/optionexplicit.wordpress.com/64/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/reddit/optionexplicit.wordpress.com/64/" /></a> <img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=optionexplicit.wordpress.com&amp;blog=4074106&amp;post=64&amp;subd=optionexplicit&amp;ref=&amp;feed=1" width="1" height="1" />]]></content:encoded>
			<wfw:commentRss>http://optionexplicit.wordpress.com/2010/01/26/vbcrlf-di-php/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
	
		<media:content url="http://0.gravatar.com/avatar/edeab4aeb5fd4b32e0a095916ca15e88?s=96&#38;d=identicon&#38;r=G" medium="image">
			<media:title type="html">optionexplicit</media:title>
		</media:content>
	</item>
		<item>
		<title>Howto: Remotely disconnect a Terminal Services Session</title>
		<link>http://optionexplicit.wordpress.com/2010/01/04/howto-remotely-disconnect-a-terminal-services-session/</link>
		<comments>http://optionexplicit.wordpress.com/2010/01/04/howto-remotely-disconnect-a-terminal-services-session/#comments</comments>
		<pubDate>Mon, 04 Jan 2010 03:51:59 +0000</pubDate>
		<dc:creator>optionexplicit</dc:creator>
				<category><![CDATA[Windows]]></category>

		<guid isPermaLink="false">http://optionexplicit.wordpress.com/?p=61</guid>
		<description><![CDATA[Windows server 2000/2003 allows two remote terminal services connections for administrative purposes. Every once in a while I’ll get the “You exceeded the allowed connection count” message when trying to connect to a server via RDP, because previous sessions were not disconnected correctly. You can use either of the following methods to remotely disconnect Terminal [...]<img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=optionexplicit.wordpress.com&amp;blog=4074106&amp;post=61&amp;subd=optionexplicit&amp;ref=&amp;feed=1" width="1" height="1" />]]></description>
			<content:encoded><![CDATA[<p>Windows server 2000/2003 allows two remote terminal services connections for administrative purposes.  Every once in a while I’ll get the “You exceeded the allowed connection count” message when trying to connect to a server via RDP, because previous sessions were not disconnected correctly.  You can use either of the following methods to remotely disconnect Terminal Server sessions.  Method 1  You can normally run the Terminal Services Manager program on another server, or even from a Windows XP workstation, to disconnect Terminal Services connections by clicking Start – Run and then typing  %SystemRoot%\system32\tsadmin.exe  This will launch the local copy of Terminal Services Manager.  Next right click on All Listed Servers and select Connect to Computer.  Type in the name or IP address of the server you wish to manage.</p>
<br />  <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gocomments/optionexplicit.wordpress.com/61/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/comments/optionexplicit.wordpress.com/61/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godelicious/optionexplicit.wordpress.com/61/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/delicious/optionexplicit.wordpress.com/61/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gofacebook/optionexplicit.wordpress.com/61/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/facebook/optionexplicit.wordpress.com/61/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gotwitter/optionexplicit.wordpress.com/61/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/twitter/optionexplicit.wordpress.com/61/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gostumble/optionexplicit.wordpress.com/61/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/stumble/optionexplicit.wordpress.com/61/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godigg/optionexplicit.wordpress.com/61/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/digg/optionexplicit.wordpress.com/61/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/goreddit/optionexplicit.wordpress.com/61/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/reddit/optionexplicit.wordpress.com/61/" /></a> <img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=optionexplicit.wordpress.com&amp;blog=4074106&amp;post=61&amp;subd=optionexplicit&amp;ref=&amp;feed=1" width="1" height="1" />]]></content:encoded>
			<wfw:commentRss>http://optionexplicit.wordpress.com/2010/01/04/howto-remotely-disconnect-a-terminal-services-session/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
	
		<media:content url="http://0.gravatar.com/avatar/edeab4aeb5fd4b32e0a095916ca15e88?s=96&#38;d=identicon&#38;r=G" medium="image">
			<media:title type="html">optionexplicit</media:title>
		</media:content>
	</item>
		<item>
		<title>Simple script to backup all SQL Server databases</title>
		<link>http://optionexplicit.wordpress.com/2009/12/15/simple-script-to-backup-all-sql-server-databases/</link>
		<comments>http://optionexplicit.wordpress.com/2009/12/15/simple-script-to-backup-all-sql-server-databases/#comments</comments>
		<pubDate>Tue, 15 Dec 2009 04:18:43 +0000</pubDate>
		<dc:creator>optionexplicit</dc:creator>
				<category><![CDATA[Database]]></category>

		<guid isPermaLink="false">http://optionexplicit.wordpress.com/?p=58</guid>
		<description><![CDATA[DECLARE @name VARCHAR(50) -- database name DECLARE @path VARCHAR(256) -- path for backup files DECLARE @fileName VARCHAR(256) -- filename for backup DECLARE @fileDate VARCHAR(20) -- used for file name SET @path = 'C:\Backup\' SELECT @fileDate = CONVERT(VARCHAR(20),GETDATE(),112) DECLARE db_cursor CURSOR FOR SELECT name FROM master.dbo.sysdatabases WHERE name NOT IN ('master','model','msdb','tempdb') OPEN db_cursor FETCH NEXT FROM db_cursor INTO @name WHILE @@FETCH_STATUS = 0 BEGIN SET @fileName = @path + @name + '_' + @fileDate + '.BAK' BACKUP DATABASE @name TO DISK = @fileName FETCH NEXT FROM db_cursor INTO @name END CLOSE db_cursor DEALLOCATE db_cursor<img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=optionexplicit.wordpress.com&amp;blog=4074106&amp;post=58&amp;subd=optionexplicit&amp;ref=&amp;feed=1" width="1" height="1" />]]></description>
			<content:encoded><![CDATA[<p><code><span style="font-family:Arial;font-size:x-small;">DECLARE </span><span style="font-size:x-small;"><span style="font-family:Arial;">@name VARCHAR(50) -- database name<br />
DECLARE @path VARCHAR(256) -- path for backup files<br />
DECLARE @fileName VARCHAR(256) -- filename for backup<br />
DECLARE @fileDate VARCHAR(20) -- used for file name</p>
<p>SET @path = 'C:\Backup\'</p>
<p>SELECT @fileDate = CONVERT(VARCHAR(20),GETDATE(),112)</p>
<p>DECLARE db_cursor CURSOR FOR<br />
SELECT name<br />
FROM master.dbo.sysdatabases<br />
WHERE name NOT IN ('master','model','msdb','tempdb')</p>
<p>OPEN db_cursor<br />
FETCH NEXT FROM db_cursor INTO @name</p>
<p>WHILE @@FETCH_STATUS = 0<br />
BEGIN<br />
SET @fileName = @path + @name + '_' + @fileDate + '.BAK'<br />
BACKUP DATABASE @name TO DISK = @fileName</p>
<p>FETCH NEXT FROM db_cursor INTO @name<br />
END</p>
<p>CLOSE db_cursor<br />
DEALLOCATE </span><span style="font-family:Arial;">db_cursor</span></span></code></p>
<br />  <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gocomments/optionexplicit.wordpress.com/58/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/comments/optionexplicit.wordpress.com/58/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godelicious/optionexplicit.wordpress.com/58/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/delicious/optionexplicit.wordpress.com/58/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gofacebook/optionexplicit.wordpress.com/58/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/facebook/optionexplicit.wordpress.com/58/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gotwitter/optionexplicit.wordpress.com/58/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/twitter/optionexplicit.wordpress.com/58/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gostumble/optionexplicit.wordpress.com/58/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/stumble/optionexplicit.wordpress.com/58/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godigg/optionexplicit.wordpress.com/58/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/digg/optionexplicit.wordpress.com/58/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/goreddit/optionexplicit.wordpress.com/58/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/reddit/optionexplicit.wordpress.com/58/" /></a> <img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=optionexplicit.wordpress.com&amp;blog=4074106&amp;post=58&amp;subd=optionexplicit&amp;ref=&amp;feed=1" width="1" height="1" />]]></content:encoded>
			<wfw:commentRss>http://optionexplicit.wordpress.com/2009/12/15/simple-script-to-backup-all-sql-server-databases/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
	
		<media:content url="http://0.gravatar.com/avatar/edeab4aeb5fd4b32e0a095916ca15e88?s=96&#38;d=identicon&#38;r=G" medium="image">
			<media:title type="html">optionexplicit</media:title>
		</media:content>
	</item>
		<item>
		<title>Internal SQL Functions</title>
		<link>http://optionexplicit.wordpress.com/2009/12/14/internal-sql-functions/</link>
		<comments>http://optionexplicit.wordpress.com/2009/12/14/internal-sql-functions/#comments</comments>
		<pubDate>Mon, 14 Dec 2009 04:41:57 +0000</pubDate>
		<dc:creator>optionexplicit</dc:creator>
				<category><![CDATA[Database]]></category>

		<guid isPermaLink="false">http://optionexplicit.wordpress.com/2009/12/14/internal-sql-functions/</guid>
		<description><![CDATA[1. Functions Introduction This section gives examples of all functions that are available in the Mckoi database software. Functions may be used within all expressions except aggregate functions that may only be used within the SELECT .... FROM clause. 2. Mathematical Functions Follows are all the mathematical functions available in Mckoi Database. Note that some [...]<img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=optionexplicit.wordpress.com&amp;blog=4074106&amp;post=56&amp;subd=optionexplicit&amp;ref=&amp;feed=1" width="1" height="1" />]]></description>
			<content:encoded><![CDATA[<p><span style="font-family:Arial;color:#0060a0;font-size:xx-small;">1. Functions Introduction</span></p>
<blockquote><p>This section gives examples of all functions that are available in the   Mckoi database software.  Functions may be used within all expressions   except aggregate functions that may only be used within the   <code><span style="color:#803050;">SELECT .... FROM</span></code> clause.</p></blockquote>
<p><a name="2"></a><br />
<span style="font-family:Arial;color:#0060a0;font-size:xx-small;">2. Mathematical Functions</span></p>
<blockquote><p>Follows are all the mathematical functions available in Mckoi Database.  Note that        some of these functions may lose precision because the number could be cast to a        &#8216;double&#8217;.  You can assume that all mathematical functions have at worst the        precision of a &#8216;double&#8217;.</p>
<p><a name="ABS"></a> <strong>ABS(number)</strong></p>
<blockquote><p>Returns the absolute value of a number.</p>
<blockquote><p>Examples:</p>
<pre><span style="color:#803050;">     SELECT ABS(-0.94)
</span>==&gt;  0.94
</pre>
<pre><span style="color:#803050;">     SELECT ABS(9 - 200)
</span>==&gt;  191
</pre>
</blockquote>
</blockquote>
<p><a name="SIGN"></a> <strong>SIGN(number)</strong></p>
<blockquote><p>Returns 1 if the number is positive, -1 if the number is negative and 0 if the number is zero.</p>
<blockquote><p>Examples:</p>
<pre><span style="color:#803050;">     SELECT SIGN(40)
</span>==&gt;  1
</pre>
<pre><span style="color:#803050;">     SELECT SIGN(-40)
</span>==&gt;  -1
</pre>
<pre><span style="color:#803050;">     SELECT SIGN(40 - 40)
</span>==&gt;  0
</pre>
</blockquote>
</blockquote>
<p><a name="MOD"></a> <strong>MOD(number1, number2)</strong></p>
<blockquote><p>Returns the modulo of number1 and number2 (equivalent to {number1 % number2} in Java).</p>
<blockquote><p>Examples:</p>
<pre><span style="color:#803050;">     SELECT MOD(15, 5)
</span>==&gt;  0
</pre>
<pre><span style="color:#803050;">     SELECT MOD(33, 10)
</span>==&gt;  3
</pre>
<pre><span style="color:#803050;">     SELECT ROUND(552 / 10), MOD(552, 10)
</span>==&gt;  55, 2
</pre>
</blockquote>
</blockquote>
<p><a name="ROUND"></a> <strong>ROUND(number, decimal_places)</strong><br />
<strong>ROUND(number)</strong></p>
<blockquote><p>Rounds the number to &#8216;n&#8217; decimal places.          When no &#8216;decimal_places&#8217; argument is provided the number is rounded to the nearest whole          number.</p>
<p>This will round up if the fraction to the right is &gt;= .5 otherwise it rounds down.          This uses the {BigDecimal.setScale(decimal_places, BigDecimal.ROUND_HALF_UP)} method for          rounding.</p>
<blockquote><p>Examples:</p>
<pre><span style="color:#803050;">     SELECT ROUND((943 * 13) / 99, 3)
</span>==&gt;  123.828
</pre>
<pre><span style="color:#803050;">     SELECT ROUND((943 * 13) / 99, 2)
</span>==&gt;  123.83
</pre>
<pre><span style="color:#803050;">     SELECT ROUND((943 * 13) / 99)
</span>==&gt;  124
</pre>
</blockquote>
</blockquote>
<p><a name="POW"></a> <strong>POW(number1, number2)</strong></p>
<blockquote><p>Raises number1 to the power of number2.</p>
<blockquote><p>Examples:</p>
<pre><span style="color:#803050;">     SELECT POW(9, 6)
</span>==&gt;  531441
</pre>
<pre><span style="color:#803050;">     SELECT POW(2, 32)
</span>==&gt;  4294967296
</pre>
<pre><span style="color:#803050;">     SELECT POW(2, 64)
</span>==&gt;  18446744073709551616
</pre>
<pre><span style="color:#803050;">     SELECT POW(2, -3)
</span>==&gt;  0.125
</pre>
</blockquote>
</blockquote>
<p><a name="SQRT"></a> <strong>SQRT(number)</strong></p>
<blockquote><p>Finds the square root of the number argument.</p>
<blockquote><p>Examples:</p>
<pre><span style="color:#803050;">     SELECT SQRT(65536)
</span>==&gt;  256
</pre>
<pre><span style="color:#803050;">     SELECT SQRT(-1)
</span>==&gt;  NULL
</pre>
</blockquote>
</blockquote>
<p><a name="LEAST"></a> <strong>LEAST(val1, val2, &#8230;)</strong></p>
<blockquote><p>This function accepts any number of arguments and returns the value          that represents the least value of the set.</p>
<blockquote><p>Examples:</p>
<pre><span style="color:#803050;">     SELECT LEAST(4)
</span>==&gt;  4
</pre>
<pre><span style="color:#803050;">     SELECT LEAST(90, 9.125, 3, 75)
</span>==&gt;  3
</pre>
<pre><span style="color:#803050;">     SELECT LEAST('H', 'Z', 'B')
</span>==&gt;  B
</pre>
<pre><span style="color:#803050;">     SELECT LEAST(10 / 3, 10 * 3,
</span><span style="color:#803050;">                  POW(10, 3), MOD(10, 3))
</span>==&gt;  1
</pre>
</blockquote>
</blockquote>
<p><a name="GREATEST"></a> <strong>GREATEST(val1, val2, &#8230;)</strong></p>
<blockquote><p>This function accepts any number of arguments and returns the value          that represents the greatest value of the set.</p>
<blockquote><p>Examples:</p>
<pre><span style="color:#803050;">     SELECT GREATEST(4)
</span>==&gt;  4
</pre>
<pre><span style="color:#803050;">     SELECT GREATEST(90, 9.125, 3, 75)
</span>==&gt;  90
</pre>
<pre><span style="color:#803050;">     SELECT GREATEST('H', 'Z', 'B')
</span>==&gt;  Z
</pre>
<pre><span style="color:#803050;">     SELECT GREATEST(10 / 3, 10 * 3,
</span><span style="color:#803050;">                     POW(10, 3), MOD(10, 3))
</span>==&gt;  1000
</pre>
</blockquote>
</blockquote>
</blockquote>
<p><a name="3"></a><br />
<span style="font-family:Arial;color:#0060a0;font-size:xx-small;">3. String Functions</span></p>
<blockquote><p>String functions in Mckoi Database mostly map to equivalent functions found within        java.lang.String.</p>
<p><a name="LOWER"></a> <strong>LOWER(str)</strong></p>
<blockquote><p>Returns a lower case version of the string literal argument.</p>
<blockquote><p>Examples:</p>
<pre><span style="color:#803050;">     SELECT LOWER('THis is sOME TEXT')
</span>==&gt;  this is some text
</pre>
</blockquote>
</blockquote>
<p><a name="UPPER"></a> <strong>UPPER(str)</strong></p>
<blockquote><p>Returns an upper case version of the string literal argument.</p>
<blockquote><p>Examples:</p>
<pre><span style="color:#803050;">     SELECT UPPER('THis is sOME TEXT')
</span>==&gt;  THIS IS SOME TEXT
</pre>
</blockquote>
</blockquote>
<p><a name="CONCAT"></a> <strong>CONCAT(str1, str2, &#8230;)</strong></p>
<blockquote><p>Returns the concatenation of the string arguments. This function          can take any number of arguments.</p>
<blockquote><p>Examples:</p>
<pre><span style="color:#803050;">     SELECT CONCAT('This i', 's some text', '.')
</span>==&gt;  This is some text.
</pre>
<pre><span style="color:#803050;">     SELECT CONCAT('-', 0.95)
</span>==&gt;  -0.95
</pre>
</blockquote>
</blockquote>
<p><a name="LENGTH"></a> <strong>LENGTH(str)</strong></p>
<blockquote><p>Returns the number of characters in the string argument.</p>
<p><em>NOTE: This may          additionally be used on BLOB data to return the count of bytes in the BLOB.</em></p>
<blockquote><p>Examples:</p>
<pre><span style="color:#803050;">     SELECT LENGTH('This is some text')
</span>==&gt;  17
</pre>
<pre><span style="color:#803050;">     SELECT LENGTH(0.544)
</span>==&gt;  5
</pre>
<pre><span style="color:#803050;">     SELECT LENGTH('    Test')
</span>==&gt;  8
</pre>
</blockquote>
</blockquote>
<p><a name="TRIM"></a> <strong>TRIM( [ [ LEADING | TRAILING | BOTH ] [ characters ] FROM ] str )</strong><br />
<strong>LTRIM(str)</strong><br />
<strong>RTRIM(str)</strong></p>
<blockquote><p>Trims characters from a string argument.  The <code>LTRIM</code> and          <code>RTRIM</code> form trim whitespace from the left and right of the          string respectively.</p>
<blockquote><p>Examples:</p>
<pre><span style="color:#803050;">     SELECT TRIM(TRAILING 'a' FROM 'aaabcdaaa')
</span>==&gt;  aaabcd
</pre>
<pre><span style="color:#803050;">     SELECT TRIM(LEADING 'a' FROM 'aaabcdaaa')
</span>==&gt;  bcdaaa
</pre>
<pre><span style="color:#803050;">     SELECT TRIM('ab' FROM 'ababzzzzab')
</span>==&gt;  zzzz
</pre>
<pre><span style="color:#803050;">     SELECT TRIM('  a string message ')
</span>==&gt;  a string message
</pre>
</blockquote>
</blockquote>
<p><a name="SUBSTRING"></a> <strong>SUBSTRING(str, start_index)</strong><br />
<strong>SUBSTRING(str, start_index, length)</strong></p>
<blockquote><p>Returns a substring of a string.  The <code>SUBSTRING</code> function complies       with the SQL specification.  The <code>start_index</code> parameter is a value       between 1 and the length of the string where 1 includes the first character, 2       includes the second character, etc.  The <code>length</code> parameter represents       the size of the substring.</p>
<blockquote><p>Examples:</p>
<pre><span style="color:#803050;">     SELECT SUBSTRING('Tobias Downer', <img src='http://s2.wp.com/wp-includes/images/smilies/icon_cool.gif' alt='8)' class='wp-smiley' />
</span>==&gt;  Downer
</pre>
<pre><span style="color:#803050;">     SELECT SUBSTRING('abcd', 1, 2)
</span>==&gt;  ab
</pre>
<pre><span style="color:#803050;">     SELECT SUBSTRING('abcd', 3, 4)
</span>==&gt;  cd
</pre>
<pre><span style="color:#803050;">     SELECT SUBSTRING('abcd', 3, 5000)
</span>==&gt;  cd
</pre>
<pre><span style="color:#803050;">     SELECT SUBSTRING('abcd', 0, 5000)
</span>==&gt;  abcd
</pre>
<pre><span style="color:#803050;">     SELECT SUBSTRING('abcd', 1, 0)
</span>==&gt;  (string of 0 length)
</pre>
</blockquote>
</blockquote>
</blockquote>
<p><a name="4"></a><br />
<span style="font-family:Arial;color:#0060a0;font-size:xx-small;">4. Aggregate Functions</span></p>
<blockquote><p>Aggregate functions can only operate within a group of a SELECT statement.  They        are used to compute statistics over a set of records.</p>
<p><a name="COUNT"></a> <strong>COUNT(*)</strong><br />
<strong>COUNT(DISTINCT expression_list)</strong><br />
<strong>COUNT(column_name)</strong><br />
<strong>COUNT(expression)</strong></p>
<blockquote><p>The * version of this function returns the total number of rows          in the group.  If a column name is specified it returns the number          of non-null values in the group.  The &#8216;expression&#8217; form of this function          evaluates the expression for each row in the group and counts it only          if it evaluates to NULL.  <code><span style="color:#803050;">COUNT(DISTINCT ... )</span></code> counts all          distinct values of the expression list over the group.</p>
<blockquote><p>Examples:</p>
<pre><span style="color:#803050;">     SELECT COUNT(*)
</span><span style="color:#803050;">       FROM Orders
</span></pre>
<pre><span style="color:#803050;">     SELECT COUNT(*)
</span><span style="color:#803050;">       FROM Orders
</span><span style="color:#803050;">   GROUP BY division
</span></pre>
<pre><span style="color:#803050;">     SELECT COUNT(id)
</span><span style="color:#803050;">       FROM Orders
</span><span style="color:#803050;">   GROUP BY division
</span></pre>
<pre><span style="color:#803050;">     SELECT last_name, COUNT(DISTINCT last_name)
</span><span style="color:#803050;">       FROM Customers
</span><span style="color:#803050;">   GROUP BY age
</span></pre>
</blockquote>
</blockquote>
<p><a name="SUM"></a> <strong>SUM(column_name)</strong><br />
<strong>SUM(expression)</strong></p>
<blockquote><p>Calculates the sum of all values in a column/expression over a group.          The expression form of this function is evaluated for each row in the group.</p>
<blockquote><p>Examples:</p>
<pre><span style="color:#803050;">     SELECT SUM(value) FROM Orders
</span></pre>
<pre><span style="color:#803050;">     SELECT SUM(quantity * value)
</span><span style="color:#803050;">       FROM Orders
</span></pre>
<pre><span style="color:#803050;">     SELECT SUM(quantity * value) * 0.75
</span><span style="color:#803050;">       FROM Orders
</span><span style="color:#803050;">   GROUP BY division
</span></pre>
</blockquote>
</blockquote>
<p><a name="AVG"></a> <strong>AVG(column_name)</strong><br />
<strong>AVG(expression)</strong></p>
<blockquote><p>Calculates the average of the column/expression over the group.          The expression form of this function is evaluated for each row in the group.</p>
<blockquote><p>Examples:</p>
<pre><span style="color:#803050;">     SELECT AVG(value) FROM Orders
</span></pre>
<pre><span style="color:#803050;">     SELECT AVG(quantity * value)
</span><span style="color:#803050;">       FROM Orders
</span></pre>
<pre><span style="color:#803050;">     SELECT AVG(quantity * value) * 0.75
</span><span style="color:#803050;">       FROM Orders
</span><span style="color:#803050;">   GROUP BY division
</span></pre>
</blockquote>
</blockquote>
<p><a name="MIN"></a> <strong>MIN(column_name)</strong><br />
<strong>MIN(expression)</strong></p>
<blockquote><p>Finds the minimum value of a column/expression over a group.</p>
<blockquote><p>Examples:</p>
<pre><span style="color:#803050;">     SELECT MIN(value) FROM Orders
</span></pre>
<pre><span style="color:#803050;">     SELECT MIN(quantity * value)
</span><span style="color:#803050;">       FROM Orders
</span></pre>
<pre><span style="color:#803050;">     SELECT MIN(quantity * value) * 0.75
</span><span style="color:#803050;">       FROM Orders
</span><span style="color:#803050;">   GROUP BY division
</span></pre>
</blockquote>
</blockquote>
<p><a name="MAX"></a> <strong>MAX(column_name)</strong><br />
<strong>MAX(expression)</strong></p>
<blockquote><p>Finds the maximum value of a column/expression over a group.</p>
<blockquote><p>Examples:</p>
<pre><span style="color:#803050;">     SELECT MAX(value) FROM Orders
</span></pre>
<pre><span style="color:#803050;">     SELECT MAX(quantity * value)
</span><span style="color:#803050;">       FROM Orders
</span></pre>
<pre><span style="color:#803050;">     SELECT MAX(quantity * value) * 0.75
</span><span style="color:#803050;">       FROM Orders
</span><span style="color:#803050;">   GROUP BY division
</span></pre>
</blockquote>
</blockquote>
</blockquote>
<p><a name="5"></a><br />
<span style="font-family:Arial;color:#0060a0;font-size:xx-small;">5. Security Functions</span></p>
<blockquote><p>Functions that provide security information about the session performing        the query.</p>
<p><a name="USER"></a> <strong>USER()</strong></p>
<blockquote><p>Returns the current user.</p></blockquote>
<p><a name="PRIVGROUPS"></a> <strong>PRIVGROUPS()</strong></p>
<blockquote><p>Returns a comma deliminated list of priv groups the user belongs to.          A user may belong to any number of groups which dictate the tables a          user may access.</p></blockquote>
</blockquote>
<p><a name="6"></a><br />
<span style="font-family:Arial;color:#0060a0;font-size:xx-small;">6. Branch Functions</span></p>
<blockquote><p><a name="IF"></a> <strong>IF(condition_expr, true_expr, false_expr)</strong></p>
<blockquote><p>If the first expression (condition_expr) evaluates to true this function          returns the result of &#8216;true_expr&#8217; otherwise returns the result of          &#8216;false_exp&#8217;.</p>
<blockquote><p>Examples:</p>
<pre><span style="color:#803050;">     SELECT IF(true, 5, <img src='http://s2.wp.com/wp-includes/images/smilies/icon_cool.gif' alt='8)' class='wp-smiley' />
</span>==&gt;  5
</pre>
<pre><span style="color:#803050;">     SELECT IF(false, 5, <img src='http://s2.wp.com/wp-includes/images/smilies/icon_cool.gif' alt='8)' class='wp-smiley' />
</span>==&gt;  8
</pre>
<pre><span style="color:#803050;">     SELECT IF(NULL, 5, <img src='http://s2.wp.com/wp-includes/images/smilies/icon_cool.gif' alt='8)' class='wp-smiley' />
</span>==&gt;  NULL
</pre>
<pre><span style="color:#803050;">     SELECT IF(true, IF(false, 1, 2), 3)
</span>==&gt;  2
</pre>
<pre><span style="color:#803050;">     SELECT IF(col1 = 0, 'N/A', col1) FROM MyTable
</span></pre>
</blockquote>
</blockquote>
<p><a name="COALESCE"></a> <strong>COALESCE(expr1, expr2, expr3, &#8230;.)</strong></p>
<blockquote><p>Returns the first non null value from the parameters or null if          the entire list contains null values.</p>
<blockquote><p>Examples:</p>
<pre><span style="color:#803050;">     SELECT COALESCE(NULL, 'a')
</span>==&gt;  a
</pre>
<pre><span style="color:#803050;">     SELECT COALESCE(NULL, NULL, NULL)
</span>==&gt;  NULL
</pre>
<pre><span style="color:#803050;">     SELECT COALESCE(col1, 'N/A') FROM MyTable
</span></pre>
</blockquote>
</blockquote>
</blockquote>
<p><a name="7"></a><br />
<span style="font-family:Arial;color:#0060a0;font-size:xx-small;">7. Date/Time Functions</span></p>
<blockquote><p><a name="DATEOB"></a> <strong>DATEOB(date_string)</strong></p>
<blockquote><p>Parses a string to a Date object that can be used on queries against          TIMESTAMP / DATE / TIME columns.  DATEOB with no arguments returns the          current time of the machine running the database.</p>
<p><em>Since version 0.92 this function has been deprecated.  Use the standard          DATE, TIME and TIMESTAMP literals specified in SQL-92 instead.</em></p>
<blockquote><p>Examples:</p>
<pre><span style="color:#803050;">     SELECT DATEOB()
</span>==&gt;  Wed Aug 09 11:49:31 EDT 2000
</pre>
<pre><span style="color:#803050;">     SELECT DATEOB('Aug 1, 2000')
</span>==&gt;  Tue Aug 01 00:00:00 EDT 2000
</pre>
<pre><span style="color:#803050;">     SELECT number FROM Orders
</span><span style="color:#803050;">      WHERE date_made &gt;= DATEOB('Jan 1, 2000')
</span></pre>
</blockquote>
</blockquote>
</blockquote>
<p><a name="8"></a><br />
<span style="font-family:Arial;color:#0060a0;font-size:xx-small;">8. Misc Functions</span></p>
<blockquote><p><a name="UNIQUEKEY"></a> <strong>UNIQUEKEY(table_name)</strong></p>
<blockquote><p>Returns a unique key for the given table name.          This is an atomic operation that is guaranteed to return a unique          number each call.  It should be used to generate unique identification          numbers for records.  It is similar to the AUTO_INCREMENT feature of          other database systems.</p>
<blockquote><p>Examples:</p>
<pre><span style="color:#803050;">     SELECT UNIQUEKEY('Orders')
</span></pre>
<pre><span style="color:#803050;">     INSERT INTO Orders
</span><span style="color:#803050;">        ( id, number, division, date_made, quantity,
</span><span style="color:#803050;">          value )
</span><span style="color:#803050;">       VALUES
</span><span style="color:#803050;">        ( UNIQUEKEY('Orders'), CONCAT('Order-', id),
</span><span style="color:#803050;">          'Bio Engineering', DATEOB(), 25, 1900.00 )
</span></pre>
</blockquote>
</blockquote>
<p><a name="TONUMBER"></a> <strong>TONUMBER(expression)</strong></p>
<blockquote><p>Attempts to cast the expression to a number.  If the expression is a          boolean then this function will return 1 for true or 0 for false.  If          the expression is a String then it attempts to parse the string into a          number.  If the expression is a Date then it returns the date as the          number of milliseconds since Jan 1st, 1970.</p>
<blockquote><p>Examples:</p>
<pre><span style="color:#803050;">     SELECT TONUMBER(DATEOB('Aug 1, 2000'))
</span>==&gt;  965102400000
</pre>
</blockquote>
</blockquote>
</blockquote>
<br />  <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gocomments/optionexplicit.wordpress.com/56/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/comments/optionexplicit.wordpress.com/56/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godelicious/optionexplicit.wordpress.com/56/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/delicious/optionexplicit.wordpress.com/56/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gofacebook/optionexplicit.wordpress.com/56/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/facebook/optionexplicit.wordpress.com/56/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gotwitter/optionexplicit.wordpress.com/56/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/twitter/optionexplicit.wordpress.com/56/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gostumble/optionexplicit.wordpress.com/56/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/stumble/optionexplicit.wordpress.com/56/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godigg/optionexplicit.wordpress.com/56/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/digg/optionexplicit.wordpress.com/56/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/goreddit/optionexplicit.wordpress.com/56/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/reddit/optionexplicit.wordpress.com/56/" /></a> <img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=optionexplicit.wordpress.com&amp;blog=4074106&amp;post=56&amp;subd=optionexplicit&amp;ref=&amp;feed=1" width="1" height="1" />]]></content:encoded>
			<wfw:commentRss>http://optionexplicit.wordpress.com/2009/12/14/internal-sql-functions/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
	
		<media:content url="http://0.gravatar.com/avatar/edeab4aeb5fd4b32e0a095916ca15e88?s=96&#38;d=identicon&#38;r=G" medium="image">
			<media:title type="html">optionexplicit</media:title>
		</media:content>
	</item>
		<item>
		<title>XAMPP Virtual Hosts on a MAC</title>
		<link>http://optionexplicit.wordpress.com/2009/10/15/xampp-virtual-hosts-on-a-mac/</link>
		<comments>http://optionexplicit.wordpress.com/2009/10/15/xampp-virtual-hosts-on-a-mac/#comments</comments>
		<pubDate>Thu, 15 Oct 2009 10:15:36 +0000</pubDate>
		<dc:creator>optionexplicit</dc:creator>
				<category><![CDATA[Mac]]></category>

		<guid isPermaLink="false">http://optionexplicit.wordpress.com/2009/10/15/xampp-virtual-hosts-on-a-mac/</guid>
		<description><![CDATA[I recently retooled a Zend development environment on a mac laptop running OS X. I had been using the free version of MAMP for awhile but found the free version too limited.  MAMP is useful for getting  Apache, PHP, and MySQL stack up and working together quickly on a mac.  One thing lacking in MAMP [...]<img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=optionexplicit.wordpress.com&amp;blog=4074106&amp;post=54&amp;subd=optionexplicit&amp;ref=&amp;feed=1" width="1" height="1" />]]></description>
			<content:encoded><![CDATA[<p>I recently retooled a Zend development environment on a mac laptop running OS X. I had been using the free version of <a href="http://www.mamp.info/en/index.html" target="_blank">MAMP</a> for awhile but found the free version too limited.  MAMP is useful for getting  Apache, PHP, and MySQL stack up and working together quickly on a mac.  One thing lacking in MAMP though is an actual http.conf file like you probably deal with on a production server.</p>
<p>XAMP is another free AMP stack which includes an editable httpd.conf file making configuring Apache to test SSL connections much more standardized if not straight forward.  Instead of dealing with a GUI one deals with the Apache configuration files directly.  While it’s nice to be able to customize XAMPs Apache installation getting the configuration right can take some time.  If your really uncomfortable meddling with Apache configuration files you should consider just purchasing a licensed version of MAMP which does most of the stuff through a graphical interface.  Of course once you go into production you’ll probably going to have to deal with Apache’s httpd.conf file anyway so you might as well front load the pain now and be better prepared when things actually do go into production.</p>
<p>So without further ado I now present the first post on the new acwolf blog: how to configure XAMP virtual hosts on a mac.</p>
<p><strong>Step One, Download and configure XAMP</strong></p>
<p>First <a title="XAMP for MAc" href="http://www.apachefriends.org/en/xampp-macosx.html" target="_blank">download XAMP for mac</a>.</p>
<p>Once you have XAMP running on you mac you’re ready to begin configuring virtual hosts.  Using Mac Finder go to <em>Applications &gt; xampp &gt; etc</em> and open the httpd.conf file. Near the bottom of the file look for the following lines:</p>
<blockquote><p># Virtual hosts<br />
#Include /Applications/xampp/etc/extra/httpd-vhosts.conf</p></blockquote>
<p>The pound symbol (#) denotes a comment.  Since we want to setup virtual hosts go ahead and uncomment the second line by removing the pound symbol like so</p>
<blockquote><p># Virtual hosts<br />
Include /Applications/xampp/etc/extra/httpd-vhosts.conf</p></blockquote>
<p>With the above line uncommented Apache will now look to the <em>httpd-vhosts.conf</em> file for instructions on how to configure virtual hosts.   Go to <em>Applications &gt; xampp &gt; etc &gt; extra</em> and open <em>httpd-vhosts.conf</em> to begin configuring virtual hosts for XAMP.  An imported (and practically undocumented) fist step is to <strong>include localhost has the default named virtual host</strong>. Do this by adding the following to the httpd-vhosts.conf:</p>
<blockquote><p>&lt;VirtualHost *:80&gt;<br />
ServerName localhost<br />
DocumentRoot “/Applications/xampp/htdocs”<br />
&lt;Directory “/Applications/xampp/htdocs”&gt;<br />
Options Indexes FollowSymLinks Includes execCGI<br />
AllowOverride None<br />
Order Allow,Deny<br />
Allow From All<br />
&lt;/Directory&gt;<br />
&lt;/VirtualHost&gt;</p></blockquote>
<p>With that in place you are now ready to add your other virtual hosts, in my case I’m developing a Zend application called zendapplication.  It’s located in a folder called myZendApps in the <em>User &gt; Documents</em> folder.</p>
<blockquote><p>&lt;VirtualHost *:80&gt;<br />
ServerName zendapplication.dev<br />
ServerAlias wwww.zendapplication.dev<br />
DocumentRoot “/Users/aaronwolf/Documents/myZendApps/zendapplication/public”<br />
&lt;Directory “/Users/aaronwolf/Documents/myZendApps/zendapplication/public”&gt;<br />
Options Indexes FollowSymLinks Includes ExecCGI<br />
AllowOverride All<br />
Order allow,deny<br />
Allow from all<br />
&lt;/Directory&gt;<br />
ErrorLog “logs/zendapplication-error_log”<br />
CustomLog “logs/zendapplication-access_log” common<br />
&lt;/VirtualHost&gt;</p></blockquote>
<p>For all the details and options involved with setting up a virtual host refer to the <a href="http://httpd.apache.org/docs/2.0/vhosts/" target="_blank">apache documentation</a>.  The two critical configuration options here are ServerName and Document root.  <strong>ServerName</strong> denotes what domain this particular virtual hosts responds to.  <strong>DocumentRoot</strong> tells Apache where the files associated with this particular domain live.  Since Zend Framework applications (like Rails applications) only make the public directory accessible to the web I have the document root pointing to the public directory of my Zend application.</p>
<p>So far we,</p>
<ol>
<li>Created a localhost vertual host pointing to XAMPs default root folder (/Applications/xampp/htdocs).</li>
<li>Created a virtual host for a zend application located in <em>Users &gt; aaronwolf &gt;Documents &gt; myZendApps &gt; zendapplication &gt;public.</em></li>
<li>Assinded a server name (the local domain name) of our choosing to the new virtual host.</li>
</ol>
<p>Note: I used the .dev extension for my server name.  It’s best not to use .com or .net domain names when configuring local applications, you’ll see why once you…</p>
<p><strong>Configure the hosts file</strong></p>
<p>The next step is to configure your host file.  A hosts file works like a <a href="http://www.howstuffworks.com/dns.htm" target="_blank">DNS</a> server associating domain names with IP address except domain names configured in your local hosts file only effect your local development machine.</p>
<p>In the example presented here we have configured Apache to respond to requests for zendapplication.dev now we want to be able to type zendapplication.dev in to a browser and play with our application.  Since zendapplication.dev only exists on our local development machine (not the internet) we’ll need to configure our local host file to send requests for the zendapplication.dev domain to our development computers IP address (127.0.0.1) to be handled by Apache server.  Sounds complicated but to get it done is very simple.</p>
<p>Fist you’ll need to open your hosts file.  On a mac you can find the hosts file in the /etc directory (you’ll need root permission to edit the file).</p>
<p>Open a concole window and type:</p>
<blockquote><p>sudo nano /etc/hosts</p></blockquote>
<p>Add the following line to the bottom of your hosts file (be sure to sperate the IP number and the domain name with a tab).</p>
<blockquote><p>127.0.0.1        zendapplication.dev</p></blockquote>
<p>Now when you type zendapplication.dev in to the address bar of you local browser you’ll should see…</p>
<p><strong>You don’t have permission to access /xampp/index.php on this server.</strong></p>
<p>Nice!  Turns out there’s one more bit of configuration to be done (at least if you’re storing you applications under the User &gt; Documents directory on a mac like I am).  You’ll need to tell the Apache process to run with your user permissions (something that should never be done on a production machine).  Back to <em>Application &gt; xamp &gt; etc</em>, open httpd.conf and look for the following block:</p>
<blockquote><p>&lt;IfModule !mpm_netware_module&gt;<br />
#<br />
# If you wish httpd to run as a different user or group, you must run<br />
# httpd as root initially and it will switch.<br />
#<br />
# User/Group: The name (or #number) of the user/group to run httpd as.<br />
# It is usually good practice to create a dedicated user and group for<br />
# running httpd, as with most system services.<br />
#<br />
User nobody<br />
Group admin<br />
&lt;/IfModule&gt;</p></blockquote>
<p>Notice by default Apache is set up to run as user “nobody” which lacks permissions to access files in your Documents directory.  To fix this simply change nobody to the username you uses when logging into your machine, so in my case…</p>
<p>User aaronwolf<br />
Group admin</p>
<p>That should about do it.  Type zendapplication.dev into your browser and <a href="http://www.thislittletown.com/" target="_blank">go to town</a>.</p>
<p>If you notice your application’s indexpage redirects to /xampp/index.php you’ll just clear your browsers chache.</p>
<p>Hopfully that will save someone a few hours…</p>
<p>Source : http://www.acwolf.com/2009/02/24/xampp-virtual-hosts-on-a-mac/</p>
<br />  <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gocomments/optionexplicit.wordpress.com/54/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/comments/optionexplicit.wordpress.com/54/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godelicious/optionexplicit.wordpress.com/54/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/delicious/optionexplicit.wordpress.com/54/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gofacebook/optionexplicit.wordpress.com/54/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/facebook/optionexplicit.wordpress.com/54/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gotwitter/optionexplicit.wordpress.com/54/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/twitter/optionexplicit.wordpress.com/54/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gostumble/optionexplicit.wordpress.com/54/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/stumble/optionexplicit.wordpress.com/54/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godigg/optionexplicit.wordpress.com/54/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/digg/optionexplicit.wordpress.com/54/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/goreddit/optionexplicit.wordpress.com/54/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/reddit/optionexplicit.wordpress.com/54/" /></a> <img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=optionexplicit.wordpress.com&amp;blog=4074106&amp;post=54&amp;subd=optionexplicit&amp;ref=&amp;feed=1" width="1" height="1" />]]></content:encoded>
			<wfw:commentRss>http://optionexplicit.wordpress.com/2009/10/15/xampp-virtual-hosts-on-a-mac/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
	
		<media:content url="http://0.gravatar.com/avatar/edeab4aeb5fd4b32e0a095916ca15e88?s=96&#38;d=identicon&#38;r=G" medium="image">
			<media:title type="html">optionexplicit</media:title>
		</media:content>
	</item>
		<item>
		<title>Microsoft Access 2003 Maximum Capacities</title>
		<link>http://optionexplicit.wordpress.com/2009/10/14/microsoft-access-2003-maximum-capacities/</link>
		<comments>http://optionexplicit.wordpress.com/2009/10/14/microsoft-access-2003-maximum-capacities/#comments</comments>
		<pubDate>Wed, 14 Oct 2009 03:33:39 +0000</pubDate>
		<dc:creator>optionexplicit</dc:creator>
				<category><![CDATA[Database]]></category>

		<guid isPermaLink="false">http://optionexplicit.wordpress.com/?p=52</guid>
		<description><![CDATA[Microsoft Access 2000 and 2002 are similar. Smaller capacities for the older versions of Access are noted in the tables. These figures are taken from Microsoft sources and published here for the convienience of my students and clients. I no longer build full applications in Access, but it is excellent for prototypes, and under some [...]<img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=optionexplicit.wordpress.com&amp;blog=4074106&amp;post=52&amp;subd=optionexplicit&amp;ref=&amp;feed=1" width="1" height="1" />]]></description>
			<content:encoded><![CDATA[<p>Microsoft Access 2000 and 2002 are similar. Smaller capacities for the older versions of Access are noted in the tables.</p>
<p>These figures are taken from Microsoft sources and published here for the convienience of my students and clients.</p>
<p>I no longer build full applications in Access, but it is excellent for prototypes, and under some circumstances it works well as a front end with SQL Server as a back end. In this situation the application should be an Access project.</p>
<table border="1" cellspacing="0" cellpadding="3" align="center">
<tbody>
<tr bgcolor="#ffffcc">
<td width="50%" valign="top"><strong><span style="font-size:xx-small;">Database specifications</span></strong></td>
<td width="50%" valign="top"></td>
</tr>
<tr>
<td width="50%" valign="top"><strong>Attribute </strong></td>
<td width="50%" valign="top"><strong>Maximum</strong></td>
</tr>
<tr>
<td width="50%" valign="top">Database (.mdb) file size</td>
<td width="50%" valign="top">2 gigabyte. However, because your database can include linked tables in other files, its total size is limited only by available storage capacity.</td>
</tr>
<tr>
<td width="50%" valign="top">Number of objects in a database</td>
<td width="50%" valign="top">32,768</td>
</tr>
<tr>
<td width="50%" valign="top">Modules (including forms and reports with the HasModule property set to True)</td>
<td width="50%" valign="top">1,000</td>
</tr>
<tr>
<td width="50%" valign="top">Number of characters in an object name</td>
<td width="50%" valign="top">64</td>
</tr>
<tr>
<td width="50%" valign="top">Number of characters in a password</td>
<td width="50%" valign="top">14</td>
</tr>
<tr>
<td width="50%" valign="top">Number of characters in a user name or group name</td>
<td width="50%" valign="top">20</td>
</tr>
<tr>
<td width="50%" valign="top">Number of concurrent users</td>
<td width="50%" valign="top">255</td>
</tr>
<tr>
<td width="50%" valign="top"></td>
<td width="50%" valign="top"></td>
</tr>
<tr bgcolor="#ffffcc">
<td width="50%" valign="top"><strong><span style="font-size:xx-small;">Table specifications</span></strong></td>
<td width="50%" valign="top"></td>
</tr>
<tr>
<td width="50%" valign="top"><strong>Attribute </strong></td>
<td width="50%" valign="top"><strong>Maximum</strong></td>
</tr>
<tr>
<td width="50%" valign="top">Number of characters in a table name</td>
<td width="50%" valign="top">64</td>
</tr>
<tr>
<td width="50%" valign="top">Number of characters in a field name</td>
<td width="50%" valign="top">64</td>
</tr>
<tr>
<td width="50%" valign="top">Number of fields in a table</td>
<td width="50%" valign="top">255</td>
</tr>
<tr>
<td width="50%" valign="top">Number of open tables</td>
<td width="50%" valign="top">2048. The actual number may be less because of tables opened internally by Microsoft Access.</td>
</tr>
<tr>
<td width="50%" valign="top">Table size</td>
<td width="50%" valign="top"><span id="divExpCollAsst_2"> 2 gigabytes minus the space needed for the system objects; 1 for Access 2000 and 2002.</span></td>
</tr>
<tr>
<td width="50%" valign="top">Number of characters in a Text field</td>
<td width="50%" valign="top">255</td>
</tr>
<tr>
<td width="50%" valign="top">Number of characters in a Memo field</td>
<td width="50%" valign="top">65,535 when entering data through the user interface;  1 gigabyte when entering data programmatically.</td>
</tr>
<tr>
<td width="50%" valign="top">Size of an OLE Object field</td>
<td width="50%" valign="top">1 gigabyte</td>
</tr>
<tr>
<td width="50%" valign="top">Number of indexes in a table</td>
<td width="50%" valign="top">32</td>
</tr>
<tr>
<td width="50%" valign="top">Number of fields in an index</td>
<td width="50%" valign="top">10</td>
</tr>
<tr>
<td width="50%" valign="top">Number of characters in a validation message</td>
<td width="50%" valign="top">255</td>
</tr>
<tr>
<td width="50%" valign="top">Number of characters in a validation rule</td>
<td width="50%" valign="top">2048</td>
</tr>
<tr>
<td width="50%" valign="top">Number of characters in a table or field description</td>
<td width="50%" valign="top">255</td>
</tr>
<tr>
<td width="50%" valign="top">Number of characters in a record (excluding Memo and OLE Object fields)</td>
<td width="50%" valign="top">4,000; 2,000 for Access 2000 and 2002</td>
</tr>
<tr>
<td width="50%" valign="top">Number of characters in a field property setting</td>
<td width="50%" valign="top">255</td>
</tr>
<tr>
<td width="50%" valign="top"></td>
<td width="50%" valign="top"></td>
</tr>
<tr bgcolor="#ffffcc">
<td width="50%" valign="top"><strong><span style="font-size:xx-small;"> Query specifications</span></strong></td>
<td width="50%" valign="top"></td>
</tr>
<tr>
<td width="50%" valign="top"><strong>Attribute </strong></td>
<td width="50%" valign="top"><strong>Maximum</strong></td>
</tr>
<tr>
<td width="50%" valign="top">Number of enforced relationships</td>
<td width="50%" valign="top">32 per table minus the number of indexes that are on the table for fields or combinations of fields that are not involved in relationships</td>
</tr>
<tr>
<td width="50%" valign="top">Number of tables in a query</td>
<td width="50%" valign="top">32</td>
</tr>
<tr>
<td width="50%" valign="top">Number of fields in a recordset</td>
<td width="50%" valign="top">255</td>
</tr>
<tr>
<td width="50%" valign="top">Recordset size</td>
<td width="50%" valign="top">1 gigabyte</td>
</tr>
<tr>
<td width="50%" valign="top">Sort limit</td>
<td width="50%" valign="top">255 characters in one or more fields</td>
</tr>
<tr>
<td width="50%" valign="top">Number of levels of nested queries</td>
<td width="50%" valign="top">50</td>
</tr>
<tr>
<td width="50%" valign="top">Number of characters in a cell in the query design grid</td>
<td width="50%" valign="top">1,024</td>
</tr>
<tr>
<td width="50%" valign="top">Number of characters for a parameter in a parameter query</td>
<td width="50%" valign="top">255</td>
</tr>
<tr>
<td width="50%" valign="top">Number of ANDs in a WHERE or HAVING clause</td>
<td width="50%" valign="top">99;	40	for Access 2000 and 2002</td>
</tr>
<tr>
<td width="50%" valign="top">Number of characters in a SQL statement</td>
<td width="50%" valign="top">approximately 64,000</td>
</tr>
<tr>
<td width="50%" valign="top"></td>
<td width="50%" valign="top"></td>
</tr>
<tr bgcolor="#ffffcc">
<td width="50%" valign="top"><strong><span style="font-size:xx-small;">Form and report specifications</span></strong></td>
<td width="50%" valign="top"></td>
</tr>
<tr>
<td width="50%" valign="top"><strong>Attribute </strong></td>
<td width="50%" valign="top"><strong>Maximum</strong></td>
</tr>
<tr>
<td width="50%" valign="top">Number of characters in a label</td>
<td width="50%" valign="top">2,048</td>
</tr>
<tr>
<td width="50%" valign="top">Number of characters in a text box</td>
<td width="50%" valign="top">65,535</td>
</tr>
<tr>
<td width="50%" valign="top">Form or report width</td>
<td width="50%" valign="top">22 in. (55.87 cm)</td>
</tr>
<tr>
<td width="50%" valign="top">Section height</td>
<td width="50%" valign="top">22 in.  (55.87 cm)</td>
</tr>
<tr>
<td width="50%" valign="top">Height of all sections plus section headers (in Design view)</td>
<td width="50%" valign="top">200 in.  (508 cm)</td>
</tr>
<tr>
<td width="50%" valign="top">Number of levels of nested forms or reports</td>
<td width="50%" valign="top">7; 3 			for Access 2000 and 2002</td>
</tr>
<tr>
<td width="50%" valign="top">Number of fields or expressions you can sort or group on in a report</td>
<td width="50%" valign="top">10</td>
</tr>
<tr>
<td width="50%" valign="top">Number of headers and footers in a report</td>
<td width="50%" valign="top">1 report header/footer; 1 page header/footer; 10 group headers/footers</td>
</tr>
<tr>
<td width="50%" valign="top">Number of printed pages in a report</td>
<td width="50%" valign="top">65,536</td>
</tr>
<tr>
<td width="50%" valign="top">Number of controls and sections you can add over the lifetime of the form or report</td>
<td width="50%" valign="top">754</td>
</tr>
<tr>
<td width="50%" valign="top"><span id="divExpCollAsst_4">Number of characters in an SQL statement that serves as the <strong>Recordsource</strong> or <strong>Rowsource</strong> property of a form, report, or control (both .mdb and .adp)</span></td>
<td width="50%" valign="top"><span id="divExpCollAsst_4">32,750</span></td>
</tr>
<tr>
<td width="50%" valign="top"></td>
<td width="50%" valign="top"></td>
</tr>
<tr bgcolor="#ffffcc">
<td width="50%" valign="top"><strong><span style="font-size:xx-small;">Macro specifications</span></strong></td>
<td width="50%" valign="top"></td>
</tr>
<tr>
<td width="50%" valign="top"><strong>Attribute </strong></td>
<td width="50%" valign="top"><strong>Maximum</strong></td>
</tr>
<tr>
<td width="50%" valign="top">Number of actions in a macro</td>
<td width="50%" valign="top">999</td>
</tr>
<tr>
<td width="50%" valign="top">Number of characters in a condition</td>
<td width="50%" valign="top">255</td>
</tr>
<tr>
<td width="50%" valign="top">Number of characters in a comment</td>
<td width="50%" valign="top">255</td>
</tr>
<tr>
<td width="50%" valign="top">Number of characters in an action argument</td>
<td width="50%" valign="top">255</td>
</tr>
</tbody>
</table>
<h3>Variable and Table Data Types</h3>
<table style="height:305px;" border="1" cellspacing="3" cellpadding="0" width="589" align="center">
<tbody>
<tr>
<td width="18%" valign="top"><strong>Data type</strong></td>
<td width="12%" valign="top"><strong>Prefix</strong></td>
<td width="31%" valign="top"><strong>Example</strong></td>
<td width="39%" valign="top"><strong>Note</strong></td>
</tr>
<tr>
<td width="18%" valign="top">String (Text)</td>
<td width="12%" valign="top">str</td>
<td width="31%" valign="top">strCity</td>
<td width="39%" valign="top">Text to 255 characters</td>
</tr>
<tr>
<td width="18%" valign="top">Date/Time</td>
<td width="12%" valign="top">dtm</td>
<td width="31%" valign="top">dtmCreated</td>
<td width="39%" valign="top">Date and Time</td>
</tr>
<tr>
<td width="18%" valign="top">Boolean</td>
<td width="12%" valign="top">bln</td>
<td width="31%" valign="top">blnIsNotNull</td>
<td width="39%" valign="top">Yes/No or True/False, two values</td>
</tr>
<tr>
<td width="18%" valign="top">Byte</td>
<td width="12%" valign="top">byt</td>
<td width="31%" valign="top">bytMonth</td>
<td width="39%" valign="top">One Byte, values from 0 to +255</td>
</tr>
<tr>
<td width="18%" valign="top">Integer</td>
<td width="12%" valign="top">int</td>
<td width="31%" valign="top">intCount</td>
<td width="39%" valign="top">Two Bytes; values from -32,768 to +32,767; No fractions</td>
</tr>
<tr>
<td width="18%" valign="top">Long<br />
(long integer)</td>
<td width="12%" valign="top">lng</td>
<td width="31%" valign="top">lngDistance</td>
<td width="39%" valign="top">Four Bytes, values from<br />
-2,147,483,648 to 2,147,483,647</td>
</tr>
<tr>
<td width="18%" valign="top">Single</td>
<td width="12%" valign="top">sng</td>
<td width="31%" valign="top">sngPopulation</td>
<td width="39%" valign="top">Four Bytes single precision, floating point</td>
</tr>
<tr>
<td width="18%" valign="top">Currency</td>
<td width="12%" valign="top">cur</td>
<td width="31%" valign="top">curTraded</td>
<td width="39%" valign="top">Fifteen digits to the left, four to the right. Fixed decimal place.</td>
</tr>
<tr>
<td width="18%" valign="top">Double</td>
<td width="12%" valign="top">dbl</td>
<td width="31%" valign="top">dblClientID</td>
<td width="39%" valign="top">Eight Bytes</td>
</tr>
<tr>
<td width="18%" valign="top">Decimal</td>
<td width="12%" valign="top">dec</td>
<td width="31%" valign="top">decMicroseconds</td>
<td width="39%" valign="top">Twelve Bytes</td>
</tr>
<tr>
<td width="18%" valign="top">Object</td>
<td width="12%" valign="top">obj</td>
<td width="31%" valign="top">objConnection</td>
<td width="39%" valign="top"></td>
</tr>
<tr>
<td width="18%" valign="top">Variant</td>
<td width="12%" valign="top">vnt</td>
<td width="31%" valign="top">vntUserInput</td>
<td width="39%" valign="top">It can store numeric, string, date/time, Null, or Empty data</td>
</tr>
<tr>
<td width="18%" valign="top">Error</td>
<td width="12%" valign="top">err</td>
<td width="31%" valign="top">errBadEmailAddress</td>
<td width="39%" valign="top"></td>
</tr>
</tbody>
</table>
<p>source : http://www.databasezone.com/techdocs/acclimit.html</p>
<br />  <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gocomments/optionexplicit.wordpress.com/52/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/comments/optionexplicit.wordpress.com/52/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godelicious/optionexplicit.wordpress.com/52/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/delicious/optionexplicit.wordpress.com/52/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gofacebook/optionexplicit.wordpress.com/52/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/facebook/optionexplicit.wordpress.com/52/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gotwitter/optionexplicit.wordpress.com/52/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/twitter/optionexplicit.wordpress.com/52/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gostumble/optionexplicit.wordpress.com/52/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/stumble/optionexplicit.wordpress.com/52/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godigg/optionexplicit.wordpress.com/52/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/digg/optionexplicit.wordpress.com/52/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/goreddit/optionexplicit.wordpress.com/52/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/reddit/optionexplicit.wordpress.com/52/" /></a> <img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=optionexplicit.wordpress.com&amp;blog=4074106&amp;post=52&amp;subd=optionexplicit&amp;ref=&amp;feed=1" width="1" height="1" />]]></content:encoded>
			<wfw:commentRss>http://optionexplicit.wordpress.com/2009/10/14/microsoft-access-2003-maximum-capacities/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
	
		<media:content url="http://0.gravatar.com/avatar/edeab4aeb5fd4b32e0a095916ca15e88?s=96&#38;d=identicon&#38;r=G" medium="image">
			<media:title type="html">optionexplicit</media:title>
		</media:content>
	</item>
		<item>
		<title>A Note on Variable Scope</title>
		<link>http://optionexplicit.wordpress.com/2009/10/07/a-note-on-variable-scope/</link>
		<comments>http://optionexplicit.wordpress.com/2009/10/07/a-note-on-variable-scope/#comments</comments>
		<pubDate>Wed, 07 Oct 2009 04:31:02 +0000</pubDate>
		<dc:creator>optionexplicit</dc:creator>
				<category><![CDATA[OOP]]></category>

		<guid isPermaLink="false">http://optionexplicit.wordpress.com/2009/10/07/a-note-on-variable-scope/</guid>
		<description><![CDATA[What about that &#8220;Private Sub MessageUser()&#8221; line from our previous example? It&#8217;s a private sub, as the name states, but try to access it from outside the Vehicle class. In the MainForm_Load() sub, try adding Van.MessageUser. You should get a build error that states &#8216;Vehicle.Private Sub MessageUser()&#8217; is not accessible in this context because it [...]<img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=optionexplicit.wordpress.com&amp;blog=4074106&amp;post=50&amp;subd=optionexplicit&amp;ref=&amp;feed=1" width="1" height="1" />]]></description>
			<content:encoded><![CDATA[<p>What about that &#8220;Private Sub MessageUser()&#8221; line from our <a href="http://optionexplicit.wordpress.com/2009/10/07/classes-vs-objects/">previous example</a>? It&#8217;s a private sub, as the name states, but try to access it from outside the Vehicle class. In the MainForm_Load() sub, try adding Van.MessageUser. You should get a build error that states &#8216;Vehicle.Private Sub MessageUser()&#8217; is not accessible in this context because it is &#8216;Private&#8217;. Try the same thing with the _VehicleType variable and you should get a similar result.</p>
<p>As the error suggests, you can&#8217;t access certain types of class members from outside of the class itself.</p>
<p>The four types of variables we have used so far are:<br />
<em>Public variables</em>. These can be access directly from the class. We choose not to use this with OP by convention. Rather we create Properties (we&#8217;ll get into this later) to adjust variables directly, or use Get/Set methods.</p>
<p><em>Private variables</em>. These can be accessed only within the class. Private variables cannot be accessed by any subclasses or other class. These are ideal whenever you have a class you know will not be inherited. Also, these are good for storing data that should not be exposed publicly.</p>
<p><em>Protected variables</em>. These can be accessed by the class or any subclass that is inherited. These are what I personally use because if you design a subclass later, you don&#8217;t have to change your base class code later. This is a good catchall private storage method.</p>
<p><em>Local variables</em>. These are created by the Dim statement. These exist for the duration of the location in which they are declared. For example, if you Dim x As Int32 in Form_Load(), it will only exist in the Form_Load() method.</p>
<p>These four access types are also used frequently in sub/function/property headings, and thus are not limited to just variables. For more information on access types, see the <a href="http://msdn2.microsoft.com/en-us/library/ms973875.aspx#methodscope_topic4" target="_blank">MSDN article</a>.</p>
<br />  <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gocomments/optionexplicit.wordpress.com/50/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/comments/optionexplicit.wordpress.com/50/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godelicious/optionexplicit.wordpress.com/50/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/delicious/optionexplicit.wordpress.com/50/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gofacebook/optionexplicit.wordpress.com/50/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/facebook/optionexplicit.wordpress.com/50/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gotwitter/optionexplicit.wordpress.com/50/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/twitter/optionexplicit.wordpress.com/50/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gostumble/optionexplicit.wordpress.com/50/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/stumble/optionexplicit.wordpress.com/50/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godigg/optionexplicit.wordpress.com/50/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/digg/optionexplicit.wordpress.com/50/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/goreddit/optionexplicit.wordpress.com/50/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/reddit/optionexplicit.wordpress.com/50/" /></a> <img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=optionexplicit.wordpress.com&amp;blog=4074106&amp;post=50&amp;subd=optionexplicit&amp;ref=&amp;feed=1" width="1" height="1" />]]></content:encoded>
			<wfw:commentRss>http://optionexplicit.wordpress.com/2009/10/07/a-note-on-variable-scope/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
	
		<media:content url="http://0.gravatar.com/avatar/edeab4aeb5fd4b32e0a095916ca15e88?s=96&#38;d=identicon&#38;r=G" medium="image">
			<media:title type="html">optionexplicit</media:title>
		</media:content>
	</item>
		<item>
		<title>Classes vs. Objects</title>
		<link>http://optionexplicit.wordpress.com/2009/10/07/classes-vs-objects/</link>
		<comments>http://optionexplicit.wordpress.com/2009/10/07/classes-vs-objects/#comments</comments>
		<pubDate>Wed, 07 Oct 2009 04:11:25 +0000</pubDate>
		<dc:creator>optionexplicit</dc:creator>
				<category><![CDATA[OOP]]></category>

		<guid isPermaLink="false">http://optionexplicit.wordpress.com/?p=47</guid>
		<description><![CDATA[I know I said this was object-oriented programming. So why am I talking about classes? The answer to this question is that all objects are classes. (Mind-blowing, huh?) The way to separate the difference between objects and classes is quite easy. An object has an IS-A relationship, while a class has a HAS-A relationship. A [...]<img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=optionexplicit.wordpress.com&amp;blog=4074106&amp;post=47&amp;subd=optionexplicit&amp;ref=&amp;feed=1" width="1" height="1" />]]></description>
			<content:encoded><![CDATA[<p>I know I said this was object-oriented programming. So why am I talking about classes? The answer to this question is that all objects are classes. (Mind-blowing, huh?) The way to separate the difference between objects and classes is quite easy. An object has an IS-A relationship, while a class has a HAS-A relationship.</p>
<p>A car IS-A vehicle, while a dog HAS-A tail. The car would be an object declared as type Vehicle, while the dog would have a member that IS-A tail. However, Fido IS-A dog. The dog class is the base template for all dog objects, so when we declare Fido as a dog, Fido is an object. Since Fido IS-A dog, Fido HAS-A tail.</p>
<p>IS-A = object<br />
HAS-A = class</p>
<p>&#8220;Class&#8221; and &#8220;object&#8221; are sometimes used interchangeably. However, classes describe the structure of objects, while objects are instances of classes. Each instance is an exact copy of its base class. Because an object is an &#8220;instance&#8221; of a class, the act of creating an object is called <strong>instantiation</strong>.<br />
To describe it better, a class is a blueprint, and an object is a building based on that blueprint.</p>
<p>To understand it, we can use an example. Open up Visual Studio, and create a new Windows Application. Go to the File menu, click Add New Item, and select &#8220;Class&#8221;. A blank class window should show up. Change the name from Class1 to Vehicle. This should be what comes up:</p>
<div style="margin:5px 20px 20px;">
<div class="smallfont" style="margin-bottom:2px;">Code:</div>
<pre class="alt2" style="border:1px inset;overflow:auto;width:95%;height:84px;margin:0;padding:4px;">
<div style="text-align:left;background-color:#f4f4f4;color:#000000;" dir="ltr">Public Class Vehicle
    'This is an empty class
End Class</div>
</pre>
</div>
<p>We will start by creating a constructor.  A <strong>constructor </strong>is a special method inside each class that tells the class what to do when it is instanced. The instantiation of a class occurs when a new instance of a class is declared. In VB.NET, this is accomplished with the New sub.</p>
<p>Change your class so it looks like this:</p>
<div style="margin:5px 20px 20px;">
<div class="smallfont" style="margin-bottom:2px;">Code:</div>
<pre class="alt2" style="border:1px inset;overflow:auto;width:95%;height:244px;margin:0;padding:4px;">
<div style="text-align:left;background-color:#f4f4f4;color:#000000;" dir="ltr">Public Class Vehicle

#Region " Constructors "

    'The default constructor
    Public Sub New()
        'Tell the user that the new sub is being called.
        MessageBox.Show("This is a new vehicle object", "Object Oriented Programming")
    End Sub

#End Region

End Class</div>
</pre>
</div>
<p>Notice two things. The first is the Region called &#8220;Constructors&#8221;. I usually create these different regions to keep the code window nice and neat, and as you can have multiple constructors (see below), it&#8217;s nice to keep them all in one place. The second is the code in the New sub. This should fire every time a new object is declared.</p>
<p>To test this out, we can add some code to the MainForm_Load() method on our form:</p>
<div style="margin:5px 20px 20px;">
<div class="smallfont" style="margin-bottom:2px;">Code:</div>
<pre class="alt2" style="border:1px inset;overflow:auto;width:95%;height:180px;margin:0;padding:4px;">
<div style="text-align:left;background-color:#f4f4f4;color:#000000;" dir="ltr">Private Sub MainForm_Load(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles MyBase.Load
    'Declare a vehicle called Car and instance it
    Dim Car As Vehicle
    Car = New Vehicle()
    '
    'Declare a vehicle called Truck and instance it
    Dim Truck As Vehicle
    Truck = New Vehicle()
End Sub</div>
</pre>
</div>
<p>Run it. You&#8217;ll notice that you get two identical MessageBoxes that tell you that you have created a new vehicle object. That&#8217;s nice, right? Wouldn&#8217;t it be better to at least let it tell you what type of vehicle it is? We can: just overload a new constructor.</p>
<p>Change the class to:</p>
<div style="margin:5px 20px 20px;">
<div class="smallfont" style="margin-bottom:2px;">Code:</div>
<pre class="alt2" style="border:1px inset;overflow:auto;width:95%;height:516px;margin:0;padding:4px;">
<div style="text-align:left;background-color:#f4f4f4;color:#000000;" dir="ltr">Public Class Vehicle
    Protected _VehicleType As String

#Region " Constructors "

    'The default constructor
    Public Sub New()
        'There was no parameter passed, so let's say the vehicle is a "vehicle"
        _VehicleType = "vehicle"
        '
        'Alert the user
        MessageUser()
    End Sub
    '
    'Another constructor that accepts a parameter
    Public Sub New(ByVal VehicleType As String)
        'We've been passed a parameter, so let's store that in a private variable
        'for later use
        _VehicleType = VehicleType
        '
        'Alert the user
        MessageUser()
    End Sub

#End Region

    Private Sub MessageUser()
        'Tell the user what type of class it is
        MessageBox.Show("This object is a " &amp; _VehicleType, "Object Oriented Programming")
    End Sub

End Class</div>
</pre>
</div>
<p>That&#8217;s a lot! What does it mean? The first line &#8220;Protected _VehicleType As String&#8221; means that this is a variable that can be used anywhere inside the class, or any subclass (we&#8217;ll get to this topic later). The default constructor has been modified to take into account the storage variable, and if there&#8217;s no parameter passed, it sets the variable to &#8220;vehicle&#8221;.</p>
<p>What about that second constructor? It&#8217;s known as an overloaded constructor because it is a New sub, but has a parameter attached to it. We take the passed value and assign it to our protected variable. Let&#8217;s see what this new class does. Modify MainForm_Load to be the following:</p>
<div style="margin:5px 20px 20px;">
<div class="smallfont" style="margin-bottom:2px;">Code:</div>
<pre class="alt2" style="border:1px inset;overflow:auto;width:95%;height:244px;margin:0;padding:4px;">
<div style="text-align:left;background-color:#f4f4f4;color:#000000;" dir="ltr">Private Sub MainForm_Load(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles MyBase.Load
    'Declare a vehicle called Car and instance it
    Dim Car As Vehicle
    Car = New Vehicle("car")
    '
    'Declare a vehicle called Truck and instance it
    Dim Truck As Vehicle
    Truck = New Vehicle("truck")
    '
    'Declare a vehicle called Van and instance it
    Dim Van As Vehicle
    Van = New Vehicle()
End Sub</div>
</pre>
</div>
<p>Notice how the MessageBox has been changed to reflect this addition. Car and Truck are shown to be their respective types, but because nothing was passed to the Van instantiation call, it defaults to &#8220;vehicle&#8221;.</p>
<br />  <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gocomments/optionexplicit.wordpress.com/47/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/comments/optionexplicit.wordpress.com/47/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godelicious/optionexplicit.wordpress.com/47/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/delicious/optionexplicit.wordpress.com/47/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gofacebook/optionexplicit.wordpress.com/47/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/facebook/optionexplicit.wordpress.com/47/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gotwitter/optionexplicit.wordpress.com/47/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/twitter/optionexplicit.wordpress.com/47/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gostumble/optionexplicit.wordpress.com/47/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/stumble/optionexplicit.wordpress.com/47/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godigg/optionexplicit.wordpress.com/47/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/digg/optionexplicit.wordpress.com/47/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/goreddit/optionexplicit.wordpress.com/47/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/reddit/optionexplicit.wordpress.com/47/" /></a> <img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=optionexplicit.wordpress.com&amp;blog=4074106&amp;post=47&amp;subd=optionexplicit&amp;ref=&amp;feed=1" width="1" height="1" />]]></content:encoded>
			<wfw:commentRss>http://optionexplicit.wordpress.com/2009/10/07/classes-vs-objects/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
	
		<media:content url="http://0.gravatar.com/avatar/edeab4aeb5fd4b32e0a095916ca15e88?s=96&#38;d=identicon&#38;r=G" medium="image">
			<media:title type="html">optionexplicit</media:title>
		</media:content>
	</item>
	</channel>
</rss>
