Sunday, February 19, 2012

dbo owner

Hi Everyone,
I'm still with this problem and now I have little bit of time to find the
solution.
After any user import data to a table I want to have that table as dbo
owner.
I dont want to give my users full administrator permisssions.
I try to setup in each database access as db_owner, db_accesmin,
db_dlladmin but no luck
I know I can change the owner later with sp_changeobjectowner but sometimes
I run crazy with more than three users at the same time.
How can I fix this issue?
Tks
JFBCould you be more specific?
Do you use qualified object names? (two-part names: owner.object_name)
ML|||Yeah, a sample table, user, and a query you are trying to run in a script
would really make this easier.
Otherwise the best answer (as usual) is 42. Sadly we still don't know the
question to that answer either :)
----
Louis Davidson - http://spaces.msn.com/members/drsql/
SQL Server MVP
"ML" <ML@.discussions.microsoft.com> wrote in message
news:77548CF2-DE05-4C93-A509-4BDF04EF49C8@.microsoft.com...
> Could you be more specific?
> Do you use qualified object names? (two-part names: owner.object_name)
>
> ML|||Hi
If the structure of the data file is fixed, then you can create a DTS
package and schedule it as a job to import the data. This will mean that the
user does not have to "manually" import the data. You table structure (and
owner) can then be fixed. If you wish to manipulate the data it may be
worthwhile loading the data into a set of holding tables, where you can
subsequently work with that data and load it into your destination tables.
For more information on DTS look up DTS in books online and at l]
For example if you wish to process several files you can loop through all
the files in a given directory using the example code at
[url]http://www.sqldts.com/default.aspx?246" target="_blank">www.sqldts.com.[/ur
l]...efault.aspx?246
John
"JFB" wrote:

> Hi Everyone,
> I'm still with this problem and now I have little bit of time to find the
> solution.
> After any user import data to a table I want to have that table as dbo
> owner.
> I dont want to give my users full administrator permisssions.
> I try to setup in each database access as db_owner, db_accesmin,
> db_dlladmin but no luck
> I know I can change the owner later with sp_changeobjectowner but sometime
s
> I run crazy with more than three users at the same time.
> How can I fix this issue?
> Tks
> JFB
>
>|||Tks for you answer, I have DTS packages in my enviroment.
What I need is to fix this dbo when the user import data from a text file
manually
Tks
JFB
"John Bell" <jbellnewsposts@.hotmail.com> wrote in message
news:1364EA0B-E2AA-416F-B34F-275CA4B57CC7@.microsoft.com...
> Hi
> If the structure of the data file is fixed, then you can create a DTS
> package and schedule it as a job to import the data. This will mean that
> the
> user does not have to "manually" import the data. You table structure
> (and
> owner) can then be fixed. If you wish to manipulate the data it may be
> worthwhile loading the data into a set of holding tables, where you can
> subsequently work with that data and load it into your destination tables.
> For more information on DTS look up DTS in books online and at
> www.sqldts.com.
> For example if you wish to process several files you can loop through all
> the files in a given directory using the example code at
> http://www.sqldts.com/default.aspx?246
>
> John
> "JFB" wrote:
>|||Hi
It is not clear how/why you allow users to import data manually.
John
"JFB" wrote:

> Tks for you answer, I have DTS packages in my enviroment.
> What I need is to fix this dbo when the user import data from a text file
> manually
> Tks
> JFB
> "John Bell" <jbellnewsposts@.hotmail.com> wrote in message
> news:1364EA0B-E2AA-416F-B34F-275CA4B57CC7@.microsoft.com...
>
>|||Well each applicator developer has sql enterprise manager to conect to our
sql server with permissions on the database that they are working on it.
Base on bad experiences I don't want they to have full admin permissions.
But they need to import data manually for different purpose.
(analize data, test sp's, test vb app, ...)
Tks
JFB
"John Bell" <jbellnewsposts@.hotmail.com> wrote in message
news:CD8D19DB-CF63-4410-965D-11D31A092965@.microsoft.com...
> Hi
> It is not clear how/why you allow users to import data manually.
> John
>
> "JFB" wrote:
>|||What I need is to fix this dbo when the users(developers) import data from a
text file manually
Tks
JFB
"Louis Davidson" <dr_dontspamme_sql@.hotmail.com> wrote in message
news:ebjR8RVnFHA.1948@.TK2MSFTNGP12.phx.gbl...
> Yeah, a sample table, user, and a query you are trying to run in a script
> would really make this easier.
> Otherwise the best answer (as usual) is 42. Sadly we still don't know the
> question to that answer either :)
> --
> ----
--
> Louis Davidson - http://spaces.msn.com/members/drsql/
> SQL Server MVP
>
> "ML" <ML@.discussions.microsoft.com> wrote in message
> news:77548CF2-DE05-4C93-A509-4BDF04EF49C8@.microsoft.com...
>|||Hi
I have never come across the situation where a programmer has needed to
create tables for testing. If they have test data it should already be
in the destination table format; if this is from a previous version of
the database, then the data is re-exported after an upgrade; if this a
formal import process then the table definitions/process should be
formalised and the dbo owner in place.
If they do need to carry out an activity that may impact other users
then you could give them their own database and make them dbo.
John

No comments:

Post a Comment