Regarding edit functionality

Hi all,
Could any one help me how to edit all the timesheets at a time.
If i slect the month as december, i should get all teh timesheets from
the data base, I’m getting this one correctly, after getting this, i
should be able to edit these automatically all the timesheets.
See this is my controller::
def logic1
userId=@session[‘user’][‘id’]
user=User.find(userId)
#@timesheets = Timesheet.find(:all,:conditions=>[‘month(created_at)
= ?’, params[:timesheet][’:created_at(2i)’].to_i])
@timesheets = Timesheet.find_by_sql(“select * from timesheets where
user_id=’#{userId}’ and month(created_at)=
‘#{params[:timesheet][‘created_at(2i)’].to_i}’ and year(created_at)=
‘#{params[:timesheet][‘created_at(1i)’].to_i}’”)
@timesheets=Timesheet.find(@timesheets)
end

my rhtml file::
<%= link_to “Home”, :action=>“index”%>
Total hours worked in
<%=params[:timesheet][‘created_at(2i)’]%>th month of
Year <%=params[:timesheet][‘created_at(1i)’]%> =
<%=@total%> hours
<%= start_form_tag :action => ‘update’,:id=>@timesheets %>

<%@projects=Project.find_all%> <%@projects=Project.find_all%>
Created At Project Hours Worked Remarks
<%= date_select 'timesheet', 'created_at' %><%= collection_select("timesheet", "project" , @projects, "name", "name") %> <%= text_field 'timesheet', 'hours_worked', "size" => 31 %> <%= text_area 'timesheet', 'remarks' ,"cols" => 22, "rows" => 5 %>
<%= date_select 'timesheet', 'created_at' %><%= collection_select("timesheet", "project" , @projects, "name", "name") %> <%= text_field 'timesheet', 'hours_worked', "size" => 31 %> <%= text_area 'timesheet', 'remarks' ,"cols" => 22, "rows" => 5 %>
<%= submit_tag "Create" %> <%= end_form_tag %>

Thanks in Advance,
Harish

Hi all,
I could explain this in very clear,
if i search the list according to date i’ll get in the following way…

Created At Project Hours Worked Remarks
2006-09-18 Ruby 3 working good
2006-09-18 Ruby 5 not working good

and here it self i should be edited in the following way.

Created At Project Hours Worked Remarks
2006-09-18 Rails 3 working good
2006-09-18 Ruby 8 not working good

see project Ruby is changed to Rails and Hours Worked is changed to 8.

like i need to get the list and i should be able to edit there it self.
Please give any suggestions.

Thanks in advance,
Regards,
Harish