title: How to separate words in a "sentence" with spaces?
body: <h2>Background</h2>
  
  <p>Looking to automate creating Domains in JasperServer. Domains are a "view" of data for creating ad hoc reports. The names of the columns must be presented to the user in a human readable fashion.</p>
  
  <h2>Problem</h2>
  
  <p>There are over 2,000 possible pieces of data from which the organization could theoretically want to include on a report. The data are sourced from non-human-friendly names such as:</p>
  
  <blockquote>
    <p>payperiodmatchcode
    labordistributioncodedesc
    dependentrelationship actionendoption
    actionendoptiondesc addresstype
    addresstypedesc historytype
    psaddresstype rolename
    bankaccountstatus
    bankaccountstatusdesc bankaccounttype
    bankaccounttypedesc beneficiaryamount
    beneficiaryclass beneficiarypercent
    benefitsubclass beneficiaryclass
    beneficiaryclassdesc benefitactioncode
    benefitactioncodedesc
    benefitagecontrol
    benefitagecontroldesc
    ageconrolagelimit
    ageconrolnoticeperiod</p>
  </blockquote>
  
  <h2>Question</h2>
  
  <p>How would you automatically change such names to:</p>
  
  <ul>
  <li>pay period match code</li>
  <li>labor distribution code desc</li>
  <li>dependent relationship</li>
  </ul>
  
  <h2>Ideas</h2>
  
  <ul>
  <li><p>Use Google's <a href="http://www.google.co.uk/search?q=caseactioncode&amp;ie=utf-8&amp;oe=utf-8&amp;aq=t&amp;rls=org.mozilla%3aen-US%3aofficial&amp;client=firefox-a#sclient=psy&amp;hl=en&amp;client=firefox-a&amp;rls=org.mozilla%3aen-US%3Aofficial&amp;q=labordistributioncodedesc&amp;aq=f&amp;aqi=&amp;aql=&amp;oq=labordistributioncodedesc&amp;gs_rfai=&amp;pbx=1&amp;fp=1&amp;bav=on.2,or.r_gc.r_pw.&amp;cad=b" rel="nofollow">Did you mean</a> engine, however I think it violates their TOS:</p>
  
  <p><code>lynx -dump «url» | grep "Did you mean" | awk ...</code></p></li>
  </ul>
  
  <h2>Languages</h2>
  
  <p>Any language is fine, but text parsers such as Perl would probably be well-suited. (The column names are English-only.)</p>
  
  <h2>Unnecessary Prefection</h2>
  
  <p>The goal is not 100% perfection in breaking words apart; the following outcome is acceptable:</p>
  
  <ul>
  <li>enrollmenteffectivedate -> Enrollment Effective Date</li>
  <li>enrollmentenddate -> Enroll Men Tend Date</li>
  <li>enrollmentrequirementset -> Enrollment Requirement Set</li>
  </ul>
  
  <p>No matter what, a human will need to double-check the results and correct many. Whittling a set of 2,000 results down to 600 edits would be a dramatic time savings. To fixate on <em>some</em> cases having multiple possibilities (e.g., therapistname) is to miss the point altogether.</p>