Terrence, you neglected to mention that 'sql_lookup' bit in your example actually requires some setup in advance.Right you are, sql_lookup is a function in SQL::Catalog and SQL::Catalog archives all SQL for a project to a database for later use. Thus, the first step in designing a SQL-oriented database app is to create all your SQL along with labels and store it. then, you can retrieve it using SQL::Catalog.
and then use any DBI shortcut interface to execute the SQL for the desired results.
<code> <a> <b> <big> <blockquote> <br /> <dd> <dl> <dt> <em> <font> <h1> <h2> <h3> <h4> <h5> <h6> <hr /> <i> <li> <nbsp> <ol> <p> <small> <strike> <strong> <sub> <sup> <table> <td> <th> <tr> <tt> <u> <ul>