On Monday, March 14, 2016 at 8:45:55 PM UTC-7, The Bang Nguyen wrote:
>
> Hi all,
>
> I would like to rename a view which is previously created.
>
> Is there any elegant way to accomplish it instead of delete old view and 
> create exactly the same one with a new name?
>
> I looked up sequel repo but there is no rename_view function.
>
> Thank you in advance
> Bang
>

Sequel doesn't have an abstraction for renaming views, so you'll have to 
use raw SQL.  If you are using PostgreSQL:

  DB.run "ALTER VIEW old_view RENAME TO new_view"

Thanks,
Jeremy

-- 
You received this message because you are subscribed to the Google Groups 
"sequel-talk" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to [email protected].
To post to this group, send email to [email protected].
Visit this group at https://groups.google.com/group/sequel-talk.
For more options, visit https://groups.google.com/d/optout.

Reply via email to