Thursday, November 3, 2011

[Rails] Re: Store XML format data into database

Hi,

Thanks for the reply.. When I puts tag.children[9] like this:

doc.xpath('//item').each do |tag|
puts tag.children[9]
@req = Hash.new
@req = tag.children[9]

detail.create(
:my_field => tag.children[9]
)
end


I am getting the whole XML Tag. But this tag is not saving into the
database. It is saving like '--0 \n'. Is there any problem with my model
or Datatype into the database??

Thanks

--
Posted via http://www.ruby-forum.com/.

--
You received this message because you are subscribed to the Google Groups "Ruby on Rails: Talk" group.
To post to this group, send email to rubyonrails-talk@googlegroups.com.
To unsubscribe from this group, send email to rubyonrails-talk+unsubscribe@googlegroups.com.
For more options, visit this group at http://groups.google.com/group/rubyonrails-talk?hl=en.

0 Comments:

Post a Comment

Subscribe to Post Comments [Atom]

<< Home


Real Estate