search for: maneneko

Displaying 6 results from an estimated 6 matches for "maneneko".

2006 Jun 15
3
Can I call MySql statements directly??
Hi All. I have a mysql statement that I would really really like to call from my Ruby program which goes like this: SELECT a, b, DAYOFWEEK(date_time) as DOW, HOUR(date_time) at hr, AVG(x/y) FROM records; This is possible by creating a 3-dimentional array of a, b, date_time containing x/y, and then finding averages and putting it into a 4-dimensional array of a, b, dow,
2006 Jun 07
5
File is nil
I don''t understand why my program does not get the file that I try to upload. It returns the following error when I try to upload a small file: NoMethodError in LogfileController#create You have a nil object when you didn''t expect it! The error occured while evaluating nil.original_filename #{RAILS_ROOT}/app/models/logfile.rb:9:in `file=''
2006 Jun 28
2
Connecting to a Remote MySQL Server
Hi All. I have one newbie question- How do I connect to a remote MySQL server using Ruby on Rails? Is it something simple like changing a few lines in database.yml?? Thanks in advance. Lisa -- Posted via http://www.ruby-forum.com/.
2006 Jun 12
0
Curious about new (ActiveRecord::Base)
Because the documentation isn''t clear (at least to me)... I have a Logfile model that has corresponding fields in MySql. The main ones are id, fileName, and content type. However, I can pass a File object to a new Logfile and have handlers that I created in the Logfile class extract the data. However, the documentation states "...you can?t have attributes that aren?t part of
2006 Jun 13
2
One model handling two different file types
Hi. I''ve gotten stuck again, this time at having one model handling 2 different file types. My model, Logfile has fields id and filename. It also has a file= method to handle an uploaded test file. What I want is to be able to upload either a text file or zipfile. The zipfile contains text files, and I''d like to save each text file within this zipfile as a Logfile. Is
2006 Jun 23
2
Generate Models & Controllers from Ruby program
Hi All. I would like to create a model, database, and controller (if possible) from a webapp. Each model and controller will each have 4 methods, and the database will always have the same number of fields. I will probably create the database through create_table or a direct SQL command. My question is this - is there a method that I can call to create the model and controllers? Would it