Clarity

Expand all | Collapse all

Reading xls data with GEL column-by-column, instead of row-by-row

  • 1.  Reading xls data with GEL column-by-column, instead of row-by-row

    Posted Oct 12, 2010 07:08 AM
    Group,

    I am in the process of modifying a gel script that I have to make it read data from a xls file column-by_column instead of row by row. I was hoping that someone with experience doing this could maybe point me in the right direction as far as what would be the best way to acheive this.

    Below is the code I will be modifying:

    <!-- Attributes part -->
    <sql:query var="obs_details">SELECT * FROM [${p_worksheet2}$$]</sql:query>
    <core:forEach trim="false" items="${obs_details.rowsByIndex}" var="obs_row" indexVar="i">
    <core:forEach var="attColumnName" items="${obs_details.columnNames}" indexVar="j" step="1">
    <core:choose>
    <core:when test="${j==0}">

    <core:set var="division">${obs_row[j]}</core:set>
    </core:when>
    <core:when test="${j==1}">

    <core:set var="platform_group">${obs_row[j]}</core:set>

    </core:when>
    <core:when test="${j==2}">

    <core:set var="supply_platform">${obs_row[j]}</core:set>

    </core:when>
    <core:when test="${j==3}">

    <core:set var="team">${obs_row[j]}</core:set>
    </core:when>
    </core:choose>
    </core:forEach>

    Regards,
    Marlon


  • 2.  RE: Reading xls data with GEL column-by-column, instead of row-by-row

    Posted Oct 12, 2010 07:08 AM
    Anyone have input for Marlon?

    Thanks,
    --K


  • 3.  Moving to correct board.

     
    Posted Oct 12, 2010 07:08 AM
    Moving to correct board.