Account Options

  1. Sign in
The old Google Groups will be going away soon, but your browser is incompatible with the new version.
Google Groups Home
« Groups Home
Message from discussion Support for views on activerecord
The group you are posting to is a Usenet group. Messages posted to this group will make your email address visible to anyone on the Internet.
Your reply message has not been sent.
Your post was successful
 
From:
To:
Cc:
Followup To:
Add Cc | Add Followup-to | Edit Subject
Subject:
Validation:
For verification purposes please type the characters you see in the picture below or the numbers you hear by clicking the accessibility icon. Listen and type the numbers you hear
 
Michael Koziarski  
View profile  
 More options Jul 11 2012, 6:02 pm
From: Michael Koziarski <mich...@koziarski.com>
Date: Thu, 12 Jul 2012 10:02:21 +1200
Local: Wed, Jul 11 2012 6:02 pm
Subject: Re: [Rails-core] Support for views on activerecord

On Thursday, 12 July 2012 at 7:52 AM, Mike Moore wrote:
> Agreed. Using AR to access views is very useful. I would love it if schema.rb was view aware though.

Supporting views in schema.rb and migrations is almost impossible to do though, we'd have to dump the exact SQL that's in use or support arbitrary SQL round tripping.  If we were going to dump the sql straight from the db that we'd have a poor-man's version of the :sql schema_format we have already.  If we build a round-trip capable SQL parser we're clinically insane and should be institutionalised.

I don't really see what more we need to support, can't you just use :sql for the schema_format and you get all the functionality you want, and more?

--
Cheers,

Koz


 
You must Sign in before you can post messages.
To post a message you must first join this group.
Please update your nickname on the subscription settings page before posting.
You do not have the permission required to post.