Good point about the controllers, but views don't have "_view" appended onto them. The name of the view is the same as the corresponding action/method in the controller.
I'm not sure why the controllers have "_controller" appended onto their filenames. Models don't have "_model" appended. Hm.
I'm not exactly sure why you think Rails directory structure is weird. I think it's pretty good.
For those who don't know... a typical Rails structure is:/app/app/models/app/model/a_model.rb/app/controllers//app/controllers/a_controller.rb/app/views/app/views/a_view//app/views/a_view/a_particular_view.rb/public/public/stylesheets/public/images
You can create automatic mappings between objects and a relational database in Java with a total of two lines of code? That's news to me. But if you can't, then that would mean that you can't "just as easily" do the same in Java, right?
Customizing views is dead simple in Rails. I don't see how it's diffcult.
Granted, the example that the guy gave was REALLY basic. There's lots of others on the Rails site.
Yes, for most sites, Rails is fine. So, how is that a weakness? By not committing the zero'th and first great blunder, would the ORM layer be as simple and flexible to use?
Writing SQL statements smack dab in the middle of one's code is generally a bad thing. You want to get the code that talks to the database separated out from the rest of the application.
If you find that the application is making too many SQL queries and is bogging down performance, then ActiveRecord (the database part of Rails) lets you create custom SQL queries.
Considering that I've written less than 500 lines of code (not counting html or css), I'd guess pretty much anyone could get up to speed with it in less than a day, even with Rails experience.
Hell, I probably only spent two days studying Rails prior to creating the site.
I've almost finished developing a real estate site using it. First time using Rails.
In PHP or other related language, probably would've taken me about 80 hours or so to develop the site. In Rails, I've spent maybe 15 hours or so total on it. And I'm charging $8k for the site. Admittedly, that doesn't include time working on the graphics or design of the site, just the backend, search, etc.
So if you look at it from one perspective, I went from making $100 an hour to $533 an hour using Rails!
Rails provides CRUD (Create, Retrieve, Update, Delete) helpers if you want to use them. They're aren't necessary by any means, they just provide an easy, extremely quick way (one line of code) to create forms that will let you operate on a database table.
I'm not sure if the code that it generates is standards-compliant, but I'd imagine that it is.
Perhaps the documentation for ActiveRecord will help answer your question?
http://ar.rubyonrails.org/
You can automatically retrieve data from the database in the form of an object, do manipulations or calculations, display it, modify it, then do a save() method on the object and it'll go right back into the database.
What the hell. Put Steam into Offline mode. You can play Half-Life 2 in single player mode then.
I've played HL2 many times without a working internet connection.
You can play Half-Life 2 without connecting to the "central servers". Put Steam into Offline mode.
Different tools for different needs. Lots of production sites use Rails succesfully.
You can determine access to the database through the ActiveRecord objects. Probably not in stored procedures though.
If you do need stored procedures, you don't need to use ActiveRecord (which is the ORM part of Rails).
Good point about the controllers, but views don't have "_view" appended onto them. The name of the view is the same as the corresponding action/method in the controller.
I'm not sure why the controllers have "_controller" appended onto their filenames. Models don't have "_model" appended. Hm.
If you don't like how it pluralizes names, you are free to change it. Takes a line of code to specify the name you want to use.
In Rails, the model is responsible for getting/putting data from/to the database and creating objects used by the controller.
The controller is responsible for manipulating the objects from the model.
The view is used to display controller data and to send user data back to the controller.
It works very well.
I'm not exactly sure why you think Rails directory structure is weird. I think it's pretty good.
/app /app/models /app/model/a_model.rb /app/controllers/ /app/controllers/a_controller.rb /app/views /app/views/a_view/ /app/views/a_view/a_particular_view.rb /public /public/stylesheets /public/images
For those who don't know... a typical Rails structure is:
You can create automatic mappings between objects and a relational database in Java with a total of two lines of code? That's news to me. But if you can't, then that would mean that you can't "just as easily" do the same in Java, right?
Customizing views is dead simple in Rails. I don't see how it's diffcult.
Granted, the example that the guy gave was REALLY basic. There's lots of others on the Rails site.
Yes, for most sites, Rails is fine. So, how is that a weakness? By not committing the zero'th and first great blunder, would the ORM layer be as simple and flexible to use?
Writing SQL statements smack dab in the middle of one's code is generally a bad thing. You want to get the code that talks to the database separated out from the rest of the application.
Rails is not just a framework for accessing a database.
There's also ActionPack (http://ap.rubyonrails.org/), which is the View and Controller of the MVC pattern (ActiveRecord being the Model part).
The integration between the two frameworks is what makes Rails so impressive.
If you find that the application is making too many SQL queries and is bogging down performance, then ActiveRecord (the database part of Rails) lets you create custom SQL queries.
So what's the problem?
Considering that I've written less than 500 lines of code (not counting html or css), I'd guess pretty much anyone could get up to speed with it in less than a day, even with Rails experience.
Hell, I probably only spent two days studying Rails prior to creating the site.
The ActiveRecord classes are simply a way to get data from the database and transfer it to an object.
You can do whatever business logic you want after you get the objects.
Visual programming? What the hell is visual about it?
Oracle is coming very soon!
What do you mean by "queries essentially on the pages"?
I've almost finished developing a real estate site using it. First time using Rails.
In PHP or other related language, probably would've taken me about 80 hours or so to develop the site. In Rails, I've spent maybe 15 hours or so total on it. And I'm charging $8k for the site. Admittedly, that doesn't include time working on the graphics or design of the site, just the backend, search, etc.
So if you look at it from one perspective, I went from making $100 an hour to $533 an hour using Rails!
The linked websites are all loading fine for me...
Hi,
Rails provides CRUD (Create, Retrieve, Update, Delete) helpers if you want to use them. They're aren't necessary by any means, they just provide an easy, extremely quick way (one line of code) to create forms that will let you operate on a database table.
I'm not sure if the code that it generates is standards-compliant, but I'd imagine that it is.
Perhaps the documentation for ActiveRecord will help answer your question?
http://ar.rubyonrails.org/
You can automatically retrieve data from the database in the form of an object, do manipulations or calculations, display it, modify it, then do a save() method on the object and it'll go right back into the database.
Insightful?
Lets see you do the same thing cleanly with a MVC pattern in any other language/framework in as little effort as you can with Rails.
And, if you get hosting at TextDrive, they'll give half of your money to supporting RubyonRails development!
Having a human readable format makes it a lot easier to a) parse the data and b) validate the data.
If performance is going to be an issue, then the design specs should indicate what performance is needed.
Otherwise, you could spend 5 times as long making the code go 25% faster for no good reason at all.
Repeat after me: Software is nothing like Construction.