Reputation: 2469
I have tried to_xls for exporting data but Is there any good way to export data in excel file from 2 different tables in rails. For example I have a user table and user details table now I want my excel file to have records of both the tables ..
Upvotes: 3
Views: 122
Reputation: 162
Have you tried this
`send_data book, :filename => "sample.xls", :type => "application/vnd.ms-excel"`
`
Upvotes: 1