infused / dbf

DBF is a small, fast Ruby library for reading dBase, xBase, Clipper, and FoxPro database files.
http://rdoc.info/projects/infused/dbf
MIT License
262 stars 88 forks source link

Column Name with Capitalize #84

Closed MansurAje closed 6 years ago

MansurAje commented 6 years ago

Dear Team , i have a trouble when use DBF with Capitalize name Column.. how ti fix it ? // in my controller @itemases = DBF::Table.new("/mnt/g/DATA/SALES/ITEMAS.DBF")

// in views 
    <%  

        i=0
        @itemases.each do |record|
        i+=1
    %>
            <%=i%>
            <%= record.C_ITENO%>
        <br>
    <%end%>

//  result 
undefined method `C_ITENO'

please help screenshot from 2018-05-21 09-15-33

infused commented 6 years ago

Try record['C_ITENO'] or record[:C_ITENO].

MansurAje commented 6 years ago

Sorry for late responds, Thanks for help.