Rails & Postgres sandbox

Previous Topic Next Topic
 
classic Classic list List threaded Threaded
4 messages Options
Reply | Threaded
Open this post in threaded view
|

Rails & Postgres sandbox

Ralph Shnelvar
Rails & Postgres sandbox Ruby,

I have a collection of Postgres tables I want my users to be able to access (share)but not modify on my Rails website .  I want each of them to be able to extract data from the tables using whatever SQL they wish and for each user not to be able to interact with other users' extracted data.

I have Devise working to give access to each separate user but now I need/want suggestions as to how to link a Devise authorized user with a correspondingly named Postgres user.

Suggestions would be appreciated.

Ralph Shnelvar

--
You received this message because you are subscribed to the Google Groups "Ruby on Rails: Talk" group.
To unsubscribe from this group and stop receiving emails from it, send an email to [hidden email].
To post to this group, send email to [hidden email].
To view this discussion on the web visit https://groups.google.com/d/msgid/rubyonrails-talk/1888584045.20180414132831%40dos32.com.
For more options, visit https://groups.google.com/d/optout.
Reply | Threaded
Open this post in threaded view
|

Re: Rails & Postgres sandbox

koulikoff
Look at https://github.com/jeremyevans/sequel

On Saturday, April 14, 2018 at 9:29:03 PM UTC+2, Ralph Shnelvar wrote:
Ruby,

I have a collection of Postgres tables I want my users to be able to access (share)but not modify on my Rails website .  I want each of them to be able to extract data from the tables using whatever SQL they wish and for each user not to be able to interact with other users' extracted data.

I have Devise working to give access to each separate user but now I need/want suggestions as to how to link a Devise authorized user with a correspondingly named Postgres user.

Suggestions would be appreciated.

Ralph Shnelvar

--
You received this message because you are subscribed to the Google Groups "Ruby on Rails: Talk" group.
To unsubscribe from this group and stop receiving emails from it, send an email to [hidden email].
To post to this group, send email to [hidden email].
To view this discussion on the web visit https://groups.google.com/d/msgid/rubyonrails-talk/b596ab58-17af-485f-81ad-9ae73a9ebeeb%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.
Reply | Threaded
Open this post in threaded view
|

Re: Rails & Postgres sandbox

Hassan Schroeder-2
In reply to this post by Ralph Shnelvar
On Sat, Apr 14, 2018 at 12:28 PM, Ralph Shnelvar <[hidden email]> wrote:

> I have a collection of Postgres tables I want my users to be able to access
> (share)but not modify on my Rails website .  I want each of them to be able
> to extract data from the tables using whatever SQL they wish and for each
> user not to be able to interact with other users' extracted data.

I think the above requirement is somewhat orthogonal to the one
below, but...

> I have Devise working to give access to each separate user but now I
> need/want suggestions as to how to link a Devise authorized user with a
> correspondingly named Postgres user.

  ActiveRecord::ConnectionHandling.establish_connection

--
Hassan Schroeder ------------------------ [hidden email]
twitter: @hassan
Consulting Availability : Silicon Valley or remote

--
You received this message because you are subscribed to the Google Groups "Ruby on Rails: Talk" group.
To unsubscribe from this group and stop receiving emails from it, send an email to [hidden email].
To post to this group, send email to [hidden email].
To view this discussion on the web visit https://groups.google.com/d/msgid/rubyonrails-talk/CACmC4yDshOitT_yWNPoYR_M-5eJJt9jve1B4Ya0X2ZGVx3AqRA%40mail.gmail.com.
For more options, visit https://groups.google.com/d/optout.
Reply | Threaded
Open this post in threaded view
|

Re: Rails & Postgres sandbox

Ralph Shnelvar
Re: [Rails] Rails & Postgres sandbox Hassan,

Why is it orthogonal?

And, yes, I understand what orthogonal means in this context.

And thank you for pointing out ActiveRecord::ConnectionHandling.establish_connection.

Ralph

Saturday, April 14, 2018, 8:15:13 PM, you wrote:

HS> On Sat, Apr 14, 2018 at 12:28 PM, Ralph Shnelvar <
[hidden email]> wrote:

>> I have a collection of Postgres tables I want my users to be able to access
>> (share)but not modify on my Rails website .  I want each of them to be able
>> to extract data from the tables using whatever SQL they wish and for each
>> user not to be able to interact with other users' extracted data.

HS> I think the above requirement is somewhat orthogonal to the one
HS> below, but...

>> I have Devise working to give access to each separate user but now I
>> need/want suggestions as to how to link a Devise authorized user with a
>> correspondingly named Postgres user.

HS>   ActiveRecord::ConnectionHandling.establish_connection

HS> --
HS> Hassan Schroeder ------------------------
[hidden email]
HS> twitter: @hassan
HS> Consulting Availability : Silicon Valley or remote




Ralph

--
You received this message because you are subscribed to the Google Groups "Ruby on Rails: Talk" group.
To unsubscribe from this group and stop receiving emails from it, send an email to [hidden email].
To post to this group, send email to [hidden email].
To view this discussion on the web visit https://groups.google.com/d/msgid/rubyonrails-talk/18868870.20180414203845%40dos32.com.
For more options, visit https://groups.google.com/d/optout.