<?xml version="1.0" encoding="utf-8"?>
			
			<rss version="2.0" xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" xmlns:cc="http://web.resource.org/cc/" xmlns:itunes="http://www.itunes.com/dtds/podcast-1.0.dtd">

			<channel>
			<title>Making It Up As I Go Along</title>
			<link>http://www.miuaiga.com/index.cfm</link>
			<description></description>
			<language>en-us</language>
			<pubDate>Sun, 05 Sep 2010 12:28:23 -0600</pubDate>
			<lastBuildDate>Sat, 04 Sep 2010 12:30:00 -0600</lastBuildDate>
			<generator>BlogCFC</generator>
			<docs>http://blogs.law.harvard.edu/tech/rss</docs>
			<managingEditor>michael@miuaiga.com</managingEditor>
			<webMaster>michael@miuaiga.com</webMaster>
			<itunes:subtitle></itunes:subtitle>
			<itunes:summary></itunes:summary>
			<itunes:category text="Technology" />
			<itunes:category text="Technology">
				<itunes:category text="Podcasting" />
			</itunes:category>
			<itunes:category text="Technology">
				<itunes:category text="Tech News" />
			</itunes:category>
			<itunes:keywords></itunes:keywords>
			<itunes:author></itunes:author>
			<itunes:owner>
				<itunes:email>michael@miuaiga.com</itunes:email>
				<itunes:name></itunes:name>
			</itunes:owner>
			<itunes:image href="" />
			<image>
				<url></url>
				<title>Making It Up As I Go Along</title>
				<link>http://www.miuaiga.com/index.cfm</link>
			</image>
			<itunes:explicit>no</itunes:explicit>
			
			<item>
				<title>How to set up local vs. production settings for Mura CMS</title>
				<link>http://www.miuaiga.com/index.cfm/2010/9/4/How-to-set-up-local-vs-production-settings-for-Mura-CMS</link>
				<description>
				
				&lt;p&gt;In an effort to become acquainted with &lt;a href=&quot;http://www.getmura.com&quot; target=&quot;_blank&quot;&gt;Mura CMS&lt;/a&gt;, I have been spending some time looking at the overall way the application is structured - what is included into what, where settings are stored or specified, and what the options are for modifying the default way things are done, in order to retain some of the in-house workflow concepts I have developed over the years.&lt;br /&gt;&lt;br /&gt;One of the main aspects of my production workflow involves the easy use of both a local and live server, running from the same database. Generally, when starting a new ColdFusion project, I like to:&lt;/p&gt;
&lt;p&gt;- Set up a local directory for the project, where i can work in the browser via a local host url&lt;br /&gt;(something like http://172.16.17.5:8500/SiteName/wwwroot/&amp;nbsp; or http://localhost:8500/sitename/wwwroot )&lt;/p&gt;
&lt;p&gt;- Set up a database on my live production server at &lt;a title=&quot;ColdFusion Hosting&quot; href=&quot;http://www.GoWestHosting.com&quot; target=&quot;_blank&quot;&gt;www.GoWestHosting.com&lt;/a&gt;&lt;/p&gt;
&lt;p&gt;- Create a DSN on the live server, pointing to the database&lt;/p&gt;
&lt;p&gt;- Create a DSN on my local CF server, pointing to the same remote database&lt;br /&gt;&lt;br /&gt;Now I can work locally and view my changes instantly without the need for FTP.&lt;br /&gt;&lt;br /&gt;Or, as needed, I can push changes to the live site with a few clicks, and view the changes there as well (such as posting work for clients, or working with routines that require server-specific settings, launched from the site&apos;s &quot;real&quot; location)&lt;br /&gt;&lt;br /&gt;My application.cfc contains both sets of DSN info, and uses a switch, based on the current cgi. server variables , to determine which DSN to run from, along with other server specific settings (such as google map key). So, wherever the site is viewed, my application &apos;knows&apos; which content paths and other settings to use for each page request or query.&lt;/p&gt;
&lt;p&gt;&lt;em&gt;(So... what about MuraCMS?) &lt;/em&gt;&lt;br /&gt;&lt;br /&gt;One of the first things I noticed when installing Mura locally was the way that it cached the local directory structure. So if my Mura site was installed in a subdirectory of the local site, e.g. http://localhost:8500/sitename/wwwroot/test/ , Mura would store the setting &quot;/sitename/wwwroot/test&quot; automatically, and prepend this path to all required assets. Wonderful. Superb. But...&lt;/p&gt;
&lt;p&gt;Then I pushed the Mura files to the live server, uploading the works via FTP. And found I had a problem. That path was still being prepended to all assets... but didn&apos;t exist.&lt;br /&gt;On the live server i was simply working from http://sitename.com/test/ , so everything was instantly broken - images, javascript, css. &lt;br /&gt;&lt;br /&gt;Unlike my own usual practices, where all primary templates or pages live in the site root,&amp;nbsp; Mura is designed to use &apos;root relative&apos; paths, rather than location relative, which makes sense if content will be served from different directory levels. &lt;br /&gt;&lt;br /&gt;So instead of simply looking in ../css/ for a css file, it wants to use the path /sitename/wwwroot/test/css&lt;/p&gt;
&lt;p&gt;&lt;em&gt;(So... how did I fix this? Get to the point already... )&lt;/em&gt;&lt;/p&gt;
&lt;p&gt;Half of any solution is identifying the problem. In this case, I needed to find out &quot;how to use two different sets of configuration variables&quot; , and set out to find the answer.&lt;/p&gt;
&lt;p&gt;On setup, mura creates and populates a file called &apos;settings.ini.cfm&apos;, which is a simple text file with variables and values stored one per line. And inside, I could see the paths were being stored as text strings. Cool. Now I know where it lives... but how to change it on the fly, and keep two different versions?&lt;/p&gt;
&lt;p&gt;I asked my question to the very friendly, patient guys on &lt;a href=&quot;http://www.getmura.com/index.cfm/blog/the-mura-show/&quot; target=&quot;_blank&quot;&gt;the Mura Show&lt;/a&gt; , but must not have asked correctly, or clearly enough. I came away thinking the solution was to set up a domain &apos;alias&apos; and somehow map a direct IP to my subfolder locally , which doesn&apos;t work since you can&apos;t put paths in the Windows hosts file... and i got into a right frustrating mess.&lt;/p&gt;
&lt;p&gt;Deciding to take another crack at it with fresh morning-coffee eyes, I got smart and did a bit of googling. And I found this, the settings.ini reference from the Mura site: &lt;a href=&quot;http://docs.getmura.com/index.cfm/installation-set-up/settingsinicfm-reference/&quot; target=&quot;_blank&quot;&gt;http://docs.getmura.com/index.cfm/installation-set-up/settingsinicfm-reference/ &lt;/a&gt;&lt;/p&gt;
&lt;p&gt;and... AHA! a classic RTFM moment.&lt;/p&gt;
&lt;p&gt;&lt;em&gt;(finally... the fix !)&lt;/em&gt;&lt;/p&gt;
&lt;p&gt;wouldn&apos;t you know it, the very first line of the settings.ini.cfm file is for the &quot;mode&quot;, (which i completely overlooked before, and the Mura team must not have thought of in reference to my seemingly vague questions. )&lt;/p&gt;
&lt;p&gt;The default mode is &apos;production&apos; and beyond the first few lines, all settings in the file are under a heading of [production]. The light started coming on right about now... they really did think of everything! &lt;br /&gt;&lt;br /&gt;So, all I had to do was create another grouping, and change that master &apos;mode&apos; setting. I simply duplicated all the lines below [production], added a new heading of [localdev] , and changed the settings to match those of my local server. (I also changed &apos;production&apos; paths to match the settings of my live production server with the simpler root directory structure) &lt;br /&gt;&lt;br /&gt;Just a few more steps - upload the changed file to the live server, and click &apos;reload application&apos; in the Mura admin.&amp;nbsp; Then, change my local copy of the settings.ini.cfm file to &apos;mode=localdev&apos; , and click &apos;reload application&apos; in my local admin as well. &lt;br /&gt;&lt;br /&gt;This caused the local settings to be loaded for the local site, and the production settings to be loaded for the production site ... and i am back in business, working in both locations with ease! &lt;br /&gt;&lt;br /&gt;Bearing in mind that any uploaded images will need to be manually copied with FTP, and some other things might need a little hand-holding, I am very pleased to be back in business with the freedom to work the way I am used to, with live, functioning copies of the complete site on both my local server and the live location.&lt;/p&gt;
&lt;p&gt;The only caveat at this stage - I&apos;ll have to be careful not to upload the settings.ini.cfm file, since I still don&apos;t have an &apos;automatic&apos; switch for which group of settings to use. But as long as my production version of the file says &quot;mode=production&quot; and my local file says &quot;mode=localdev&quot; , I should be good to go.&lt;/p&gt;
&lt;p&gt;&amp;nbsp;&lt;/p&gt; 
				</description>
				
				<category>ColdFusion</category>				
				
				<category>Mura CMS</category>				
				
				<pubDate>Sat, 04 Sep 2010 12:30:00 -0600</pubDate>
				<guid>http://www.miuaiga.com/index.cfm/2010/9/4/How-to-set-up-local-vs-production-settings-for-Mura-CMS</guid>
				
			</item>
			
			<item>
				<title>Tools to Live By: ClearContext plug-in for Outlook</title>
				<link>http://www.miuaiga.com/index.cfm/2010/7/14/Tools-I-Live-With-ClearContext-plugin-for-Outlook</link>
				<description>
				
				&lt;p&gt;I&apos;ve used MS Outlook for a few years now, as part of my GTD-ish system for tracking tasks, appointments, and of course email messages. After quite a while of using a tricked-out routine using some variations on the built-in outlook categories (those colored dots that outlook lets you tack onto any message, task or appointment), along with the usual gazillions-of-folders for projects, customers, billing, personal messages and every other possible categorization of outlook info - all managed by clicking and dragging messages and tasks here and there - I went looking for a better solution... and I am so glad I did.&lt;/p&gt;
&lt;p&gt;Enter &quot;Clear Context&quot; from&amp;nbsp;&lt;a href=&quot;http://www.clearcontext.com/&quot;&gt;http://www.clearcontext.com/&lt;/a&gt;&amp;nbsp;- this little add-in makes such a big difference to my day. While it boasts a long list of features ( see the user guide, here:&amp;nbsp;&lt;a href=&quot;http://www.clearcontext.com/user_guide/&quot;&gt;http://www.clearcontext.com/user_guide/&lt;/a&gt;&amp;nbsp;), I&apos;ll touch briefly on the ones I use the most, and let you see for yourself why i am so excited about this tool.&lt;/p&gt;
&lt;p&gt;1) Folders as &apos;projects&apos;. ClearContext analyzes your Outlook folders and uses those as the basis for what it calls &apos;projects&apos;. The entire application runs based on those folders - replacing outlook&apos;s somewhat limited category options with a limitless number of options for filing. When i get a new client or project, i create a folder, and once i&apos;ve put a message from a client in that folder, CC &apos;suggests&apos; that future messages from the same person go there as well. Unlike regular message folders, these same project/folder names are applied to your tasks, and CC&apos;s easy &apos;dashboard&apos; view lets me see all messages, tasks, attached files and contact information for anything in that folder or related to that &apos;project&apos;.&lt;/p&gt;
&lt;p&gt;2) Put stuff where it goes with keyboard shortcuts, and smart suggestions. With any message highlighted, i can hit ctrl+shift+m for an intuitive list of likely folders where this message belongs (ClearContext gets to know who you put where and suggests it back to you, becoming more accurate as time goes on). So, without taking my hands off the keys, i can file an entire day&apos;s worth of email in a matter of seconds. This is big, and the way it works is super slick.&lt;br /&gt;&lt;br /&gt;3) Defer / Unsubscribe. These are two separate features but both of them serve the same purpose - getting things out of your face that you don&apos;t want to see! With a single click i can &apos;defer&apos; any message for a set number of hours or days, or until a set time and date - it is removed from view, and at the set time, it comes back to my inbox as a new message. So, if stuff piles in for &apos;later&apos; while i am working on correspondence for &apos;now&apos;, i can defer everything else until i am ready to deal with it, and don&apos;t even have to look at it until then. &apos;Unsubscribe&apos; uses the message subject to create a rule which puts all messages using that same subject line into a special folder &apos;clear context deferred&apos;, which i look at and then empty to deleted items every few days. This is also huge - repeat emails, junk alerts, group messages where i am bcc&apos;d but really don&apos;t need to be - they all go away, never to be seen, clicked or managed again (unless i want to ... then they are easy to find)&amp;nbsp;&lt;/p&gt;
&lt;p&gt;4) Tasks from messages. More keyboard shortcuts, or a click on a single toolbar icon, allows me to create an outlook &apos;task&apos; from any message. Even if I file or delete the email message (which i often do, once a task is made) , CC saves a task with the due date i specify, and the email text as the body of the message, with the original message attached. This makes it uber-easy to look through my to-do list , by category, and see what needs to be done. If i mark the task complete, or delete it, the original message is still where i put it, for future reference, without the need to refile it from &apos;to do&apos; to the project it belongs to. This is incredibly useful for the way i work, and the way i use Outlook.&lt;/p&gt;
&lt;p&gt;5) Do not disturb. Turns off auto send/receive for a limited time, and hides the &apos;you have mail&apos; icon along with any sounds related to same. Click that, leave me alone, I am working.&lt;/p&gt;
&lt;p&gt;6) Follow-up. When sending any message, there&apos;s an easy option to &apos;follow up&apos;. This creates an automated alert, again at a time and/or date i specify, which is automatically cancelled when somebody replies to the message (lots of options there for who must reply to cancel the follow-up, etc) . If i send off a proposal&amp;nbsp;(or even more importantly, a bill)&amp;nbsp;and want to make sure the client receives it , I simply click the follow-up button and can put the whole thing out of mind. If the client replies, the alert is cancelled - if they don&apos;t, i get reminded to follow up. Super simple, super useful.&amp;nbsp;&lt;br /&gt;&lt;br /&gt;Overall, my goal is to keep things organized and my inbox empty so i don&apos;t have to think about any of it. By making easy to file and find all email messages, tasks and other important &apos;to do&apos; data, I can free my &apos;mental RAM&apos; from carrying those things around, and focus on whatever i am doing at the time. (Now, what was I doing... ?)&lt;br /&gt;&lt;br /&gt;If you use Outlook&apos;s tasks, or file your messages by folder, or just like to keep your inbox clean, I suggest you take a test drive (30 day free trial, $89.95 to buy w/ money-back guarantee) of this super useful, well-maintained and carefully implemented add-in.&amp;nbsp;&lt;br /&gt;You can also check in with other users in the active, well-supported Clear Context forums:&amp;nbsp;&lt;a href=&quot;http://online.clearcontext.com/forums/&quot;&gt;http://online.clearcontext.com/forums/&lt;/a&gt;&amp;nbsp;&amp;nbsp;to find how it can help you get more done.&lt;/p&gt;
&lt;p&gt;&amp;nbsp;&lt;/p&gt;
&lt;p&gt;&amp;nbsp;&lt;/p&gt; 
				</description>
				
				<category>Tools &amp;amp; Tips</category>				
				
				<category>Getting Things Done</category>				
				
				<pubDate>Wed, 14 Jul 2010 10:08:00 -0600</pubDate>
				<guid>http://www.miuaiga.com/index.cfm/2010/7/14/Tools-I-Live-With-ClearContext-plugin-for-Outlook</guid>
				
			</item>
			
			<item>
				<title>jQuery AJAX get() function cached in IE</title>
				<link>http://www.miuaiga.com/index.cfm/2010/5/30/jQuery-AJAX-get-function-cached-in-IE</link>
				<description>
				
				&lt;p&gt;From the &apos;how the heck were we supposed to know this?&apos; department, a little tidbit I&apos;d like to share, perhaps saving some poor, frustrated developer from the same type of mystifying madness:&lt;/p&gt;
&lt;p&gt;&lt;em&gt;&lt;strong&gt;jQuery &quot;get()&quot; operations are cached in IE unless you pass in a unique URL !&lt;br /&gt;&lt;/strong&gt;&lt;/em&gt;&lt;/p&gt;
&lt;p&gt;By cached, I mean, you can have a remote page with a query or other function, which responds to a unique set of values being passed in, and it will work fine in Firefox, but in IE, you&apos;ll get the same results from the remote page, even if the response is unique (like query results that have changed, for the same record), unless the values you are passing in via get()  are also unique (i.e. you haven&apos;t looked up that particular record yet).&lt;/p&gt;
&lt;p&gt;So, before you go banging your head on the floor and screaming out &apos;why oh why can&apos;t i find the problem, let alone the solution?!?&apos; (not that i would ever do that), read this post, which i found via a quick Google search for &apos;jquery get IE cache&apos; : &lt;a href=&quot;http://www.sitecrafting.com/blog/ajax-ie-caching-issues/&quot; target=&quot;_blank&quot;&gt;http://www.sitecrafting.com/blog/ajax-ie-caching-issues/&lt;/a&gt;&amp;nbsp;&lt;/p&gt;
&lt;p&gt;I only had the presence of mind to run that search once i got my ajax results to display as an alert on the calling page, and deduced that the displayed content was based on the first values passed in, while all other updates and requests were ignored.&lt;/p&gt;
&lt;p&gt;The fix, as that post suggests, is to create a unique url. In this case, i use javascript to append a random number to my function, - in this case, I just use javascript to create a random number right inline, then add that as a meaningles url variable to the page in the get() function:&lt;/p&gt;
&lt;p&gt;&amp;nbsp;&amp;nbsp; &amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;nbsp;&amp;nbsp;&amp;nbsp; // set up unique url&lt;br /&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;nbsp;&amp;nbsp;&amp;nbsp; var randomNo = Math.floor(Math.random()*9999999);&lt;br /&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;nbsp;&amp;nbsp;&amp;nbsp; var urlStr = &apos;journalLookup.cfm?r=&apos; + randomNo;&lt;br /&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;nbsp;&amp;nbsp;&amp;nbsp; // run get function using randomized URL&lt;br /&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;nbsp;&amp;nbsp;&amp;nbsp; $.get(&lt;strong&gt;urlStr&lt;/strong&gt;,{jdate:dateLookup}, function(data){&amp;nbsp; .... [ function here ]&lt;/p&gt;
&lt;p&gt;If this saves you some aggravation, let me know in the comments ... maybe i&apos;ll feel better about the time i just wasted chasing this mystery &apos;feature&apos; in IE!!&lt;/p&gt;
&lt;p&gt;&amp;nbsp;&lt;/p&gt; 
				</description>
				
				<category>Javascript</category>				
				
				<category>jQuery</category>				
				
				<pubDate>Sun, 30 May 2010 18:37:00 -0600</pubDate>
				<guid>http://www.miuaiga.com/index.cfm/2010/5/30/jQuery-AJAX-get-function-cached-in-IE</guid>
				
			</item>
			
			<item>
				<title>When Alt+Tab just isn&apos;t cutting it: VistaSwitcher!</title>
				<link>http://www.miuaiga.com/index.cfm/2010/5/3/When-AltTab-just-isnt-cutting-it-VistaSwitcher</link>
				<description>
				
				&lt;p&gt;Any PC user who likes keyboard shortcuts knows about the Alt + Tab combination built into&amp;nbsp; all recent versions of Windows. It has been improved in recent versions, and the visual options and speed in Win 7 are pretty good... but not good enough. &lt;br /&gt;&lt;br /&gt;That&apos;s where VistaSwitcher comes in - I just found this little app, and it is instantly part of my workflow, providing a more visible, more intuitive way to switch between open programs or documents.&lt;/p&gt;
&lt;p&gt;From the description:&lt;/p&gt;
&lt;p&gt;&amp;nbsp;&lt;/p&gt;
&lt;table border=&quot;0&quot; cellspacing=&quot;2&quot; cellpadding=&quot;8&quot; width=&quot;100%&quot; align=&quot;center&quot; bgcolor=&quot;#dcdcdc&quot;&gt;
&lt;tbody&gt;
&lt;tr bgcolor=&quot;#ffffff&quot;&gt;
&lt;td width=&quot;30%&quot;&gt;&lt;em&gt;&lt;strong&gt;Alt + Tab&lt;/strong&gt;&lt;/em&gt;&lt;/td&gt;
&lt;td width=&quot;70%&quot;&gt;&lt;em&gt;Switch between ALL open windows&lt;/em&gt;&lt;/td&gt;
&lt;/tr&gt;
&lt;tr bgcolor=&quot;#ffffff&quot;&gt;
&lt;td&gt;&lt;em&gt;&lt;strong&gt;Alt + ` (Backtick)&lt;/strong&gt;&lt;/em&gt;&lt;/td&gt;
&lt;td&gt;&lt;em&gt;Switch between open windows of a single application (for example, MS  Word documents or Explorer folders)&lt;/em&gt;&lt;/td&gt;
&lt;/tr&gt;
&lt;/tbody&gt;
&lt;/table&gt;
&lt;p&gt;&lt;em&gt;Also, you can &lt;strong&gt;switch  between open windows with only the mouse&lt;/strong&gt;. No keyboard  shortcuts required! Just hold your right mouse button down and scroll  the wheel up or down to select the window you want.&lt;/em&gt;&lt;/p&gt;
&lt;p&gt;Check it out here:&lt;/p&gt;
&lt;p&gt;&lt;a href=&quot;http://www.ntwind.com/software/vistaswitcher/download.html&quot; target=&quot;_blank&quot;&gt;http://www.ntwind.com/software/vistaswitcher/download.html&lt;/a&gt;&lt;/p&gt; 
				</description>
				
				<category>Tools &amp;amp; Tips</category>				
				
				<pubDate>Mon, 03 May 2010 02:45:00 -0600</pubDate>
				<guid>http://www.miuaiga.com/index.cfm/2010/5/3/When-AltTab-just-isnt-cutting-it-VistaSwitcher</guid>
				
			</item>
			
			<item>
				<title>Add a value to a stored list in mySQL using FIND_IN_SET() and CONCAT()</title>
				<link>http://www.miuaiga.com/index.cfm/2010/3/12/Add-a-value-to-a-stored-list-in-mySQL-using-FINDINSET-and-CONCAT</link>
				<description>
				
				For example, a column in a candy store database contains a list of flavors that the different shapes of candy come in. We have another table of flavors, but rather than a third relative table of flavors and product relationships, the IDs of the flavors are simply stored in a column in the products table.

So, you might have a value like
12,14,35,36,78,105
where each number represents the value of a form checkbox in the product admin for this site, and and ID for a flavor in the flavors table. The store admin checks the boxes for the flavors that product comes in, and those IDs get stored as a list in a specific column.

For the purpose of example, suppose the column is simply called &apos;flavors&apos;, and you need to add the flavor &apos;wowzaberry&apos; (id 199) to all of the products that currently have the flavor &apos;razzoberry&apos; (id 105) - with the added logic so that if a candy product already has the new flavor, we don&apos;t add it twice.

&lt;code&gt;
UPDATE tbl_products
SET flavors = CONCAT(flavors,&apos;,199&apos;)
WHERE FIND_IN_SET(&apos;105&apos;,flavors)
AND NOT FIND_IN_SET(&apos;199&apos;,flavors)
&lt;/code&gt;

This says
Add (concat) a comma (,) and 199 (the new ID number)
To any record that already has ID 105 in the flavors column
And that does not already have ID 199 in that same column 
				</description>
				
				<category>mySQL</category>				
				
				<pubDate>Fri, 12 Mar 2010 15:04:00 -0600</pubDate>
				<guid>http://www.miuaiga.com/index.cfm/2010/3/12/Add-a-value-to-a-stored-list-in-mySQL-using-FINDINSET-and-CONCAT</guid>
				
			</item>
			
			<item>
				<title>HTML Formatter ColdFusion-friendly code cleanup tool</title>
				<link>http://www.miuaiga.com/index.cfm/2010/2/8/HTML-Formatter-ColdFusionfriendly-code-cleanup-tool</link>
				<description>
				
				&lt;p&gt;No matter how clean your code, there&apos;s something to be said for a fast, clean pre-launch cleanup with a reliable code formatter . My favorite by far is the HTML Formatter from LogicHammer.com:&amp;nbsp; &lt;a href=&quot;http://www.logichammer.com/html-formatter/&quot; target=&quot;_blank&quot;&gt;http://www.logichammer.com/html-formatter/&lt;br /&gt;&lt;br /&gt;&lt;/a&gt;Complete with a full set of ColdFusion-friendly options, this simple tool makes cleaning your code a snap. I use it as I&apos;m working, to clean up the work-so-far at any point, and before final launch to make sure the production code will be as easy as possible to maintain and revisit later on. It is a standalone executable, which means there&apos;s no installation, and you can put in anywhere you like on your hard drive.&lt;/p&gt;
&lt;p&gt;I simply create a taskbar shortcut on my Windows PC and drag the files I want to clean directly from the &apos;project&apos; view in Eclipse onto the icon - couldn&apos;t be faster, simpler or easier. I prefer to have my original files altered, with the originals automatically put in a specified backup location - you can also assign the option to leave the original alone and create a cleaned-up copy.&lt;/p&gt;
&lt;p&gt;Among other fav features, HTML Formatter ships with a simple text-based config file which makes it incredibly easy to specify tags to ignore or to indent, and file extensions to be formatted or skipped ( you can run the formatting on specific files, or an entire directory).&lt;/p&gt;
&lt;p&gt;For only $14.99 you get all the features and 2 years of updates (there is also an 8.99 version with a basic feature set). The program&apos;s developer has answered every question I ask directly and has been very helpful with customizations, even building in some features I requested a while back (for the record - I&apos;m not affiliated with logichammer in any way, just very pleased with this slick little tool).&lt;/p&gt; 
				</description>
				
				<category>ColdFusion</category>				
				
				<category>Tools &amp;amp; Tips</category>				
				
				<category>WebDev</category>				
				
				<pubDate>Mon, 08 Feb 2010 23:44:00 -0600</pubDate>
				<guid>http://www.miuaiga.com/index.cfm/2010/2/8/HTML-Formatter-ColdFusionfriendly-code-cleanup-tool</guid>
				
			</item>
			
			<item>
				<title>How to find lowercase (no caps) values in mySQL (and Capitalize them with ColdFusion)</title>
				<link>http://www.miuaiga.com/index.cfm/2010/2/4/How-to-find-lowercase-no-caps-values-in-mySQL-and-Capitalize-them-with-ColdFusion</link>
				<description>
				
				I have a request from a client to help clean up some customer-entered data in a mySQL database, specifically, we need to capitalize all of the values in a column called &apos;user_city&apos;

For the actual capitalization, I am using the very handy CapFirstTitle() function from CFlib : &lt;a href=&quot;http://www.cflib.org/index.cfm?event=page.udfbyid&amp;udfid=116&quot;&gt;http://www.cflib.org/index.cfm?event=page.udfbyid&amp;udfid=116&lt;/a&gt;

But first, I need to find all of the entries that are not already capitalized. This dataset has tens of thousands of records , including some with a blank value in the &apos;city&apos; field - no need to loop all of that just to fix our caps! 

So, here&apos;s the SQL query code to find all of the records with no capital letters at all, by comparing to a lower() all lowercase version of the same value:

&lt;code&gt;
SELECT  user_city, ID 
FROM site_users
WHERE user_city = lower(user_city)
AND NOT user_city = &apos;&apos;
ORDER  by user_city
&lt;/code&gt;

And here is the full CFoutput / CFquery code for the loop and update with Coldfusion, and the CapFirstTitle() function in the head of the page: 

&lt;code&gt;
&lt;cfoutput query=&quot;myQueryAbove&quot;&gt;
	&lt;cfquery datasource=&quot;#application.dsn#&quot;&gt;
	UPDATE site_users
	SET user_city = &apos;#capFirstTitle(myQueryAbove.user_city)#&apos;
	WHERE ID = #myQueryAbove.ID#
	&lt;/cfquery&gt;
&lt;/cfoutput&gt;

&lt;/code&gt;

for other columns you could use OR in the first query and an additional statement in the second, or just change the queries, run the page again, or even, make the column name a variable and just change it once in the head of the page... easy. 
				</description>
				
				<category>mySQL</category>				
				
				<category>ColdFusion</category>				
				
				<pubDate>Thu, 04 Feb 2010 18:30:00 -0600</pubDate>
				<guid>http://www.miuaiga.com/index.cfm/2010/2/4/How-to-find-lowercase-no-caps-values-in-mySQL-and-Capitalize-them-with-ColdFusion</guid>
				
			</item>
			
			<item>
				<title>mySQL str_to_date converts text formatted dates and times to real SQL timestamps</title>
				<link>http://www.miuaiga.com/index.cfm/2010/1/10/mySQL-strtodate-converts-text-formatted-dates-and-times-to-real-SQL-timestamps</link>
				<description>
				
				&lt;p&gt;I am working on a site where dates have been stored as text strings in a mySQL database, such as &apos;2009-10-17&apos; , and I need to create a &apos;search by date&apos; function where a given start and end date can be compared to the date stored in the database. In other words, i need to convert the text-formatted date to a real &apos;datetime&apos; value , that can be compared with (greater than) and (less than) logic within the query itself.&lt;/p&gt;
&lt;p&gt;Like all things CF/mySQL , there are usually multiple ways to get things done. After kicking it around a few different ways, I settled on mySQL&apos;s built-in &quot;str_to_date&quot; function as the easiest and most efficient solution.&lt;/p&gt;
&lt;p&gt;The str_to_date()&amp;nbsp; function takes two arguments: the string that is to be converted, and a format string, which uses the same syntax as mysql date_format() and other related mySQL date functions.&lt;/p&gt;
&lt;p&gt;Since the dates are entered in &apos;yyyy-mm-dd&apos; format, my format string is&quot; %Y-%m-%d &quot;&lt;br /&gt;(Note the capital Y which signifies a 4-digit year)&lt;/p&gt;
&lt;p&gt;My query now looks something like this - note the second line:&lt;/p&gt;
&lt;p&gt;SELECT&lt;br /&gt;str_to_date(aa.date_published,&apos;%Y-%m-%d&apos;) as articleDate,&lt;br /&gt;aa.title, aa.ID,&lt;br /&gt;aa.author,&lt;br /&gt;aa.article&lt;br /&gt;FROM articles_table ...&lt;/p&gt;
&lt;p&gt;This converts the date, 2009-10-17,&lt;br /&gt;to a datetime stamp,&lt;br /&gt;{ts &apos;2009-09-17 00:00:00&apos;}, &lt;br /&gt;which can now be used for any type of date comparisons.&lt;/p&gt;
&lt;p&gt;To keep things clean, if an article happens to be entered with a different format that does not match our format pattern (i.e. somebody types in &apos;10/17/09&apos;),&amp;nbsp; str_to_date() will simply return an empty string in that column, rather than throwing an error.&lt;/p&gt;
&lt;p&gt;The mySQL specification for this and other functions is here: &lt;br /&gt;&lt;a href=&quot;http://dev.mysql.com/doc/refman/5.0/en/date-and-time-functions.html#function_str-to-date&quot;&gt;http://dev.mysql.com/doc/refman/5.0/en/date-and-time-functions.html#function_str-to-date&lt;/a&gt;&lt;/p&gt;
&lt;p&gt;&amp;nbsp;&lt;/p&gt;
&lt;p&gt;&amp;nbsp;&lt;/p&gt;
&lt;p&gt;&amp;nbsp;&lt;/p&gt; 
				</description>
				
				<category>mySQL</category>				
				
				<category>WebDev</category>				
				
				<pubDate>Sun, 10 Jan 2010 14:00:00 -0600</pubDate>
				<guid>http://www.miuaiga.com/index.cfm/2010/1/10/mySQL-strtodate-converts-text-formatted-dates-and-times-to-real-SQL-timestamps</guid>
				
			</item>
			
			<item>
				<title>New TinyMCE lets you paste as plain text automatically</title>
				<link>http://www.miuaiga.com/index.cfm/2010/1/7/New-TinyMCE-lets-you-paste-as-plain-text-automatically</link>
				<description>
				
				&lt;p&gt;When building web applications, one of the most common functions involves allowing a site administrator to add or edit content on a page via some sort of &apos;wysiwyg&apos; (what you see is what you get) editor. My tool of choice for this purpose is the very versatile, relatively light TinyMCE ( &lt;a href=&quot;http://tinymce.moxiecode.com/&quot;&gt;tinymce.moxiecode.com&lt;/a&gt;)&lt;br /&gt;&lt;br /&gt;As great as these tools are, it is inevitable that the average site administrator will want to copy and paste some text from a word processing function like MS Word or WordPerfect, both of which add invisible formatting to the copy-and-pasted text, which in turn can really mess up even the best of web designs. &lt;br /&gt;&lt;br /&gt;TinyMCE has had a very nice &apos;paste from word&apos; plugin for as long as I can remember, but it still requires the user to click a tiny icon for the &apos;paste from word&apos; popup, and then paste their text into that. ( There is also a &apos;paste as plain text&apos; option which removes all formatting just as if you&apos;d copied into notepad first, then pasted into the web form). So, even with these great options, I still find myself answering more than a few support calls related to text not looking quite like it should (or worse) when copying from Word.&lt;/p&gt;
&lt;p&gt;Much to my delight, I&apos;ve found a much better solution - the newest version of TinyMCE has the &quot;paste&quot; plugin built in, and it now includes options for cleaning up the text automatically when pasting right into the main text box (without needing to use the littlepopup icons).&lt;/p&gt;
&lt;p&gt;As seen on the paste plugin page (&lt;a href=&quot;http://wiki.moxiecode.com/index.php/TinyMCE:Plugins/paste&quot;&gt;TinyMCE:Plugins/paste - Moxiecode Documentation Wiki&lt;/a&gt;) you simply need to include &apos;paste&apos; in the list of plugins when initializing the tinyMCE script, and then can call the cleanup options like this:&lt;/p&gt;
&lt;p&gt;&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; paste_auto_cleanup_on_paste : true,&lt;br /&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;nbsp;&amp;nbsp;&amp;nbsp; paste_remove_styles: true,&lt;br /&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;nbsp;&amp;nbsp;&amp;nbsp; paste_remove_styles_if_webkit: true,&lt;br /&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;nbsp;&amp;nbsp;&amp;nbsp; paste_strip_class_attributes: true,&lt;/p&gt;
&lt;p&gt;This runs the &apos;paste from word&apos; function automatically, then removes any remaining inline style and class attributes , leaving you with nice clean paragraph-formatted html.&lt;/p&gt;
&lt;p&gt;so, whether your clients remember to use that little button or not, whatever they paste (via ctrl+v on their keyboards) will be stripped clean, ready to be shown in pristine valid html format on your site.&lt;br /&gt;&lt;/p&gt; 
				</description>
				
				<category>Javascript</category>				
				
				<category>WebDev</category>				
				
				<pubDate>Thu, 07 Jan 2010 02:13:00 -0600</pubDate>
				<guid>http://www.miuaiga.com/index.cfm/2010/1/7/New-TinyMCE-lets-you-paste-as-plain-text-automatically</guid>
				
			</item>
			
			<item>
				<title>Keyboard Shortcuts I use all the time</title>
				<link>http://www.miuaiga.com/index.cfm/2009/12/27/Keyboard-Shortcuts-I-use-all-the-time</link>
				<description>
				
				&lt;p&gt;&lt;strong&gt;WIN 7&lt;/strong&gt;&lt;strong&gt;&lt;br /&gt;--------&lt;br /&gt;&lt;br /&gt;&lt;/strong&gt;&lt;strong&gt;Win + Arrow left/right:&amp;nbsp; &lt;/strong&gt;&lt;br /&gt;snap open window to 1/2 monitor frame&lt;/p&gt;
&lt;p&gt;&lt;strong&gt;Win + Arrow up/down:&amp;nbsp; &lt;/strong&gt;&lt;br /&gt; up: full screen (maximize window)&lt;br /&gt;down: restore / minimize&lt;br /&gt;&lt;br /&gt;&lt;strong&gt;Alt + F4:&lt;br /&gt;&lt;/strong&gt;Exit program / close window&lt;/p&gt;
&lt;p&gt;&lt;strong&gt;Win + D:&lt;/strong&gt;&lt;br /&gt;Show desktop&lt;/p&gt;
&lt;p&gt;&amp;nbsp;&lt;/p&gt;
&lt;p&gt;&lt;strong&gt;Eclipse (w/ CFeclipse)&lt;br /&gt;----------&lt;br /&gt;&lt;br /&gt;Ctrl+Alt+Up/Down arrows&lt;br /&gt;&lt;/strong&gt;Duplicate line&lt;strong&gt;&lt;br /&gt;&lt;/strong&gt;&lt;/p&gt;
&lt;p&gt;&lt;strong&gt;Alt+Up/Down&amp;nbsp;&lt;strong&gt;arrows&lt;br /&gt; &lt;/strong&gt;&lt;/strong&gt;Move line&lt;strong&gt;&lt;strong&gt;&lt;br /&gt; &lt;/strong&gt;&lt;/strong&gt;&lt;/p&gt;
&lt;p&gt;&lt;strong&gt;Alt + F &amp;gt; A&lt;/strong&gt;&lt;br /&gt;Save as&lt;/p&gt;
&lt;p&gt;&lt;strong&gt;Ctrl + Shft + R&lt;br /&gt;&lt;/strong&gt;Open file w/ search by name&lt;strong&gt;&lt;/strong&gt;&lt;/p&gt;
&lt;p&gt;&lt;strong&gt;&lt;br /&gt;&lt;/strong&gt;&lt;/p&gt;
&lt;p&gt;&lt;strong&gt;Firefox&lt;br /&gt;----------&lt;/strong&gt;&lt;/p&gt;
&lt;p&gt;&lt;strong&gt;Ctrl+T&lt;br /&gt;&lt;/strong&gt;New Tab&lt;/p&gt;
&lt;p&gt;&lt;strong&gt;Ctrl+T&lt;br /&gt;&lt;/strong&gt;New&amp;nbsp; Window&lt;strong&gt;&lt;/strong&gt;&lt;/p&gt;
&lt;p&gt;&lt;strong&gt;Ctrl+Shift+Q&lt;/strong&gt; &lt;br /&gt;Inspect Element&lt;strong&gt; (Firebug)&lt;br /&gt;&lt;/strong&gt;&lt;/p&gt;
&lt;p&gt;&lt;strong&gt;Ctrl+Shift+F&lt;br /&gt; &lt;/strong&gt;Display Element Information&lt;strong&gt; &lt;/strong&gt;&lt;strong&gt;(Web Dev Tools)&lt;/strong&gt;&lt;/p&gt;
&lt;p&gt;&lt;strong&gt;Ctrl+Shift+W&lt;br /&gt; &lt;/strong&gt;Close window (close all tabs)&lt;strong&gt; &lt;/strong&gt;&lt;/p&gt;
&lt;p&gt;&lt;strong&gt;Ctrl+W&lt;br /&gt; &lt;/strong&gt;Close current tab&lt;/p&gt; 
				</description>
				
				<category>Tools &amp;amp; Tips</category>				
				
				<category>Getting Things Done</category>				
				
				<pubDate>Sun, 27 Dec 2009 12:12:00 -0600</pubDate>
				<guid>http://www.miuaiga.com/index.cfm/2009/12/27/Keyboard-Shortcuts-I-use-all-the-time</guid>
				
			</item>
			
			<item>
				<title>How to show changed input and select fields with jQuery</title>
				<link>http://www.miuaiga.com/index.cfm/2009/12/10/How-to-show-changed-input-and-select-fields-with-jQuery</link>
				<description>
				
				Here are a few quick easy jquery functions that will add a class of &apos;changed&apos; to any input or select box if it is changed, and will remove that class if the value is reset to the default. 

&lt;code&gt;

		// inputs
		$(&apos;form.myForm :input&apos;).change(function(){
		var defval = $(this)[0].defaultValue;
		if ($(this).val()!=defval){
			$(this).addClass(&apos;changed&apos;);
		} else {
		 	$(this).removeClass(&apos;changed&apos;);
		}
		}).keyup(function(){
		 	$(this).trigger(&apos;change&apos;);
		});

		// select boxes
		$(&apos;form.myForm select&apos;).change(function(){
		var defval = $(this).find(&apos;option[defaultSelected=true]&apos;).val();
		if ($(this).val()!=defval){
			$(this).addClass(&apos;changed&apos;);
		} else {
		 	$(this).removeClass(&apos;changed&apos;);
		}
		}).keyup(function(){
		 	$(this).trigger(&apos;change&apos;);
		});

&lt;/code&gt;

Note in both cases we use keyup (onkeyup) to trigger the &apos;change&apos; event. This allows the browser to show the changed class as soon as the user changes the value using a keyboard, rather than &apos;onblur&apos;. 
				</description>
				
				<category>Javascript</category>				
				
				<category>jQuery</category>				
				
				<category>WebDev</category>				
				
				<pubDate>Thu, 10 Dec 2009 04:16:00 -0600</pubDate>
				<guid>http://www.miuaiga.com/index.cfm/2009/12/10/How-to-show-changed-input-and-select-fields-with-jQuery</guid>
				
			</item>
			
			<item>
				<title>How to find Specific Column Names or Types in a mySQL Database</title>
				<link>http://www.miuaiga.com/index.cfm/2009/12/6/How-to-find-Specific-Column-Names-or-Types-in-a-mySQL-Database</link>
				<description>
				
				I&apos;m working on a rather extensive CMS admin application, and need to make some adjustments to all of the &quot;sort&quot; fields in the database. Many of the tables have either a &apos;sort&apos; or &apos;sort_order&apos; (and in one case, I think I saw &apos;SortOrder&apos;), and I need hunt them down, creating a list of column names and table names so i can quickly find the columns I want to edit.

I could open each table one by one, and look for those column names... but of course, there&apos;s a much better way:

&lt;code&gt;
SELECT TABLE_NAME, COLUMN_NAME, DATA_TYPE
FROM INFORMATION_SCHEMA.COLUMNS
WHERE lower(column_name) LIKE &apos;%sort%&apos;
AND TABLE_SCHEMA=&apos;//my database name here//&apos;
&lt;/code&gt;

This returns a perfectly formatted query of table names and column names, along with the &apos;data type&apos; for any column containing &apos;sort&apos; (or &apos;Sort&apos;). Now it will be a snap to make my changes to all of the numeric sort fields in the entire database. 

The query can be modified to return all sorts of useful info, such as all columns in the entire database:

&lt;code&gt;
SELECT TABLE_NAME, COLUMN_NAME, DATA_TYPE
FROM INFORMATION_SCHEMA.COLUMNS
WHERE TABLE_SCHEMA=&apos;//my database name here//&apos;
&lt;/code&gt;

or all columns with a specific data type

&lt;code&gt;
SELECT TABLE_NAME, COLUMN_NAME, DATA_TYPE
FROM INFORMATION_SCHEMA.COLUMNS
WHERE TABLE_SCHEMA=&apos;//my database name here//&apos;
AND DATA_TYPE=&apos;varchar&apos;
&lt;/code&gt;

And then, if you wanted to get really lazy, er, creative... you can loop the results of that query, and &apos;do stuff&apos; to all of the columns automatically with just a few more lines:

&lt;code&gt;
alter table #table_Name# modify #column_name# VARCHAR(55) ; 
&lt;/code&gt;

(this would set the size of your varchar field to 55 characters, for example) 
				</description>
				
				<category>mySQL</category>				
				
				<category>WebDev</category>				
				
				<pubDate>Sun, 06 Dec 2009 02:29:00 -0600</pubDate>
				<guid>http://www.miuaiga.com/index.cfm/2009/12/6/How-to-find-Specific-Column-Names-or-Types-in-a-mySQL-Database</guid>
				
			</item>
			
			<item>
				<title>Installing SQL Server 2008 Management Studio Express</title>
				<link>http://www.miuaiga.com/index.cfm/2009/11/30/Installing-SQL-Server-2008-Management-Studio-Express</link>
				<description>
				
				&lt;p&gt;I don&apos;t do much work on MS SQL, but a recent project requires I connect to a remote SQL 2008 database, so I went looking for the new version of the SQL Server Management Studio Express program which has worked so well, and so simply, for SQL 2005 databases.&lt;/p&gt;
&lt;p&gt;Simple enough, right? Not quite. It didn&apos;t take me long on &lt;a href=&quot;http://www.google.com/search?q=how+to+install+sql+server+2008+management+studio+express&quot; target=&quot;_blank&quot;&gt;Google&lt;/a&gt; to realize i was far from the only one having trouble installing just the Management Studio, without the server components. Microsoft has managed to make this process incredibly unintuitive, including links and download pages which don&apos;t actually point you to what you think you are getting.&lt;br /&gt;( for examples, see the google link above... i&apos;m being really nice in this post by comparison!)&lt;/p&gt;
&lt;p&gt;The best compromise i could find was the official MS download page, which offers a 160+mb file containing the full database server system. Blog posts mention compatibility issues (Win7 did throw up some warnings of its own when i started the process, so i backed out and kept looking), incomplete installations and the need to run the installer twice so you can &apos;add&apos; the Management Studio as a component to an existing installation.&lt;/p&gt;
&lt;p&gt;Huh? Exactly.&lt;/p&gt;
&lt;p&gt;So, anyway...&amp;nbsp; for those that might be in the same plight... I have the solution!&lt;/p&gt;
&lt;p&gt;Go here: &lt;a href=&quot;http://www.microsoft.com/web/Downloads/platform.aspx&quot;&gt;http://www.microsoft.com/web/Downloads/platform.aspx&lt;/a&gt; and install the MS &apos;Web Platform Installer&apos;.&amp;nbsp; Then, when the installer loads up, find the little &apos;customize&apos; link under the &quot;Database&quot; section, where you can tick the boxes for the components you want to install. ( see image )&lt;/p&gt;
&lt;p&gt;Once i got it going, this was actually a slick little installer. &lt;br /&gt;(So finally I have SQL 2008 Management Studio ready to go. &lt;br /&gt;Now, what was i going to use it for?)&lt;/p&gt;
&lt;p&gt;&amp;nbsp;&lt;/p&gt; 
				</description>
				
				<category>Tools &amp;amp; Tips</category>				
				
				<category>WebDev</category>				
				
				<pubDate>Mon, 30 Nov 2009 20:04:00 -0600</pubDate>
				<guid>http://www.miuaiga.com/index.cfm/2009/11/30/Installing-SQL-Server-2008-Management-Studio-Express</guid>
				
				<enclosure url="http://www.miuaiga.com/enclosures/sql2008install.jpg" length="116263" type="image/jpeg"/>
				
			</item>
			
			<item>
				<title>How to find Duplicate Entries in a mySQL Database</title>
				<link>http://www.miuaiga.com/index.cfm/2009/11/25/How-to-find-Duplicate-Entries-in-a-mySQL-Database</link>
				<description>
				
				Here&apos;s a quick easy query that will return all records where a given column&apos;s value appears more than once. 

The trick is the &apos;group by&apos; phrase, combined with the selection of the &apos;count(*)&apos; value, which simply counts the records found for each match of &apos;Name&apos;. 

This query will return any records where the same value appears more than one time in the given column (in this case, the &apos;Name&apos; column), along with the &apos;Counter&apos; value showing how many times the duplicate appears.

&lt;code&gt;
SELECT Name,count(*) as Counter
FROM Table_Name
GROUP BY Name
HAVING Counter &gt; 1
&lt;/code&gt; 
				</description>
				
				<category>mySQL</category>				
				
				<category>WebDev</category>				
				
				<pubDate>Wed, 25 Nov 2009 19:00:00 -0600</pubDate>
				<guid>http://www.miuaiga.com/index.cfm/2009/11/25/How-to-find-Duplicate-Entries-in-a-mySQL-Database</guid>
				
			</item>
			
			<item>
				<title>Javascript How To: Add a Number of Days to a Date</title>
				<link>http://www.miuaiga.com/index.cfm/2009/11/11/Javascript-How-To-Add-a-Number-of-Days-to-a-Date</link>
				<description>
				
				I have a form where a user can input a date in the format mm/dd/yyyy, and we need to add an &apos;expiration date&apos; that is 30 days from the date entered, regardless of calendar month, leap years, or other complex calculations. 

Thankfully, javascript already has the &apos;setDate()&apos; function built in. We just have to parse the date object (a full javascript formatted date string) out of the given form input ( e.g. &apos;11/10/2009&apos;).

Easy enough - first we parse out the numeric date/time object, and in this example, write it to the screen. 

Then, we add 30 days (the number of days can be changed in the setting for the &apos;interval&apos; variable - use a negative number to remove days)

Again, this example simply writes the date to the screen. In the current usage, I will use that date value to populate another text input in the same form as the initial date being entered.

&lt;code&gt;
&lt;script type=&quot;text/javascript&quot;&gt;
function setExpDate(formDate){
	// set number of days to add
	var interval = 30;
	var startDate = new Date(Date.parse(formDate));
	document.write(&apos;start: &apos; + startDate);
	var expDate = startDate;
	expDate.setDate(startDate.getDate() + interval);
	document.write(&apos;&lt;br&gt;expire: &apos; + expDate);
};
&lt;/script&gt;
&lt;/code&gt;

Example usage on a form input:

&lt;code&gt;

&lt;input type=&quot;text&quot; size=&quot;10&quot; maxlength=&quot;10&quot; id=&quot;startDate&quot; name=&quot;startDate&quot; onblur=&quot;setExpDate(this.value)&quot;&gt; &#xa0;&#xa0;

&lt;/code&gt; 
				</description>
				
				<category>Javascript</category>				
				
				<category>WebDev</category>				
				
				<pubDate>Wed, 11 Nov 2009 13:29:00 -0600</pubDate>
				<guid>http://www.miuaiga.com/index.cfm/2009/11/11/Javascript-How-To-Add-a-Number-of-Days-to-a-Date</guid>
				
			</item>
			</channel></rss>