> Also, the same question for eRuby - it seems pretty straightforward, but
> I can't find any English documentation, so more examples would be
> great.

Table.rhtml writes a table of alternate white and gray rows.
This example lists current directory files as follows. 
  list = Dir.glob('*').sort
Replace it with your query code, in your application.

 % ruby erb.rb table.rhtml > table.html		# erb
 % eruby table.rhtml > table.html		# eruby

-- table.rhtml ---
<HTML>
<HEAD>
<TITLE>401 Unauthorized</TITLE>
</HEAD>
<BODY>
<% 
  def h(s)
    s.to_s.gsub(/&/, "&amp;").gsub(/\"/, "&quot;").gsub(/>/, "&gt;").gsub(/</, "&lt;")
  end

  class BGAttr
    def initialize(colors = ["#eeeeee", "#ffffff"])
      @colors = colors
      @cur = -1
    end

    def to_s
      @cur = (@cur+1) % @colors.size
      "bgcolor=\"#{@colors[@cur]}\""
    end
  end

  list = Dir.glob('*').sort
%>
<H2>Dir.glob('*')</H2>
<TABLE bgcolor="white" rules="none" frame="void">
<% 
  bgattr = BGAttr.new
  list.each do |v|
%>
<TR <%= bgattr %>><TD><%=h v %>
<%
  end
%>
</TABLE>
<HR>
<ADDRESS>Masatoshi  SEKI<ADDRESS>
</BODY>