Warning: Cannot modify header information - headers already sent by (output started at /home/mptim/public_html/modules/Blogs/Blogs.module.php:431) in /home/mptim/public_html/modules/Blogs/rssfeed.php on line 101 mProduction Blog - Excel
http://www.mproduction.net/admin/index.php?mact=Blogs,cntnt01,rssfeed,0&cntnt01show=category&cntnt01catid=12&cntnt01returnid=-1
various items I come acrossentim@timothymahoney.comTim MahoneyRemoving spaces from text in Excel<p>I've been meaning to come up with a way to create an Excel library for tasks I do very often; I suppose this will be a good place to start it and update it.</p>
<p>The TRIM function removes spaces from the right and left sides of whatever text you're processing, like so:</p>
<h4>Formula:</h4>
<code>=TRIM(A1)</code>
<p>" Hello " will process to: "Hello"</p>
<p>However, if you want to remove spaces from within a text cell, leaving all other characters / numbers / etc., you need to use the SUBSTITUTE function for simple cases.</p>
<h4>Formula</h4>
<code>=SUBSTITUTE(A1," ","")</code>
<p>" Hello Thar " will process to "HelloThar"</p>
<p>First in what will probably be a lot of posts about Excel stuff. I use it WAY too often for text processing.</p>
http://www.mproduction.net/index.php?mact=Blogs,cntnt01,showentry,0&cntnt01entryid=6&cntnt01returnid=15
Wed, 09 Sep 2009 09:26:27 -0500Use Excel to generate a whole crapload of SQL queries<p>I had to update a whole lot of rows, and instead of sitting down and doing some ridiculous export and re-update, I figured I'd just write an SQL query in an Excel Concatenate statement and use the ids in the spreadsheet. WAH LA</p>
<p>First 2 columns are A : the id and B : the value I want to replace.</p>
<p>In column C, I put:</p>
<code>=CONCATENATE("UPDATE tablename SET fieldname='",B1,"' WHERE idfield=",A1,";")</code>
<p>Then, just copy and paste that cell all the way down, copy the queries, and paste them into a phpMyAdmin SQL text box and run.</p>
http://www.mproduction.net/index.php?mact=Blogs,cntnt01,showentry,0&cntnt01entryid=7&cntnt01returnid=15
Wed, 09 Sep 2009 16:04:51 -0500