<HTML><BODY style="word-wrap: break-word; -khtml-nbsp-mode: space; -khtml-line-break: after-white-space; ">Sending CSV is sufficiently simple that I haven't bothered with a View, although a view where an array is dumped to CSV might be worthwhile, just like the JSON view works.  There might be a more elegant way, but this is very, very easy.<DIV><BR class="khtml-block-placeholder"></DIV><DIV>In order to have the browser automatically save the file/open in excel, just add these lines:</DIV><DIV><BR class="khtml-block-placeholder"></DIV><DIV style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; "><SPAN class="Apple-tab-span" style="white-space:pre">        </SPAN><FONT class="Apple-style-span" color="#B20022" face="Monaco" size="3"><SPAN class="Apple-style-span" style="font-size: 13px;"># Set the response content type to text/csv</SPAN></FONT></DIV><DIV style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; "><SPAN class="Apple-tab-span" style="white-space:pre">        </SPAN><FONT class="Apple-style-span" face="Monaco" size="3"><SPAN class="Apple-style-span" style="font-size: 13px;">$</SPAN></FONT><FONT class="Apple-style-span" color="#A000F0" face="Monaco" size="3"><SPAN class="Apple-style-span" style="font-size: 13px;">c</SPAN></FONT><FONT class="Apple-style-span" color="#B22200" face="Monaco" size="3"><SPAN class="Apple-style-span" style="font-size: 13px;">-&gt;</SPAN></FONT><FONT class="Apple-style-span" face="Monaco" size="3"><SPAN class="Apple-style-span" style="font-size: 13px;">response</SPAN></FONT><FONT class="Apple-style-span" color="#B22200" face="Monaco" size="3"><SPAN class="Apple-style-span" style="font-size: 13px;">-&gt;</SPAN></FONT><FONT class="Apple-style-span" face="Monaco" size="3"><SPAN class="Apple-style-span" style="font-size: 13px;">content_type</SPAN></FONT><FONT class="Apple-style-span" color="#B22200" face="Monaco" size="3"><SPAN class="Apple-style-span" style="font-size: 13px;">(</SPAN></FONT><FONT class="Apple-style-span" color="#0000FF" face="Monaco" size="3"><SPAN class="Apple-style-span" style="font-size: 13px;">'text/csv'</SPAN></FONT><FONT class="Apple-style-span" color="#B22200" face="Monaco" size="3"><SPAN class="Apple-style-span" style="font-size: 13px;">);</SPAN></FONT></DIV><DIV style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; "><SPAN class="Apple-tab-span" style="white-space:pre">        </SPAN><FONT class="Apple-style-span" face="Monaco" size="3"><SPAN class="Apple-style-span" style="font-size: 13px;">$</SPAN></FONT><FONT class="Apple-style-span" color="#A000F0" face="Monaco" size="3"><SPAN class="Apple-style-span" style="font-size: 13px;">c</SPAN></FONT><FONT class="Apple-style-span" color="#B22200" face="Monaco" size="3"><SPAN class="Apple-style-span" style="font-size: 13px;">-&gt;</SPAN></FONT><FONT class="Apple-style-span" face="Monaco" size="3"><SPAN class="Apple-style-span" style="font-size: 13px;">response</SPAN></FONT><FONT class="Apple-style-span" color="#B22200" face="Monaco" size="3"><SPAN class="Apple-style-span" style="font-size: 13px;">-&gt;</SPAN></FONT><FONT class="Apple-style-span" face="Monaco" size="3"><SPAN class="Apple-style-span" style="font-size: 13px;">header</SPAN></FONT><FONT class="Apple-style-span" color="#B22200" face="Monaco" size="3"><SPAN class="Apple-style-span" style="font-size: 13px;">(</SPAN></FONT><FONT class="Apple-style-span" color="#0000FF" face="Monaco" size="3"><SPAN class="Apple-style-span" style="font-size: 13px;">'Content-Disposition' </SPAN></FONT><FONT class="Apple-style-span" color="#B22200" face="Monaco" size="3"><SPAN class="Apple-style-span" style="font-size: 13px;">=&gt; </SPAN></FONT><FONT class="Apple-style-span" color="#0000FF" face="Monaco" size="3"><SPAN class="Apple-style-span" style="font-size: 13px;">"attachment; filename=report.csv"</SPAN></FONT><FONT class="Apple-style-span" color="#B22200" face="Monaco" size="3"><SPAN class="Apple-style-span" style="font-size: 13px;">);</SPAN></FONT></DIV><DIV><DIV><SPAN class="Apple-style-span" style="border-collapse: separate; border-spacing: 0px 0px; color: rgb(0, 0, 0); font-family: Helvetica; font-size: 12px; font-style: normal; font-variant: normal; font-weight: normal; letter-spacing: normal; line-height: normal; text-align: auto; -khtml-text-decorations-in-effect: none; text-indent: 0px; -apple-text-size-adjust: auto; text-transform: none; orphans: 2; white-space: normal; widows: 2; word-spacing: 0px; "><SPAN class="Apple-style-span" style="border-collapse: separate; border-spacing: 0px 0px; color: rgb(0, 0, 0); font-family: Helvetica; font-size: 12px; font-style: normal; font-variant: normal; font-weight: normal; letter-spacing: normal; line-height: normal; text-align: auto; -khtml-text-decorations-in-effect: none; text-indent: 0px; -apple-text-size-adjust: auto; text-transform: none; orphans: 2; white-space: normal; widows: 2; word-spacing: 0px; "><SPAN class="Apple-style-span" style="border-collapse: separate; border-spacing: 0px 0px; color: rgb(0, 0, 0); font-family: Helvetica; font-size: 12px; font-style: normal; font-variant: normal; font-weight: normal; letter-spacing: normal; line-height: normal; text-align: auto; -khtml-text-decorations-in-effect: none; text-indent: 0px; -apple-text-size-adjust: auto; text-transform: none; orphans: 2; white-space: normal; widows: 2; word-spacing: 0px; "><DIV style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; "><FONT class="Apple-style-span" color="#B22200" face="Monaco" size="3"><SPAN class="Apple-style-span" style="font-size: 13px;"><BR class="khtml-block-placeholder"></SPAN></FONT></DIV><DIV style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; ">Then stash an array with your CSV data in it, and use a template like so:</DIV><DIV style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; "><BR class="khtml-block-placeholder"></DIV><DIV style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; "><FONT class="Apple-style-span" face="Monaco" size="3"><SPAN class="Apple-style-span" style="font-size: 13px;">[% FOREACH row = csv -%]</SPAN></FONT></DIV><DIV style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; "><FONT class="Apple-style-span" color="#008000" face="Monaco" size="3"><SPAN class="Apple-style-span" style="font-size: 13px;">"[% row.0 -%]"</SPAN></FONT><FONT class="Apple-style-span" face="Monaco" size="3"><SPAN class="Apple-style-span" style="font-size: 13px;">,</SPAN></FONT><FONT class="Apple-style-span" color="#008000" face="Monaco" size="3"><SPAN class="Apple-style-span" style="font-size: 13px;">"[% row.1 -%]"</SPAN></FONT><FONT class="Apple-style-span" face="Monaco" size="3"><SPAN class="Apple-style-span" style="font-size: 13px;">,</SPAN></FONT><FONT class="Apple-style-span" color="#008000" face="Monaco" size="3"><SPAN class="Apple-style-span" style="font-size: 13px;">"[% row.2 -%]"</SPAN></FONT><FONT class="Apple-style-span" face="Monaco" size="3"><SPAN class="Apple-style-span" style="font-size: 13px;">,</SPAN></FONT><FONT class="Apple-style-span" color="#008000" face="Monaco" size="3"><SPAN class="Apple-style-span" style="font-size: 13px;">"[% row.3 -%]"<FONT class="Apple-style-span" color="#000000">...</FONT></SPAN></FONT></DIV><DIV style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; "><FONT class="Apple-style-span" face="Monaco" size="3"><SPAN class="Apple-style-span" style="font-size: 13px;">[% END -%]</SPAN></FONT></DIV><DIV style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; "><BR class="khtml-block-placeholder"></DIV><DIV style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; ">This works for me.  It took about 2 minutes, and my application now spits CSV. which is default opened in Excel.  Very simple 'Excel export.'</DIV><DIV style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; "><BR class="khtml-block-placeholder"></DIV><DIV style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; ">Russell Jurney</DIV><DIV style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; ">CEO   Lucision, Inc.</DIV><DIV style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; "><A href="mailto:rjurney@lucision.com">rjurney@lucision.com</A></DIV><DIV style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; "><BR class="khtml-block-placeholder"></DIV><DIV style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; "><BR class="khtml-block-placeholder"></DIV><BR class="Apple-interchange-newline"></SPAN></SPAN></SPAN> </DIV><BR></DIV></BODY></HTML>