Displaying 3 results from an estimated 3 matches for "satement".
Did you mean:
statement
2006 May 01
1
Is there a way to do unbuffered render :update ?
...n action which does some stuff and then does a render :update to
replace a container with a partial, the delay due to processing is more
than I''d like for expecting a user to wait without hitting the button
again and again. Is there a way to force the render''s display when the
satement is executed rather than at the end of the action?
Thanks,
Andy
--
Posted via http://www.ruby-forum.com/.
2006 Nov 02
6
Multiple items in the where clause while updating...
...want to achive the following.
Update friends set ftype=''F'' where id=1 and fid=3
Im using the following code...
===========
f = Friend.find(:first, :conditions => "id = 1 and fid = 3")
f.ftype=''F''
f.save
===========
This errors out because the sql satement that gets generated will be
UPDATE friends SET `sid` = 31, `ftype` = ''F'', `fid` = 3 WHERE id = 1
As you can see the where clause always takes just the id attribute and
ignores others which will try to update muliple rows.
Is there a way to handle this situation?
Thanks
Prasa...
2011 Jul 27
20
Rails, jquery and Ajax
How do I make an ajax call and then update a div with a partial? I''ve
tried this but it''s not working. Comment is created but the partial is
not loaded.
//view
<a href="#" id="testlink">Testlink</a>
<div id="commentlist">
</div>
//controller
def new
@comment = Comment.new
@comment.save