tag:blogger.com,1999:blog-151483712024-03-13T08:42:25.669-07:00Documenting Lifeex uteroChad S. Lauritsenhttp://www.blogger.com/profile/08137855501067699809noreply@blogger.comBlogger25125tag:blogger.com,1999:blog-15148371.post-5800660924097819952011-09-19T19:40:00.001-07:002011-09-19T19:59:51.541-07:00I didn't attend 12 years of Evil Doctor School to be Called "Mr. Evil"...<span class="Apple-style-span"><a href="http://a2.sphotos.ak.fbcdn.net/hphotos-ak-ash4/310662_10150298014698611_600178610_7931610_846563369_n.jpg" onblur="try {parent.deselectBloggerImageGracefully();} catch(e) {}"><img style="float:left; margin:0 10px 10px 0;cursor:pointer; cursor:hand;width: 200px; height: 212px;" src="http://a2.sphotos.ak.fbcdn.net/hphotos-ak-ash4/310662_10150298014698611_600178610_7931610_846563369_n.jpg" border="0" alt="" /></a><br /></span><div><span class="Apple-style-span" style="line-height: 14px;"><div>COLE: I want a snack.</div><div>PAPA: No.</div><div>C: Why not?</div><div>P: Because I'm evil.</div><div>C: You're NOT EVIL!</div><div>P: Sort of?</div><div>C: Yeah, you're sort of evil.</div></span></div>Chad S. Lauritsenhttp://www.blogger.com/profile/08137855501067699809noreply@blogger.com0tag:blogger.com,1999:blog-15148371.post-1427926810492141032011-08-05T14:19:00.000-07:002011-08-05T14:32:12.928-07:00Something's Gotta Give<div>Quality of life for me has been noticeably lower this year. Injuries, aches, pains have increased in both frequency and duration. Currently, I'm dealing with some lower back pain. I firmly believe this increase in morbidities are due to my morbid obesity--the demon I've never been able to shake. </div><div><br /></div><div>At any rate, the net result is something of a vicious cycle: I don't feel like exercising because x body part hurts, so I don't exercise even when I feel I could get my butt down to the gym. Instead, I turn to my old pal, food, for a little pop in my brain that makes me forget/feel comforted, even if only for less than a minute. The irony is that exercise, while I hate the boredom of it, actually produces longer lasting and higher quality euphoria.</div><div><br /></div><div>I have looked into weight loss surgery, and in the end will probably choose to go through with it as a weight loss tool. It is the only thing I've observed in my life that actually has data that shows the weight stays off--and for me, nothing else really matters. </div><div><br /></div><div>About 7 years ago I lost over 100 lbs using the Weight Watchers method. Of course it worked, but the key for me was tracking the number of calories, fat and fiber you eat everyday. Obviously, very few people sustain that kind of pedantic record-keeping for the long haul, even if you have easy access to the information. (If someone knows differently, please comment.)</div><div><br /></div><div>Since that 100lb loss, I have gained all of it back and more. There are some psychological drivers at work here that I'm working on with a therapist, but I strongly doubt that talking to a head shrink will result in a permanent shrinkage of my waistline. (Bad pun. Sorry.) Something's gotta give. I'm 38 years old, but feel like I'm 83.</div><div><br /></div><div>I frequently feel that if "I could only lose the weight," then I'd have fewer problems. This might be one of the issues I should explore with my therapist. It doesn't make sense. But I do think that I'd have more energy. I'd be less afraid to do something that requires sustained physical activity, like spending all day on my feet at an amusement park. </div>Chad S. Lauritsenhttp://www.blogger.com/profile/08137855501067699809noreply@blogger.com1tag:blogger.com,1999:blog-15148371.post-22217199388648126402008-02-25T19:55:00.000-08:002008-02-25T19:56:15.531-08:00H on Cake<object width="425" height="350"><param name="movie" value="http://www.youtube.com/v/ARsCzJLZhG8"></param><embed src="http://www.youtube.com/v/ARsCzJLZhG8" type="application/x-shockwave-flash" width="425" height="350"></embed></object><br /><br />This is what happens after feeding Harris cake before bed.Chad S. Lauritsenhttp://www.blogger.com/profile/08137855501067699809noreply@blogger.com0tag:blogger.com,1999:blog-15148371.post-60340241013842584192008-02-25T19:38:00.001-08:002008-02-25T19:39:09.591-08:00Harmonica Boy<object width="425" height="355"><param name="movie" value="http://www.youtube.com/v/D0yoi23ukg4&rel=1"></param><param name="wmode" value="transparent"></param><embed src="http://www.youtube.com/v/D0yoi23ukg4&rel=1" type="application/x-shockwave-flash" wmode="transparent" width="425" height="355"></embed></object><br />I whipped out my dad's old harmonica, 30+ years old, and let the toddler experiment with it. It was comical.Chad S. Lauritsenhttp://www.blogger.com/profile/08137855501067699809noreply@blogger.com0tag:blogger.com,1999:blog-15148371.post-55752135092753803782008-02-25T19:36:00.001-08:002008-02-25T19:37:12.339-08:00A Boy of Few Words<object height="355" width="425"><param name="movie" value="http://www.youtube.com/v/rgCgcrULsAU&rel=1"><param name="wmode" value="transparent"><embed src="http://www.youtube.com/v/rgCgcrULsAU&rel=1" type="application/x-shockwave-flash" wmode="transparent" height="355" width="425"></embed></object><br /><br />I like to think he takes after his papa.Chad S. Lauritsenhttp://www.blogger.com/profile/08137855501067699809noreply@blogger.com0tag:blogger.com,1999:blog-15148371.post-3290967591187883512008-01-12T12:22:00.000-08:002008-01-12T12:22:37.813-08:00<div style="MARGIN: 0px auto 10px; TEXT-ALIGN: center"><a href="http://3.bp.blogspot.com/_pPOrygbs0uk/R4khjKZLXmI/AAAAAAAAABs/ELvJxiWZRF8/s1600-h/PB200197.JPG"><img id="BLOGGER_PHOTO_ID_" alt="" src="http://3.bp.blogspot.com/_pPOrygbs0uk/R4khjKZLXmI/AAAAAAAAABs/ELvJxiWZRF8/s320/PB200197.JPG" border="0" /></a> </div><br />We made our trip back to the heartland this fall. Grandma Lilly turned 80 and we had a great turnout at her birthday bash. It coincided nicely with Thanksgiving. Shown above are the Hasch grandkids. <a href="http://home.planetlauritsen.com/photos/Thanksgiving2007/">More photos like this </a>are available on the web.<div style='clear:both; text-align:CENTER'><a href='http://picasa.google.com/blogger/' target='ext'><img src='http://photos1.blogger.com/pbp.gif' alt='Posted by Picasa' style='border: 0px none ; padding: 0px; background: transparent none repeat scroll 0% 50%; -moz-background-clip: initial; -moz-background-origin: initial; -moz-background-inline-policy: initial;' align='middle' border='0' /></a></div>Chad S. Lauritsenhttp://www.blogger.com/profile/08137855501067699809noreply@blogger.com0tag:blogger.com,1999:blog-15148371.post-2129739896564358082008-01-12T12:09:00.000-08:002008-01-12T12:10:15.779-08:00Christmas<a href="http://1.bp.blogspot.com/_pPOrygbs0uk/R4kepqZLXlI/AAAAAAAAABk/4r3AGWwevFY/s1600-h/PC250242.JPG"><img id="BLOGGER_PHOTO_ID_" style="CLEAR: both; FLOAT: left; MARGIN: 0px 10px 10px 0px" alt="" src="http://1.bp.blogspot.com/_pPOrygbs0uk/R4kepqZLXlI/AAAAAAAAABk/4r3AGWwevFY/s320/PC250242.JPG" border="0" /></a> Finally I was able to get the camera, myself, and the computer together in a room (without the kids) long enough to copy the pictures off of it. Here's some <a href="http://home.planetlauritsen.com/photos/Christmas2007/">photos</a> for friends and family to enjoy.<div style='clear:both; text-align:LEFT'><a href='http://picasa.google.com/blogger/' target='ext'><img src='http://photos1.blogger.com/pbp.gif' alt='Posted by Picasa' style='border: 0px none ; padding: 0px; background: transparent none repeat scroll 0% 50%; -moz-background-clip: initial; -moz-background-origin: initial; -moz-background-inline-policy: initial;' align='middle' border='0' /></a></div>Chad S. Lauritsenhttp://www.blogger.com/profile/08137855501067699809noreply@blogger.com0tag:blogger.com,1999:blog-15148371.post-1666096823542680852007-08-22T22:03:00.001-07:002007-08-22T22:28:33.168-07:00Creating AudiobooksI love my iPod. I love being able to carry around my entire music collection in my pocket. Being a long-time iTunes user, it's a shame I didn't discover podcasts before the iPod. But the real killer: audiobooks. They took me totally by surprise and I am enamored. Audiobooks from iTunes are expensive, but there are <a href="http://dlc.clevnet.org/">other sources</a>. The problem is, when you rip audiobook CDs, you can get them into iTunes/iPod with no problems, but navigation is a Sisyphean chore.<br /><br />Sure, iPod and iTunes remember where you left off, but a single inadvertent wheel click can undo that "bookmark." What's worse, my crazy entertainment-center-with-iPod-dock likes to spontaneously start the iPod playing when you turn the system off. No, I want the real thing when it comes to audiobooks. I want a single file or small number of files; I want them to show up in my audiobooks group thingy. There are guides on the web to get you thru these issues. (short version: create a single AAC encoded file and rename to .m4b, then import to iTunes) But the Holy Grail has been chapter breaks. I can remember "Chapter 12" better than 04:23:08. And I want them where the author intended, not necessarily at the unfortunate boundaries imposed by the CD medium.<br /><br /><a onblur="try {parent.deselectBloggerImageGracefully();} catch(e) {}" href="http://www.ilounge.com/assets/images/logo05.gif"><img style="margin: 0pt 0pt 10px 10px; float: right; cursor: pointer; width: 200px;" src="http://www.ilounge.com/assets/images/logo05.gif" alt="" border="0" /></a><a href="http://jrlearnsmedia.com/blog/archive/2007/07/29/enhanced-podcasting-on-windows.aspx">Slideshow adapter</a> to the rescue! Props to ejsjrnc over at <a href="http://forums.ilounge.com/showthread.php?t=202606">iLounge </a><img src="file:///C:/DOCUME%7E1/csl/LOCALS%7E1/Temp/moz-screenshot-2.jpg" alt="" />for finding it and documenting it for the rest of us. It's a geek tool. But if you want what I want, you're probably a geek, too.Chad S. Lauritsenhttp://www.blogger.com/profile/08137855501067699809noreply@blogger.com0tag:blogger.com,1999:blog-15148371.post-49369423613889310462007-07-02T09:27:00.000-07:002007-07-02T09:29:47.901-07:00Here is WisdomToday I heard this on <a href="http://www.keylife.org/">Key Life</a>, and thought it was worth sharing and remembering:<br /><br /><blockquote><span style="font-style: italic;">No matter how rich or famous you may become, the number of people who come to your funeral will still depend on the weather.</span><br /><span style="font-style: italic;"> --Unknown</span><br /></blockquote>Chad S. Lauritsenhttp://www.blogger.com/profile/08137855501067699809noreply@blogger.com0tag:blogger.com,1999:blog-15148371.post-12619756654390610652007-06-20T09:36:00.000-07:002007-06-20T09:37:58.478-07:00Cole, Take 2<a href="http://1.bp.blogspot.com/_pPOrygbs0uk/RnlXkHCxGCI/AAAAAAAAAAk/Oi2Sva360Ek/s1600-h/P6120212.JPG"><img id="BLOGGER_PHOTO_ID_" style="margin: 0px 10px 10px 0px; clear: both; " alt="" src="http://1.bp.blogspot.com/_pPOrygbs0uk/RnlXkHCxGCI/AAAAAAAAAAk/Oi2Sva360Ek/s320/P6120212.JPG" border="0" /></a> <br /><br clear="all"> Here's a closer-up shot of the new boy in town.<div style="clear: both; text-align: left;"><a href="http://picasa.google.com/blogger/" target="ext"><img src="http://photos1.blogger.com/pbp.gif" alt="Posted by Picasa" style="border: 0px none ; padding: 0px; background: transparent none repeat scroll 0% 50%; -moz-background-clip: -moz-initial; -moz-background-origin: -moz-initial; -moz-background-inline-policy: -moz-initial;" align="middle" border="0" /></a></div>Chad S. Lauritsenhttp://www.blogger.com/profile/08137855501067699809noreply@blogger.com0tag:blogger.com,1999:blog-15148371.post-9531890579530228652007-06-20T09:05:00.000-07:002007-06-22T11:36:37.796-07:00Bruning, Nebraska: Hot Air Ballooning Hotbed<a onblur="try {parent.deselectBloggerImageGracefully();} catch(e) {}" href="http://1.bp.blogspot.com/_pPOrygbs0uk/RnlVoHCxGBI/AAAAAAAAAAc/nrYg4f-0_VI/s1600-h/Photo_052807_004.jpg"><img style="margin: 0pt 10px 10px 0pt; float: left; cursor: pointer; width: 320px; height: 240px;" src="http://1.bp.blogspot.com/_pPOrygbs0uk/RnlVoHCxGBI/AAAAAAAAAAc/nrYg4f-0_VI/s320/Photo_052807_004.jpg" alt="" id="BLOGGER_PHOTO_ID_5078184202410727442" border="0" /></a><br />Since I've begun to crew for a balloon-pilot colleague, I've become interested in this sport. I've been doing a little research. So, having grown up in southeast Nebraska, about 10 miles from Bruning, I was surprised to learn of a significant event that occurred there in 1960. The equipment used in modern hot air ballooning was first demonstrated outside Bruning by Ed Yost (who coincidentally died just a few weeks ago [No! Not in a balloon wreck!].) He was the first to use an airborne heater to keep the balloon aloft.<br /><br />Of course, hot air ballooning had been around for almost 200 years at that point. The advent of a portable mechanism to keep the air hot allowed the pilot to maneuver in the vertical plane, and the sport received a shot in the arm. Currently there are, according to <a href="http://en.wikipedia.org/wiki/Hot_air_balloon">My Favorite Site in the World</a>, 7500 balloons in the US.<br /><br />I found it somewhat ironic that Southeast Nebraska would be involved in the revival of a sport which, as far as I know, has almost no participation in that part of the world. I don't recall ever seeing a hot air balloon as a kid. Someone, please correct me if I'm wrong about the dearth of ballooning in SE Nebr.<br /><br />Ahh...Bruning. I have fond memories of Pastor Thomas Damrow, who shepherded the flock Trinity Lutheran Church in Bruning during my childhood there. God bless you, if you're out there, Pastor.<br /><br /><br /><span style="text-decoration: underline;"><br /></span><a href="http://en.wikipedia.org/wiki/Hot_air_balloon"></a>Chad S. Lauritsenhttp://www.blogger.com/profile/08137855501067699809noreply@blogger.com0tag:blogger.com,1999:blog-15148371.post-83067819485463594982007-06-19T09:18:00.000-07:002007-06-19T19:06:02.523-07:00Chomsky Refuted?While leafing through the Plain Dealer this morning, I came across an unusual spot. Seems there's a tribe of 350 or so in Brazil with an actual "primitive" language. As a student of linguistics, I have long accepted the claim that no language is <span style="font-style: italic;">primitive</span>, that is, any thought can be expressed in any language. Building from these assumptions, smart folks like Noam Chomsky have tried to distill what the common denominators are to all human languages: Which features of human language are "hard-wired" in our brains from birth? What allows us to acquire language and use it to express abstract thought? They have claimed for several decades that certain universals are found in every human language, or shall we say, <span style="font-style: italic;">almost </span>every human language?<br /><br />The language of the Pirahã tribe of Brazil reportedly lacks some of the "universal" constructs we'd expect to see in a language. According to <a href="http://www.spiegel.de/international/spiegel/0,1518,414291,00.html">Der Spiegel</a>, one of these missing constructs is recursion. In English recursion is rendered using subordinate clauses. For example: "This is the dog <span style="text-decoration: underline;">that </span><span style="font-style: italic;">bit the man</span> <span style="text-decoration: underline;">who</span> <span style="font-style: italic;">came to our door</span>." (Relative pronouns underlined, subordinate clauses in italics.) Clauses modify and describe each other, so in the end the full meaning of the discourse is dependent upon its context.<br /><br />The chief expert on the Pirahã language today is Daniel Everett, who not surprisingly has been working among the tribe as a Bible translator. It may be that his analysis is incorrect or incomplete. Others apparently have been dispatched to test his claims. The Plain Dealer article (sorry, no link available as of this writing) mentioned that current traditionalists had regarded Everett's claims as "putative" and insufficient to revolutionize the study of human language. I hope that Everett is not being dismissed as a lightweight because of his work as a Bible translator.<br /><br />In the end it may be that the Pirahã language will serve to advance the claims of the thought-depends-on-language school--those who claim, "You cannot conceive in your mind what you cannot find words for." I don't know. Something in my world view seems to reject this idea...e.g. God, Trinity, infinity. But I must admit I could stand to learn from those who've dedicated much effort in the field.Chad S. Lauritsenhttp://www.blogger.com/profile/08137855501067699809noreply@blogger.com0tag:blogger.com,1999:blog-15148371.post-64672328207386188982007-06-15T13:25:00.000-07:002007-06-19T09:58:59.786-07:00Coleman Steven<a href="http://2.bp.blogspot.com/_pPOrygbs0uk/RnL12HCxF_I/AAAAAAAAAAM/LiDxxfART8s/s1600-h/P6140218.JPG"><img src="http://2.bp.blogspot.com/_pPOrygbs0uk/RnL12HCxF_I/AAAAAAAAAAM/LiDxxfART8s/s320/P6140218.JPG" alt="" id="BLOGGER_PHOTO_ID_" style="margin: 0pt 0pt 10px 10px; clear: both; float: right;" border="0" /></a> My, how our family has grown! We are proud to announce the birth of Coleman Steven on June 12, 2007. Here's the first official picture of "the boys." Praise the Lord for his blessings!<div style="clear: both; text-align: right;"><a href="http://picasa.google.com/blogger/" target="ext"><img src="http://photos1.blogger.com/pbp.gif" alt="Posted by Picasa" style="border: 0px none ; padding: 0px; background: transparent none repeat scroll 0% 50%; -moz-background-clip: -moz-initial; -moz-background-origin: -moz-initial; -moz-background-inline-policy: -moz-initial;" align="middle" border="0" /></a></div>Chad S. Lauritsenhttp://www.blogger.com/profile/08137855501067699809noreply@blogger.com0tag:blogger.com,1999:blog-15148371.post-84653804783870392502007-04-09T12:02:00.000-07:002007-04-09T12:04:13.521-07:00Which Church Father are You?<p>As for me, the results are in...</p><br /><br /><br /><table width="200" border="2" cellpadding="4" cellspacing="0"><br /><tr><br /><td><br /><div align="center"><br /><p><strong><font size="2">You’re St. Melito of Sardis!</font></strong></p><br /><p align="left"><font size="2">You have a great love of history and liturgy. You’re attached to the traditions of the ancients, yet you recognize that the old world — great as it was — is passing away. You are loyal to the customs of your family, though you do not hesitate to call family members to account for their sins.</font></p><br /><p align="left"><font size="1"><a href="http://www.fathersofthechurch.com/quiz/">Find out which Church Father you are at <em>The Way of the Fathers</em>!</a></font></p><br /></div><br /></td><br /></tr><br /></table>Chad S. Lauritsenhttp://www.blogger.com/profile/08137855501067699809noreply@blogger.com0tag:blogger.com,1999:blog-15148371.post-41225342441348136512007-04-08T18:33:00.000-07:002007-04-08T18:35:23.505-07:00Harrison Hunting Easter Eggs<p> <br /> This is Harrison crawling around the room with his broken leg. :-( hunting easter eggs. He broke it on Tuesday, we think it was when he was getting out of a toy car. Anyway, he'll have the cast for a 3 weeks. It doesn't slow him down much as you can see. He's definitely an inspiration to me.<br /> <center><br /> <object width="425" height="350"><br /> <param name="movie" value="http://www.youtube.com/v/eDVJ0-l895Y"></param><br /> <embed src="http://www.youtube.com/v/eDVJ0-l895Y" type="application/x-shockwave-flash" width="425" height="350"><br /> </embed><br /> </object><br /> </center>Chad S. Lauritsenhttp://www.blogger.com/profile/08137855501067699809noreply@blogger.com0tag:blogger.com,1999:blog-15148371.post-1168958084183433482007-01-16T06:31:00.000-08:002007-01-16T06:43:59.888-08:00Sending text and html email with JavaHere's a useful snippet for sending HTML formatted messages with the JavaMail API. One problem that I see out there is that people like nicely formatted HTML messages, but they don't often include a text-only part as well. This makes the message inaccessible to certain mail clients. This Mailer class shows an example of what I consider to be best practice in this arena.<br /><br />Enjoy!<br /><br /><span style="font-size:85%;"><br /><br /></span><span style="font-size:85%;"><span style="font-family:courier new;"><span style="font-family: courier new;">// $Header$</span><br /><span style="font-family: courier new;">// $Name$</span><br /><span style="font-family: courier new;">package com.sherwin.ordering.util;</span><br /><br /><span style="font-family: courier new;">import java.util.Date;</span><br /><span style="font-family: courier new;">import java.util.Properties;</span><br /><br /><span style="font-family: courier new;">import javax.mail.Address;</span><br /><span style="font-family: courier new;">import javax.mail.Message;</span><br /><span style="font-family: courier new;">import javax.mail.Session;</span><br /><span style="font-family: courier new;">import javax.mail.Transport;</span><br /><span style="font-family: courier new;">import javax.mail.internet.InternetAddress;</span><br /><span style="font-family: courier new;">import javax.mail.internet.MimeBodyPart;</span><br /><span style="font-family: courier new;">import javax.mail.internet.MimeMessage;</span><br /><span style="font-family: courier new;">import javax.mail.internet.MimeMultipart;</span><br /><br /><span style="font-family: courier new;">public class Mailer {</span><br /><br /><span style="font-family: courier new;"> /**</span><br /><span style="font-family: courier new;"> * @param args</span><br /><span style="font-family: courier new;"> */</span><br /><span style="font-family: courier new;"> public static void main(String[] args) throws Exception {</span><br /><span style="font-family: courier new;"> </span><br /><span style="font-family: courier new;"> if (args.length <><br /><span style="font-family: courier new;"> throw new IllegalArgumentException("2 arguments required");</span><br /><span style="font-family: courier new;"> }</span><br /><br /><span style="font-family: courier new;"> String email1 = args[0];</span><br /><span style="font-family: courier new;"> String email2 = args[1];</span><br /><br /><span style="font-family: courier new;"> Properties mailProperties = new Properties();</span><br /><span style="font-family: courier new;"> mailProperties.setProperty("protocol", "smtp");</span><br /><span style="font-family: courier new;"> mailProperties.setProperty("type", "transport");</span><br /><span style="font-family: courier new;"> mailProperties.setProperty("class", "com.sun.mail.smtp.SMTPTransport");</span><br /><span style="font-family: courier new;"> mailProperties.setProperty("mail.smtp.host", </span><br /><span style="font-family: courier new;"> System.getProperty("mail.smtp.host", // say on cmd line: -Dmail.smtp.host=xxx.yyy.zzz </span><br /><span style="font-family: courier new;"> "smtp.mycompany.com" // default if above not present</span><br /><span style="font-family: courier new;"> ));</span><br /><br /><span style="font-family: courier new;"> // setup the sending "session"</span><br /><span style="font-family: courier new;"> Session session = Session.getInstance(mailProperties, null);</span><br /><br /><span style="font-family: courier new;"> String htmlString = "<html><body>This has <i>HTML</i> in it. <a href="\">google</a>.</body></html>";</span><br /><span style="font-family: courier new;"> String txtString = "Hi text";</span><br /><br /><span style="font-family: courier new;"> Address[] recipients = { </span><br /><span style="font-family: courier new;"> new InternetAddress(email1, "Smitty"),</span><br /><span style="font-family: courier new;"> new InternetAddress(email2) </span><br /><span style="font-family: courier new;"> };</span><br /><br /><span style="font-family: courier new;"> // Assemble a MIME message</span><br /><span style="font-family: courier new;"> Message msg = new MimeMessage(session);</span><br /><span style="font-family: courier new;"> msg.addRecipients(Message.RecipientType.TO, recipients);</span><br /><span style="font-family: courier new;"> msg.setFrom(new InternetAddress("do-not-reply@mycompany.com", "My Company, Inc."));</span><br /><span style="font-family: courier new;"> msg.setSubject("Thanks for contacting us");</span><br /><span style="font-family: courier new;"> msg.setSentDate(new Date());</span><br /><span style="font-family: courier new;"> msg.setHeader("X-Mailer", "MyMailer $Name$");</span><br /><br /><span style="font-family: courier new;"> MimeMultipart mp = new MimeMultipart("alternative");</span><br /><br /><span style="font-family: courier new;"> MimeBodyPart txtPart = new MimeBodyPart();</span><br /><span style="font-family: courier new;"> txtPart.setText(txtString);</span><br /><br /><span style="font-family: courier new;"> MimeBodyPart htmlPart = new MimeBodyPart();</span><br /><span style="font-family: courier new;"> htmlPart.setContent(htmlString, "text/html");</span><br /><br /><span style="font-family: courier new;"> // it's probably important to have the txt part added first</span><br /><span style="font-family: courier new;"> // for the sake of less capable clients</span><br /><span style="font-family: courier new;"> mp.addBodyPart(txtPart);</span><br /><span style="font-family: courier new;"> mp.addBodyPart(htmlPart);</span><br /><span style="font-family: courier new;"> msg.setContent(mp);</span><br /><br /><span style="font-family: courier new;"> Transport.send(msg);</span><br /><span style="font-family: courier new;"> }</span><br /><span style="font-family: courier new;">}</span><br /><br /></span><span style="font-family:courier new;"></span></span>Chad S. Lauritsenhttp://www.blogger.com/profile/08137855501067699809noreply@blogger.com0tag:blogger.com,1999:blog-15148371.post-1143568619012272342006-03-28T09:56:00.000-08:002006-03-28T09:56:59.513-08:00Hierarchies in RDBMS<p class="mobile-post">Here's one I've been knocking around while: how do you most effectively model an infinite-depth hierarchical structure in a relational database like PostgreSQL, MySQL, etc.?</p><p class="mobile-post">A couple of choices come to mind: <br /> 1. a table with a field to contain the key value of its parent record<br /> 2. a table with a field containing a delimited value, like a filesystem pathname<br /> 3. A "link" table to map parent and child record IDs from the "data" table. This has the added capability of a record with multiple ancestors.</p><p class="mobile-post">It seems that options 1 & 2 are similar, the main difference being 3 supports multiple ancestors. This could be extra confusing if you don't need this capability. Finding all children of a parent would difficult to do, and I think impossible with SQL alone--some sort of iteration or recursion logic would need to be written, and it is likely to be very slow with large datasets--you can index the keys to find records quickly, but you have to query the index many times. </p><p class="mobile-post">Option 3 would support speedy lookups, but reorganizing the structure would be messy, especially for large datasets.</p><p class="mobile-post">Is there a way to get the best of both worlds? How can lookups be quick and re-orgs also?</p><p class="mobile-post">Someone must have an answer out there...</p>Chad S. Lauritsenhttp://www.blogger.com/profile/08137855501067699809noreply@blogger.com0tag:blogger.com,1999:blog-15148371.post-1139458275750910792006-02-08T20:09:00.000-08:002006-02-08T20:11:15.756-08:00BabyfaceThis is the man-cub in his high chair, evidently in a good mood. Love those baby blues.<a href="http://photos1.blogger.com/blogger/3964/1393/640/PC230411.jpg"><img style="CLEAR: all; FLOAT: left; MARGIN: 0px 10px 10px 0px; CURSOR: hand" alt="" src="http://photos1.blogger.com/blogger/3964/1393/320/PC230411.jpg" border="0" /></a> <a href='http://picasa.google.com/' target='ext'><img src='http://photos1.blogger.com/pbp.gif' alt='Posted by Picasa' style='border: 0px none ; padding: 0px; background: transparent none repeat scroll 0% 50%; -moz-background-clip: initial; -moz-background-origin: initial; -moz-background-inline-policy: initial;' align='middle' border='0' /></a> Chad S. Lauritsenhttp://www.blogger.com/profile/08137855501067699809noreply@blogger.com0tag:blogger.com,1999:blog-15148371.post-1132324238771678102005-11-18T06:25:00.000-08:002005-11-18T06:30:38.796-08:00Earworm: Poulenc GloriaVarious parts of this piece are floating around in my head. This morning, I was <span style="font-style: italic;">regaling</span> my wife and child with<br /><br /><span style="font-style: italic;"> Qui tollis pecata mundi</span><br /><br />DO I LIKE: Yes, very much. It's really Grown on me.<br />WHY: Obviously, since we've been singing it all week with <a href="http://www.clevelandorch.com/html/about/Choruses.asp">COC.</a> We had our first performance last night.<br /><br />Happy nine-month-birthday, Harrison!Chad S. Lauritsenhttp://www.blogger.com/profile/08137855501067699809noreply@blogger.com0tag:blogger.com,1999:blog-15148371.post-1131713059072124312005-11-11T04:44:00.000-08:002005-11-11T04:44:19.406-08:00Earworm: Edmund Fitzgerald<p class="mobile-post">Yesterday was the 30th anniversary of the sinking of the Edmund Fitzgerald on Lake Superior (Gitchi Gumi.) Consequently the Gordon Lightfoot song was discussed yesterday on NPR. Residues of it were in my consuciousness this morning. It seems odd that as I write this I am hard pressed to recall the words or melody.</p><p class="mobile-post">DO I LIKE? Don't really know it. Not even sure about the title. Seems a little beany for my tastes, though.</p>Chad S. Lauritsenhttp://www.blogger.com/profile/08137855501067699809noreply@blogger.com0tag:blogger.com,1999:blog-15148371.post-1131453958400998722005-11-08T04:45:00.000-08:002005-11-08T04:45:58.406-08:00Earworms<p class="mobile-post">It seems most mornings I have a song stuck in my head right as I wake. I thought that if I blogged it, a useful pattern may emerge. Or not. More to come...</p>Chad S. Lauritsenhttp://www.blogger.com/profile/08137855501067699809noreply@blogger.com0tag:blogger.com,1999:blog-15148371.post-1131453756014055342005-11-08T04:42:00.000-08:002005-11-08T06:49:44.853-08:00Earworm: Beethoven's Ninth<p class="mobile-post">This morning, I kept thinking </p><p class="mobile-post"><br /><blockquote><i><br />Seid entschlungen Millionen diesen Küß der ganzen Welt.</i><br /></blockquote></p><p class="mobile-post">DO I LIKE? So-so. It's grown on me. It's stirring, but not my favorite of his symphonies.</p><p class="mobile-post">WHY? No clue. Maybe b/c of COC reh last nite, but we reh nothing like that.<br /> </p>Chad S. Lauritsenhttp://www.blogger.com/profile/08137855501067699809noreply@blogger.com0tag:blogger.com,1999:blog-15148371.post-1123608311659230682005-08-09T10:25:00.000-07:002005-08-09T11:00:48.590-07:00What did I learn today?<style>div#b-navbar {display: none !important;}</style><br /><p class="mobile-post"><br />In today's edition of, "What did I learn today?" we explore the issue of etiquette.</p><p class="mobile-post">I stood today waiting for the walk signal at a busy intersection downtown. When the signal changed, a car lerched forward as if to cross in front of me, then stopped. I walked. After I had passed the front of the car, the driver honked at me, moved her cell phone's handset, and apparently uttered some unitelligible oathes regarding my person. I looked to a passing fellow pedestrian as if to silently plead my case. We mutually shrugged shoulders and kept going.<br /><br /><blockquote><br /><b> What did I learn today?</b><br />I learned that <i>"Even when you do the right thing, there's always someone who will find a reason to be pissed at you.</i><br /></blockquote><br /><br /></p>Chad S. Lauritsenhttp://www.blogger.com/profile/08137855501067699809noreply@blogger.com0tag:blogger.com,1999:blog-15148371.post-1123510923875347592005-08-08T07:22:00.000-07:002005-08-08T07:22:04.596-07:00Erie Sunset<p class="mobile-photo"><img width="320" src="http://photos1.blogger.com/blogger/3964/1393/0/Photo_080605_001-723875.jpg"/></p><p class="mobile-post">We got there just in time, so I whipped out the Treo 650 to grab this shot.</p>Chad S. Lauritsenhttp://www.blogger.com/profile/08137855501067699809noreply@blogger.com0tag:blogger.com,1999:blog-15148371.post-1123269164407381082005-08-05T12:10:00.000-07:002005-08-05T12:12:44.410-07:00the day has finally comewhen asked to select year of birth on a webpage today, mine was one further than was visible on the screen (without scrolling). and i thought the big 3-0 was significant.Chad S. Lauritsenhttp://www.blogger.com/profile/08137855501067699809noreply@blogger.com0