Showing posts with label ability. Show all posts
Showing posts with label ability. Show all posts

Tuesday, March 27, 2012

ability to use variables in package configurations and set their values at runtime

Hi,

My scenario:

I am using a FTP Connection Manager and the configuration setting for it is being set in the package configuration xml file. So the xml file contains the Ftpserver, FTp server username and password. The package is picking up the values from the xml file and is executing successfully. I have to do this because I was not able to provide an expression to the Connection Manager Server Password property.

Now, I want to pick up the ftp details from a database table and set it in the xml file during runtime. Is this possible? OR something like using the

<Configuration ConfiguredType="Property" Path="\Package.Connections[FTP Connection Manager].Properties[ServerPassword]" ValueType="Variable"><ConfiguredValue>@.[user::FtpPassword]</ConfiguredValue></Configuration>

Kindly look at the items in bold. Is this possible? Then I can set the value of the variable in the package before the FTP connection manager task is executed.

Thanks for all the help.

$wapnil

You could use a configuration storage as DB.

Or you can use Script task to query the DB and set the FTP connection properties or Variable values at runtime

Or even Execute SQL task to get the variable values from DB|||

Thanks

Reply to the options that you have provided

1) We want to use XML for the configuration. Just something which we want to follow if we could.

2) We are trying to minimuize the script tasks in the package by bringing the configuration details outside of the package and storing it in XML.

3) same as 1

Lets take a FTP connection Manager for example. The details of the FTP server are present in the database and I have also created variables for that but atleast I am not able to set the FTP Server password using a variable so I resorted to using the xml file and putting in the password there.

Now if I want to connect to multiple FTP server using the same package and the connection details are there in the database then I can pull out the connection details using an Execute SQL task but then how to update the xml files with values......knowing that the FTP server password can be only be set dynamically using the xml file.

Correct me if I am wrong. is storing the variable in the DB the only solution.

Thanks,

$wapnil

|||

spattewar wrote:

Now if I want to connect to multiple FTP server using the same package and the connection details

Are you trying to connect multiple FTP servers at the same time or are you trying to run the package in different environments?

For example if I would need to pull info from 3 different FTP servers - I would create 3 different configuration files:
1 for Development
1 for staging
and 1 for Production site|||

I am trying to connect to multiple FTP servers. But it can be at the same time or in sequence. But I am planning to use a single package for this task.

Thanks for your response.

$wapnil

|||Why don't you use Parent Package Configurations instead? A simple 2-package setup could work where:
Your mother package cycles through a list of FTP server configurations or whatever is needed.|||

That looks like a good idea.

But there is one concern. Even though I pass the configuration as a parent package variable to the child package, will I be able to set the FTP ServerPassword property of the FTP connection manager using a variable. I doubt I can do that, then it boils down to the same thing picking up the package configuration from the xml file or a database, here we would prefer xml file.

Maybe we can do this by.

1) Running the master package which will have a script task to update a xml configuration file.

2) Pass that xml file as a configuration parameter to the child package and execute the child package.

Thanks for your response.

$wapnil

|||I don't have any reason to believe that you can't pass the password or even the whole connectionstring as a variable.

However do note that if your variable values refuse to change (although I don't see any reason why they won't) you might have to tweak the ProtectionLevel of the package to DontSaveSensitive or some other value that allows you to modify your connectionstring variable.

HTHsql

Ability to update multiple tables simultaneously via stored proc

Anyone have any ideas on how to use a stored procedure to update multiple tables simultaneously? I am updating a parent record and zero or more child records. I would like to make one stored procedure call if possible to do so. Any ideas on doing this would be appreciated. Thanks!

EverettYou can update more than one table within a stored procedure, just make sure to use BEGIN TRAN/COMMIT TRAN/ROLLBACK TRAN

Example:

CREATE PROCEDURE sp_ModifyMasterDetail
(
.
.
.
@.msg varchar(255) output
)
AS
SET NOCOUNT ON

DECLARE @.error int
, @.tfTran tinyint

--
-- Start Transaction
--
IF (@.@.TRANCOUNT = 0) BEGIN
SELECT @.tfTran = 1
BEGIN TRAN
END
ELSE
SELECT @.tfTran = 0

UPDATE tblMaster
.
WHERE ID = @.ID

SELECT @.error = @.@.error

IF (@.error <> 0)
GOTO Error_Exit

UPDATE tblDetail
.
WHERE ID = @.ID
AND SubID = @.SubID

SELECT @.error = @.@.error

IF (@.error <> 0)
GOTO Error_Exit

--
-- Check to see if an error occured during processing. If so then
-- ROLLBACK else COMMIT transactions
--
Error_Exit:

IF (@.error <> 0) BEGIN
IF (@.tfTran = 1)
ROLLBACK TRAN

SELECT @.msg = 'ERROR: Transaction failed with error ' + CONVERT(varchar(20),@.error),
END
ELSE BEGIN
IF (@.tfTran = 1)
COMMIT TRAN

SELECT @.msg = 'Transaction successful'
END

RETURN @.error
GO|||begin tran
update parent set ...
if @.@.error <> 0
begin
raiserror('failed',16,-1)
rollback tran
return
end
update child set ...
if @.@.error <> 0
begin
raiserror('failed',16,-1)
rollback tran
return
end
commit tran

Or you could put a trigger on the parent (or child) table or on a view of the combination - depends on the updates you want to do.|||Thanks guys! Either one of these will do the trick, except that I'm not sure how to get the data into the stored procedure! I guess I could munge it into varchar(8000), but I'm not sure that it would always be long enough. Any way of passing either an array or a recordset/cursor into a stored procedure?

Everett|||You can create a temp table on the spid, populate it then access it in the SP.

Call the SP repeated times with the values and the SP can populate a table keyed on spid.

Call the sp with comma delimitted strings with the values.

Have lots of parameters - up to the max you think you will need.

Ability to schedule job across Domains

Situation: I have to copy data from a host SQL Server and place it onto my
SQL Server. We have an intermediary box with Console installed with both SQL
Servers registered. I have setup a DTS that performs the transfer.
Problem: I can run the DTS manually but when I schedule the job to run
automatically I get an error message that the job cannot be run because the
user is a nonSysAdmin.
That is because the context of the package is different when you run it as a
job, instead of you running it. See if this helps:
http://support.microsoft.com/default...269074&sd=tech
HTH,
Vyas, MVP (SQL Server)
SQL Server Articles and Code Samples @. http://vyaskn.tripod.com/
"bssolutions" <bssolutions@.discussions.microsoft.com> wrote in message
news:D1FAB676-20A5-4DE1-A20E-90C5114A10BB@.microsoft.com...
Situation: I have to copy data from a host SQL Server and place it onto my
SQL Server. We have an intermediary box with Console installed with both
SQL
Servers registered. I have setup a DTS that performs the transfer.
Problem: I can run the DTS manually but when I schedule the job to run
automatically I get an error message that the job cannot be run because the
user is a nonSysAdmin.
|||Since the 1st box is accessed thru VPN, we have a 2nd box that acts as the
connecting device with console and is outside our domain, and the 3rd box is
inside our domain with SQL installed. I made the login, for test purposes a
member of sysadmin. This allowed me to schedule the job and it would run as
scheduled but now I get a message that it cannot find the server referenced
(a simply sql statement is my test to the 1st box).
Here is what the job history tells me:
Executed as user: TEST1\SYSTEM. DTSRun: Loading... DTSRun: Executing...
DTSRun OnStart: DTSStep_DTSExecuteSQLTask_1 DTSRun OnError:
DTSStep_DTSExecuteSQLTask_1, Error = -2147467259 (80004005) Error
string: [DBNETLIB][ConnectionOpen (Connect()).]SQL Server does not exist or
access denied. Error source: Microsoft OLE DB Provider for SQL Server
Help file: Help context: 0 Error Detail Records: Error:
-2147467259 (80004005); Provider Error: 17 (11) Error string:
[DBNETLIB][ConnectionOpen (Connect()).]SQL Server does not exist or access
denied. Error source: Microsoft OLE DB Provider for SQL Server
Help file: Help context: 0 DTSRun OnFinish:
DTSStep_DTSExecuteSQLTask_1 DTSRun: Package execution complete. Process
Exit Code 1. The step failed.
Thanks a bunch for you help on this.
"Narayana Vyas Kondreddi" wrote:

> That is because the context of the package is different when you run it as a
> job, instead of you running it. See if this helps:
> http://support.microsoft.com/default...269074&sd=tech
> --
> HTH,
> Vyas, MVP (SQL Server)
> SQL Server Articles and Code Samples @. http://vyaskn.tripod.com/
>
> "bssolutions" <bssolutions@.discussions.microsoft.com> wrote in message
> news:D1FAB676-20A5-4DE1-A20E-90C5114A10BB@.microsoft.com...
> Situation: I have to copy data from a host SQL Server and place it onto my
> SQL Server. We have an intermediary box with Console installed with both
> SQL
> Servers registered. I have setup a DTS that performs the transfer.
> Problem: I can run the DTS manually but when I schedule the job to run
> automatically I get an error message that the job cannot be run because the
> user is a nonSysAdmin.
>
>

Ability to schedule job across Domains

Situation: I have to copy data from a host SQL Server and place it onto my
SQL Server. We have an intermediary box with Console installed with both SQ
L
Servers registered. I have setup a DTS that performs the transfer.
Problem: I can run the DTS manually but when I schedule the job to run
automatically I get an error message that the job cannot be run because the
user is a nonSysAdmin.That is because the context of the package is different when you run it as a
job, instead of you running it. See if this helps:
http://support.microsoft.com/defaul...;269074&sd=tech
--
HTH,
Vyas, MVP (SQL Server)
SQL Server Articles and Code Samples @. http://vyaskn.tripod.com/
"bssolutions" <bssolutions@.discussions.microsoft.com> wrote in message
news:D1FAB676-20A5-4DE1-A20E-90C5114A10BB@.microsoft.com...
Situation: I have to copy data from a host SQL Server and place it onto my
SQL Server. We have an intermediary box with Console installed with both
SQL
Servers registered. I have setup a DTS that performs the transfer.
Problem: I can run the DTS manually but when I schedule the job to run
automatically I get an error message that the job cannot be run because the
user is a nonSysAdmin.|||Since the 1st box is accessed thru VPN, we have a 2nd box that acts as the
connecting device with console and is outside our domain, and the 3rd box is
inside our domain with SQL installed. I made the login, for test purposes a
member of sysadmin. This allowed me to schedule the job and it would run as
scheduled but now I get a message that it cannot find the server referenced
(a simply sql statement is my test to the 1st box).
Here is what the job history tells me:
Executed as user: TEST1\SYSTEM. DTSRun: Loading... DTSRun: Executing...
DTSRun OnStart: DTSStep_DTSExecuteSQLTask_1 DTSRun OnError:
DTSStep_DTSExecuteSQLTask_1, Error = -2147467259 (80004005) Error
string: [DBNETLIB][ConnectionOpen (Connect()).]SQL Server does not
exist or
access denied. Error source: Microsoft OLE DB Provider for SQL Server
Help file: Help context: 0 Error Detail Records: Error:
-2147467259 (80004005); Provider Error: 17 (11) Error string:
[DBNETLIB][ConnectionOpen (Connect()).]SQL Server does not exist or
access
denied. Error source: Microsoft OLE DB Provider for SQL Server
Help file: Help context: 0 DTSRun OnFinish:
DTSStep_DTSExecuteSQLTask_1 DTSRun: Package execution complete. Process
Exit Code 1. The step failed.
Thanks a bunch for you help on this.
"Narayana Vyas Kondreddi" wrote:

> That is because the context of the package is different when you run it as
a
> job, instead of you running it. See if this helps:
> http://support.microsoft.com/defaul...;269074&sd=tech
> --
> HTH,
> Vyas, MVP (SQL Server)
> SQL Server Articles and Code Samples @. http://vyaskn.tripod.com/
>
> "bssolutions" <bssolutions@.discussions.microsoft.com> wrote in message
> news:D1FAB676-20A5-4DE1-A20E-90C5114A10BB@.microsoft.com...
> Situation: I have to copy data from a host SQL Server and place it onto my
> SQL Server. We have an intermediary box with Console installed with both
> SQL
> Servers registered. I have setup a DTS that performs the transfer.
> Problem: I can run the DTS manually but when I schedule the job to run
> automatically I get an error message that the job cannot be run because th
e
> user is a nonSysAdmin.
>
>

Ability to schedule job across Domains

Situation: I have to copy data from a host SQL Server and place it onto my
SQL Server. We have an intermediary box with Console installed with both SQL
Servers registered. I have setup a DTS that performs the transfer.
Problem: I can run the DTS manually but when I schedule the job to run
automatically I get an error message that the job cannot be run because the
user is a nonSysAdmin.That is because the context of the package is different when you run it as a
job, instead of you running it. See if this helps:
http://support.microsoft.com/default.aspx?scid=kb;en-us;269074&sd=tech
--
HTH,
Vyas, MVP (SQL Server)
SQL Server Articles and Code Samples @. http://vyaskn.tripod.com/
"bssolutions" <bssolutions@.discussions.microsoft.com> wrote in message
news:D1FAB676-20A5-4DE1-A20E-90C5114A10BB@.microsoft.com...
Situation: I have to copy data from a host SQL Server and place it onto my
SQL Server. We have an intermediary box with Console installed with both
SQL
Servers registered. I have setup a DTS that performs the transfer.
Problem: I can run the DTS manually but when I schedule the job to run
automatically I get an error message that the job cannot be run because the
user is a nonSysAdmin.|||Since the 1st box is accessed thru VPN, we have a 2nd box that acts as the
connecting device with console and is outside our domain, and the 3rd box is
inside our domain with SQL installed. I made the login, for test purposes a
member of sysadmin. This allowed me to schedule the job and it would run as
scheduled but now I get a message that it cannot find the server referenced
(a simply sql statement is my test to the 1st box).
Here is what the job history tells me:
Executed as user: TEST1\SYSTEM. DTSRun: Loading... DTSRun: Executing...
DTSRun OnStart: DTSStep_DTSExecuteSQLTask_1 DTSRun OnError:
DTSStep_DTSExecuteSQLTask_1, Error = -2147467259 (80004005) Error
string: [DBNETLIB][ConnectionOpen (Connect()).]SQL Server does not exist or
access denied. Error source: Microsoft OLE DB Provider for SQL Server
Help file: Help context: 0 Error Detail Records: Error:
-2147467259 (80004005); Provider Error: 17 (11) Error string:
[DBNETLIB][ConnectionOpen (Connect()).]SQL Server does not exist or access
denied. Error source: Microsoft OLE DB Provider for SQL Server
Help file: Help context: 0 DTSRun OnFinish:
DTSStep_DTSExecuteSQLTask_1 DTSRun: Package execution complete. Process
Exit Code 1. The step failed.
Thanks a bunch for you help on this.
"Narayana Vyas Kondreddi" wrote:
> That is because the context of the package is different when you run it as a
> job, instead of you running it. See if this helps:
> http://support.microsoft.com/default.aspx?scid=kb;en-us;269074&sd=tech
> --
> HTH,
> Vyas, MVP (SQL Server)
> SQL Server Articles and Code Samples @. http://vyaskn.tripod.com/
>
> "bssolutions" <bssolutions@.discussions.microsoft.com> wrote in message
> news:D1FAB676-20A5-4DE1-A20E-90C5114A10BB@.microsoft.com...
> Situation: I have to copy data from a host SQL Server and place it onto my
> SQL Server. We have an intermediary box with Console installed with both
> SQL
> Servers registered. I have setup a DTS that performs the transfer.
> Problem: I can run the DTS manually but when I schedule the job to run
> automatically I get an error message that the job cannot be run because the
> user is a nonSysAdmin.
>
>

Ability to Manually Enter a Parameter in a Queried Parameter

I have a queried parameter getting it's parameters from its own dataset.
Works great. Now they want to have the ability to enter their own if they
know what value they want rather than scrolling through the list.
Any ideas on how to go about this?
ThanksAnybody?
"BillD" wrote:
> I have a queried parameter getting it's parameters from its own dataset.
> Works great. Now they want to have the ability to enter their own if they
> know what value they want rather than scrolling through the list.
> Any ideas on how to go about this?
> Thanks
>|||Chris,
Thank You for taking the time to reply. Looks like I'll be getting into some
ASP as I also like to have a calendar for date parameters...
"Chris Baldwin" wrote:
> > "BillD" wrote:
> >
> >> I have a queried parameter getting it's parameters from its own
> >> dataset. Works great. Now they want to have the ability to enter
> >> their own if they know what value they want rather than scrolling
> >> through the list.
> Hello BillD,
> I'm not sure there's a way to do this when rendering through Report Manager.
> If there is I'd love to hear about it. But, I know you could easily create
> a custom webform that accomplishes this goal.
> For example, you can use JavaScript to determine whether the text box has
> been typed into and adjust the form action that requests the report accordingly.
> Here's a snippet that I used in one of my apps that might help:
> <script>
> function process()
> {
> var actionBase = "http://localhost/reportserver/myreport?rs:Command=Render&ParamVal=";
> var theForm = document.getElementById("myForm");
> var txtBox = document.getElementById("myBox");
> var selectBox = document.getElementById("mySelect");
> // If the textbox is empty, use the select box value
> if(txtBox.value == "")
> theForm.action = actionBase + selectBox.value;
> else
> // otherwise, use the text box value
> theForm.action = actionBase + txtBox.value;
> theForm.submit();
> }
> </script>
> <form method="get" id="myForm">
> <select id="mySelect">
> <!-- would be populated from database -->
> <option>Val1</option>
> <option>Val2</option>
> <option>Val3</option>
> </select>
> <input id="myBox" type="textbox">
> <input type="button" value="Submit" onClick="process();">
> </form>
> -chris
>
>sql

Ability to load a TextBox with RichText ?

Is it possible (using SQL Server Reporting Services) to load a 'TextBox'
component with the contents of a RichText file (i.e. from a saved file
'testRpt.rtf') ?
Any suggestions would be appreciated.
Thanks in advance ...
SteveNo but yes I can solve your problem!
You can't get RTF text neatly formatted into a Reporting Services Textbox
control. - you could create a .NET function to strip the RTF content and
just display the raw text - but that's not what you really want is it?
So what you can do is create a .NET function in a custom assembly that you
pass the RTF into and have it return an image stream and what you then do is
bind that image data to a Reporting Services Image control.
(in the function you'll need to use the CreateGraphics() method.)
Hope that helps. If you need help on creating custom assemblies Chapter 9 of
our book does a great job showing how to progress and how to get Code Access
Security properly configured. We had intended to include the RTF example
but time and space meant that we didn't. I'll probably be doing an article
on this RTF example in the coming months in the Premium area of our web
site.
Peter Blackburn
www.sqlreportingservices.net
"Steve_S3T" <SteveS3T@.discussions.microsoft.com> wrote in message
news:BC061D8B-5FCC-4465-BE99-233BF1CFB292@.microsoft.com...
> Is it possible (using SQL Server Reporting Services) to load a 'TextBox'
> component with the contents of a RichText file (i.e. from a saved file
> 'testRpt.rtf') ?
> Any suggestions would be appreciated.
> Thanks in advance ...
> Steve|||Due to the fact that there's no direct route with this - I'm going to leave
it well alone. :(
Much least of all because I hate doing excessive coding if there's a more
direct approach - in this case I've found an alternate route via DataDynamics
ActiveReports - cue many groans ...
I'm still waiting on a copy of your book - it's been on order a while now.
I'll give that chapter a look through when the book finally gets to me ...
Steve
"Peter Blackburn (www.sqlreportingservice" wrote:
> No but yes I can solve your problem!
> You can't get RTF text neatly formatted into a Reporting Services Textbox
> control. - you could create a .NET function to strip the RTF content and
> just display the raw text - but that's not what you really want is it?
> So what you can do is create a .NET function in a custom assembly that you
> pass the RTF into and have it return an image stream and what you then do is
> bind that image data to a Reporting Services Image control.
> (in the function you'll need to use the CreateGraphics() method.)
> Hope that helps. If you need help on creating custom assemblies Chapter 9 of
> our book does a great job showing how to progress and how to get Code Access
> Security properly configured. We had intended to include the RTF example
> but time and space meant that we didn't. I'll probably be doing an article
> on this RTF example in the coming months in the Premium area of our web
> site.
> Peter Blackburn
> www.sqlreportingservices.net
>
>
> "Steve_S3T" <SteveS3T@.discussions.microsoft.com> wrote in message
> news:BC061D8B-5FCC-4465-BE99-233BF1CFB292@.microsoft.com...
> > Is it possible (using SQL Server Reporting Services) to load a 'TextBox'
> > component with the contents of a RichText file (i.e. from a saved file
> > 'testRpt.rtf') ?
> > Any suggestions would be appreciated.
> > Thanks in advance ...
> > Steve
>
>

Ability to import Data into SQL Server Express Edition

I am using SQL Server 2005 Express Edition and Server Mangement Studio
Express. I can connect to the server and create databases/tables just fine
but I can't seem to fine a way to import data into the table. The Data
Transformation wizard does not seem to be in the Management studio. Can
anybody give me some help in how to import data into express edition? Thanks,
Using the SQL 2000 version I use bcp (bulk copy) command line tool.
Don't know if the command is included in the 2005 version.

Ability to import Data into SQL Server Express Edition

I am using SQL Server 2005 Express Edition and Server Mangement Studio
Express. I can connect to the server and create databases/tables just fine
but I can't seem to fine a way to import data into the table. The Data
Transformation wizard does not seem to be in the Management studio. Can
anybody give me some help in how to import data into express edition? Thank
s,Using the SQL 2000 version I use bcp (bulk copy) command line tool.
Don't know if the command is included in the 2005 version.

Ability to import Data into SQL Server Express Edition

I am using SQL Server 2005 Express Edition and Server Mangement Studio
Express. I can connect to the server and create databases/tables just fine
but I can't seem to fine a way to import data into the table. The Data
Transformation wizard does not seem to be in the Management studio. Can
anybody give me some help in how to import data into express edition? Thanks,Using the SQL 2000 version I use bcp (bulk copy) command line tool.
Don't know if the command is included in the 2005 version.

Ability to create dynamic subreports within report

I have the need to create a report that contains four subreports. Each of the four subreports can be any one of 20-30 different reports (layouts differ).
Is there a way to programatically change the name (or source) of the subreport at runtime? Would this end up creating a new rdl for each report?
Any help or ideas are greatly appreciated!!
RickGcan you put "all" your sub reports under the master report and hide your sub
reports.
then dynamically, simply show the targeted sub reports.
"RickG" <RickG@.discussions.microsoft.com> a écrit dans le message de
news:BAF79348-FB1D-45B0-861B-4A3BDA30DE58@.microsoft.com...
> I have the need to create a report that contains four subreports. Each of
the four subreports can be any one of 20-30 different reports (layouts
differ).
> Is there a way to programatically change the name (or source) of the
subreport at runtime? Would this end up creating a new rdl for each report?
> Any help or ideas are greatly appreciated!!
> RickGsql

Ability to create and schedule jobs on shared system

I have a shared SQL Server, used by applications that donâ't need an
instance, just a DB. Users with DBO rights to their DB, no system roles, can
still create and schedule jobs under sql agent. I donâ't want to allow this,
how can I prevent it?Hello Jason,
You could use sqlagent proxy account to run the jobs if they are not in
sysadmin server role. If you want to prevent it, you could use the
following method:
1. Start SQL Server Enterprise Manager.
2. In SQL Server Enterprise Manager, expand Microsoft SQL Server, and then
expand SQL Server Group.
3. Expand the instance of SQL Server that you want to set up the proxy
account for.
4. Expand Management, right-click SQL Server Agent, and then click
Properties.
5. In the SQL Server Agent Properties dialog box, click the Job System
tab.
6. Under Non-SysAdmin job step proxy account, click to check the Only
users with SysAdmin priviledges can execute CmdExec and ActiveScripting job
steps check box.
If you have any further questions on the issue, please feel free to let's
know. Thank you.
Best Regards,
Peter Yang
MCSE2000/2003, MCSA, MCDBA
Microsoft Online Community Support
==================================================Get notification to my posts through email? Please refer to
http://msdn.microsoft.com/subscriptions/managednewsgroups/default.aspx#notif
ications
<http://msdn.microsoft.com/subscriptions/managednewsgroups/default.aspx>.
Note: The MSDN Managed Newsgroup support offering is for non-urgent issues
where an initial response from the community or a Microsoft Support
Engineer within 1 business day is acceptable. Please note that each follow
up response may take approximately 2 business days as the support
professional working with you may need further investigation to reach the
most efficient resolution. The offering is not appropriate for situations
that require urgent, real-time or phone-based interactions or complex
project analysis and dump analysis issues. Issues of this nature are best
handled working with a dedicated Microsoft Support Engineer by contacting
Microsoft Customer Support Services (CSS) at
<http://msdn.microsoft.com/subscriptions/support/default.aspx>.
==================================================This posting is provided "AS IS" with no warranties, and confers no rights.|||Hi Jason,
I'm still interested in this issue. If you have any comments or questions,
please feel free to let's know. We look forward to hearing from you.
Best Regards,
Peter Yang
MCSE2000/2003, MCSA, MCDBA
Microsoft Online Partner Support
When responding to posts, please "Reply to Group" via your newsreader so
that others may learn and benefit from your issue.
=====================================================
This posting is provided "AS IS" with no warranties, and confers no rights.|||i looked at this setting, it currently is checked, however there is a user w/
only dbo rights to their db that can create, schedule jobs and run jobs.
i checked the roles, he has none.
this is a windows account, it if has some high level, domain admin type
right in AD, could AD be working behind the scenes to enable the features in
SQL Server for this user?
""Peter YangMSFT]"" wrote:
> Hello Jason,
> You could use sqlagent proxy account to run the jobs if they are not in
> sysadmin server role. If you want to prevent it, you could use the
> following method:
> 1. Start SQL Server Enterprise Manager.
> 2. In SQL Server Enterprise Manager, expand Microsoft SQL Server, and then
> expand SQL Server Group.
> 3. Expand the instance of SQL Server that you want to set up the proxy
> account for.
> 4. Expand Management, right-click SQL Server Agent, and then click
> Properties.
> 5. In the SQL Server Agent Properties dialog box, click the Job System
> tab.
> 6. Under Non-SysAdmin job step proxy account, click to check the Only
> users with SysAdmin priviledges can execute CmdExec and ActiveScripting job
> steps check box.
> If you have any further questions on the issue, please feel free to let's
> know. Thank you.
> Best Regards,
> Peter Yang
> MCSE2000/2003, MCSA, MCDBA
> Microsoft Online Community Support
> ==================================================> Get notification to my posts through email? Please refer to
> http://msdn.microsoft.com/subscriptions/managednewsgroups/default.aspx#notif
> ications
> <http://msdn.microsoft.com/subscriptions/managednewsgroups/default.aspx>.
> Note: The MSDN Managed Newsgroup support offering is for non-urgent issues
> where an initial response from the community or a Microsoft Support
> Engineer within 1 business day is acceptable. Please note that each follow
> up response may take approximately 2 business days as the support
> professional working with you may need further investigation to reach the
> most efficient resolution. The offering is not appropriate for situations
> that require urgent, real-time or phone-based interactions or complex
> project analysis and dump analysis issues. Issues of this nature are best
> handled working with a dedicated Microsoft Support Engineer by contacting
> Microsoft Customer Support Services (CSS) at
> <http://msdn.microsoft.com/subscriptions/support/default.aspx>.
> ==================================================> This posting is provided "AS IS" with no warranties, and confers no rights.
>
>|||Hello Jason,
Yes. If it's domain admin, it's by default in the group local admin groups.
Local admin group is added in SQL server with sysadmin rights by default.
You may want to check the logins on the server to check this.
You may want to temporarily remove the login to test if the issue still
occurs. Thanks.
Best Regards,
Peter Yang
MCSE2000/2003, MCSA, MCDBA
Microsoft Online Partner Support
When responding to posts, please "Reply to Group" via your newsreader so
that others may learn and benefit from your issue.
=====================================================Please note that the newsgroups are staffed weekdays with a goal to provide
ONE BUSINESS DAY RESPONSE to all posts.
If this response time does not meet your needs, please contact CSS for more
immediate assistance:
http://support.microsoft.com/default.aspx?scid=fh;EN-US;OfferProPhone#faq607|||i have found another user who is NOT a domain admin, OR server admin. he is
DBO on his db and is able to create/run a job that runs a select from the
database.
i guess becuase these to meet the criteria of that checkbox.
that checkbox you mentioned, what actually is considered a cmdexec step?
assuming that is the case, is there any other way to block users from
creating jobs?
""Peter YangMSFT]"" wrote:
> Hello Jason,
> Yes. If it's domain admin, it's by default in the group local admin groups.
> Local admin group is added in SQL server with sysadmin rights by default.
> You may want to check the logins on the server to check this.
> You may want to temporarily remove the login to test if the issue still
> occurs. Thanks.
> Best Regards,
> Peter Yang
> MCSE2000/2003, MCSA, MCDBA
> Microsoft Online Partner Support
> When responding to posts, please "Reply to Group" via your newsreader so
> that others may learn and benefit from your issue.
> =====================================================> Please note that the newsgroups are staffed weekdays with a goal to provide
> ONE BUSINESS DAY RESPONSE to all posts.
> If this response time does not meet your needs, please contact CSS for more
> immediate assistance:
> http://support.microsoft.com/default.aspx?scid=fh;EN-US;OfferProPhone#faq607
>|||Hello Jason,
I'd like to confirm if check the "Only users with SysAdmin priviledges can
execute CmdExec and ActiveScripting job
steps" check box in the sqlagent property dialog. If so, it's supposed that
a domain user without sysadmin rights shall be able to create job but the
job cannot run properly because there is no proxy agent account to run the
job.
If you have proxy account configured, you are not able to block only one
user/login using the proxy account because it's used as proxy for all users
without sysadmin rights.
I think cmdexec step in a job is actually run as the proxy account.
Best Regards,
Peter Yang
MCSE2000/2003, MCSA, MCDBA
Microsoft Online Partner Support|||that check box is checked.
upon further testing, this is what I see.
only some commands are blocked as indicated by the descriptive text.
e.g. a user can create and run a job that does a simple select. but user
cannot run a job that kicks off a DTS package as it requires a cmdexec cmd,
he can create it though. I was wanting to block the running off all jobs to
force users to schedule them through a DBA.
""Peter YangMSFT]"" wrote:
> Hello Jason,
> I'd like to confirm if check the "Only users with SysAdmin priviledges can
> execute CmdExec and ActiveScripting job
> steps" check box in the sqlagent property dialog. If so, it's supposed that
> a domain user without sysadmin rights shall be able to create job but the
> job cannot run properly because there is no proxy agent account to run the
> job.
> If you have proxy account configured, you are not able to block only one
> user/login using the proxy account because it's used as proxy for all users
> without sysadmin rights.
> I think cmdexec step in a job is actually run as the proxy account.
> Best Regards,
> Peter Yang
> MCSE2000/2003, MCSA, MCDBA
> Microsoft Online Partner Support
>|||Hello Jason,
Sorry for my fault and I spoke too quick based on my memory. In SQLServer
2000, the following table describes the user context under which a
scheduled SQLServer Agent job is run depending on whether the owner of the
job is sysadmin in SQLServer or not.
Owner of job Job Type Job executed as (user)
=========== ========= =============
non-sysadmin TSQL [owner of Job]
non-sysadmin CmdExec/Activex [SQL Agent proxy account]
sysadmin TSQL [owner of Job]
sysadmin CmdExec/Activex [SQLServer startup account]
Also, scheduled DTS packages fall under CmdExec job type.
You are correct that the checkbox only blocks CmdExec and ActiveScripting
job of non-sysadmin users. They could still schedule and run jobs that
don't use CmdExec and ActiveScripting job etc.
Since the SQLagent will "impersonate" the user only when the user runs the
job step, actually there is no option to "deny" the user to access the
database objects that he has permissions in the first place.
However, you could deny the user to create jobs by the following method:
1. Add the user as a database user of msdb database.
2. Run the following statement to deny its permission to
use msdb
deny execute on msdb.dbo.sp_add_job to username
If you have any further questions or concerns, please feel free to let's
know. Thank you.
Best Regards,
Peter Yang
MCSE2000/2003, MCSA, MCDBA
Microsoft Online Partner Support
When responding to posts, please "Reply to Group" via your newsreader so
that others may learn and benefit from your issue.
=====================================================
This posting is provided "AS IS" with no warranties, and confers no rights.|||Hello Jason,
I'm still interested in this issue. If you have any comments or questions,
please feel free to let's know. We look forward to hearing from you.
Best Regards,
Peter Yang
MCSE2000/2003, MCSA, MCDBA
Microsoft Online Partner Support
When responding to posts, please "Reply to Group" via your newsreader so
that others may learn and benefit from your issue.
=====================================================
This posting is provided "AS IS" with no warranties, and confers no rights.

Ability to create and schedule jobs on shared system

I have a shared SQL Server, used by applications that don’t need an
instance, just a DB. Users with DBO rights to their DB, no system roles, can
still create and schedule jobs under sql agent. I don’t want to allow this,
how can I prevent it?
Hello Jason,
You could use sqlagent proxy account to run the jobs if they are not in
sysadmin server role. If you want to prevent it, you could use the
following method:
1. Start SQL Server Enterprise Manager.
2. In SQL Server Enterprise Manager, expand Microsoft SQL Server, and then
expand SQL Server Group.
3. Expand the instance of SQL Server that you want to set up the proxy
account for.
4. Expand Management, right-click SQL Server Agent, and then click
Properties.
5. In the SQL Server Agent Properties dialog box, click the Job System
tab.
6. Under Non-SysAdmin job step proxy account, click to check the Only
users with SysAdmin priviledges can execute CmdExec and ActiveScripting job
steps check box.
If you have any further questions on the issue, please feel free to let's
know. Thank you.
Best Regards,
Peter Yang
MCSE2000/2003, MCSA, MCDBA
Microsoft Online Community Support
==================================================
Get notification to my posts through email? Please refer to
http://msdn.microsoft.com/subscriptions/managednewsgroups/default.aspx#notif
ications
<http://msdn.microsoft.com/subscriptions/managednewsgroups/default.aspx>.
Note: The MSDN Managed Newsgroup support offering is for non-urgent issues
where an initial response from the community or a Microsoft Support
Engineer within 1 business day is acceptable. Please note that each follow
up response may take approximately 2 business days as the support
professional working with you may need further investigation to reach the
most efficient resolution. The offering is not appropriate for situations
that require urgent, real-time or phone-based interactions or complex
project analysis and dump analysis issues. Issues of this nature are best
handled working with a dedicated Microsoft Support Engineer by contacting
Microsoft Customer Support Services (CSS) at
<http://msdn.microsoft.com/subscriptions/support/default.aspx>.
==================================================
This posting is provided "AS IS" with no warranties, and confers no rights.
|||i looked at this setting, it currently is checked, however there is a user w/
only dbo rights to their db that can create, schedule jobs and run jobs.
i checked the roles, he has none.
this is a windows account, it if has some high level, domain admin type
right in AD, could AD be working behind the scenes to enable the features in
SQL Server for this user?
""Peter YangMSFT]"" wrote:

> Hello Jason,
> You could use sqlagent proxy account to run the jobs if they are not in
> sysadmin server role. If you want to prevent it, you could use the
> following method:
> 1. Start SQL Server Enterprise Manager.
> 2. In SQL Server Enterprise Manager, expand Microsoft SQL Server, and then
> expand SQL Server Group.
> 3. Expand the instance of SQL Server that you want to set up the proxy
> account for.
> 4. Expand Management, right-click SQL Server Agent, and then click
> Properties.
> 5. In the SQL Server Agent Properties dialog box, click the Job System
> tab.
> 6. Under Non-SysAdmin job step proxy account, click to check the Only
> users with SysAdmin priviledges can execute CmdExec and ActiveScripting job
> steps check box.
> If you have any further questions on the issue, please feel free to let's
> know. Thank you.
> Best Regards,
> Peter Yang
> MCSE2000/2003, MCSA, MCDBA
> Microsoft Online Community Support
> ==================================================
> Get notification to my posts through email? Please refer to
> http://msdn.microsoft.com/subscriptions/managednewsgroups/default.aspx#notif
> ications
> <http://msdn.microsoft.com/subscriptions/managednewsgroups/default.aspx>.
> Note: The MSDN Managed Newsgroup support offering is for non-urgent issues
> where an initial response from the community or a Microsoft Support
> Engineer within 1 business day is acceptable. Please note that each follow
> up response may take approximately 2 business days as the support
> professional working with you may need further investigation to reach the
> most efficient resolution. The offering is not appropriate for situations
> that require urgent, real-time or phone-based interactions or complex
> project analysis and dump analysis issues. Issues of this nature are best
> handled working with a dedicated Microsoft Support Engineer by contacting
> Microsoft Customer Support Services (CSS) at
> <http://msdn.microsoft.com/subscriptions/support/default.aspx>.
> ==================================================
> This posting is provided "AS IS" with no warranties, and confers no rights.
>
>
|||Hello Jason,
Yes. If it's domain admin, it's by default in the group local admin groups.
Local admin group is added in SQL server with sysadmin rights by default.
You may want to check the logins on the server to check this.
You may want to temporarily remove the login to test if the issue still
occurs. Thanks.
Best Regards,
Peter Yang
MCSE2000/2003, MCSA, MCDBA
Microsoft Online Partner Support
When responding to posts, please "Reply to Group" via your newsreader so
that others may learn and benefit from your issue.
================================================== ===
Please note that the newsgroups are staffed weekdays with a goal to provide
ONE BUSINESS DAY RESPONSE to all posts.
If this response time does not meet your needs, please contact CSS for more
immediate assistance:
http://support.microsoft.com/default.aspx?scid=fh;EN-US;OfferProPhone#faq607
|||i have found another user who is NOT a domain admin, OR server admin. he is
DBO on his db and is able to create/run a job that runs a select from the
database.
i guess becuase these to meet the criteria of that checkbox.
that checkbox you mentioned, what actually is considered a cmdexec step?
assuming that is the case, is there any other way to block users from
creating jobs?
""Peter YangMSFT]"" wrote:

> Hello Jason,
> Yes. If it's domain admin, it's by default in the group local admin groups.
> Local admin group is added in SQL server with sysadmin rights by default.
> You may want to check the logins on the server to check this.
> You may want to temporarily remove the login to test if the issue still
> occurs. Thanks.
> Best Regards,
> Peter Yang
> MCSE2000/2003, MCSA, MCDBA
> Microsoft Online Partner Support
> When responding to posts, please "Reply to Group" via your newsreader so
> that others may learn and benefit from your issue.
> ================================================== ===
> Please note that the newsgroups are staffed weekdays with a goal to provide
> ONE BUSINESS DAY RESPONSE to all posts.
> If this response time does not meet your needs, please contact CSS for more
> immediate assistance:
> http://support.microsoft.com/default.aspx?scid=fh;EN-US;OfferProPhone#faq607
>
|||Hello Jason,
I'd like to confirm if check the "Only users with SysAdmin priviledges can
execute CmdExec and ActiveScripting job
steps" check box in the sqlagent property dialog. If so, it's supposed that
a domain user without sysadmin rights shall be able to create job but the
job cannot run properly because there is no proxy agent account to run the
job.
If you have proxy account configured, you are not able to block only one
user/login using the proxy account because it's used as proxy for all users
without sysadmin rights.
I think cmdexec step in a job is actually run as the proxy account.
Best Regards,
Peter Yang
MCSE2000/2003, MCSA, MCDBA
Microsoft Online Partner Support
|||that check box is checked.
upon further testing, this is what I see.
only some commands are blocked as indicated by the descriptive text.
e.g. a user can create and run a job that does a simple select. but user
cannot run a job that kicks off a DTS package as it requires a cmdexec cmd,
he can create it though. I was wanting to block the running off all jobs to
force users to schedule them through a DBA.
""Peter YangMSFT]"" wrote:

> Hello Jason,
> I'd like to confirm if check the "Only users with SysAdmin priviledges can
> execute CmdExec and ActiveScripting job
> steps" check box in the sqlagent property dialog. If so, it's supposed that
> a domain user without sysadmin rights shall be able to create job but the
> job cannot run properly because there is no proxy agent account to run the
> job.
> If you have proxy account configured, you are not able to block only one
> user/login using the proxy account because it's used as proxy for all users
> without sysadmin rights.
> I think cmdexec step in a job is actually run as the proxy account.
> Best Regards,
> Peter Yang
> MCSE2000/2003, MCSA, MCDBA
> Microsoft Online Partner Support
>

Ability to create and schedule jobs on shared system

I have a shared SQL Server, used by applications that don’t need an
instance, just a DB. Users with DBO rights to their DB, no system roles, ca
n
still create and schedule jobs under sql agent. I don’t want to allow thi
s,
how can I prevent it?Hello Jason,
You could use sqlagent proxy account to run the jobs if they are not in
sysadmin server role. If you want to prevent it, you could use the
following method:
1. Start SQL Server Enterprise Manager.
2. In SQL Server Enterprise Manager, expand Microsoft SQL Server, and then
expand SQL Server Group.
3. Expand the instance of SQL Server that you want to set up the proxy
account for.
4. Expand Management, right-click SQL Server Agent, and then click
Properties.
5. In the SQL Server Agent Properties dialog box, click the Job System
tab.
6. Under Non-SysAdmin job step proxy account, click to check the Only
users with SysAdmin priviledges can execute CmdExec and ActiveScripting job
steps check box.
If you have any further questions on the issue, please feel free to let's
know. Thank you.
Best Regards,
Peter Yang
MCSE2000/2003, MCSA, MCDBA
Microsoft Online Community Support
========================================
==========
Get notification to my posts through email? Please refer to
http://msdn.microsoft.com/subscript...ault.aspx#notif
ications
<http://msdn.microsoft.com/subscript...ps/default.aspx>.
Note: The MSDN Managed Newsgroup support offering is for non-urgent issues
where an initial response from the community or a Microsoft Support
Engineer within 1 business day is acceptable. Please note that each follow
up response may take approximately 2 business days as the support
professional working with you may need further investigation to reach the
most efficient resolution. The offering is not appropriate for situations
that require urgent, real-time or phone-based interactions or complex
project analysis and dump analysis issues. Issues of this nature are best
handled working with a dedicated Microsoft Support Engineer by contacting
Microsoft Customer Support Services (CSS) at
<http://msdn.microsoft.com/subscript...rt/default.aspx>.
========================================
==========
This posting is provided "AS IS" with no warranties, and confers no rights.|||Hi Jason,
I'm still interested in this issue. If you have any comments or questions,
please feel free to let's know. We look forward to hearing from you.
Best Regards,
Peter Yang
MCSE2000/2003, MCSA, MCDBA
Microsoft Online Partner Support
When responding to posts, please "Reply to Group" via your newsreader so
that others may learn and benefit from your issue.
========================================
=============
This posting is provided "AS IS" with no warranties, and confers no rights.|||i looked at this setting, it currently is checked, however there is a user w
/
only dbo rights to their db that can create, schedule jobs and run jobs.
i checked the roles, he has none.
this is a windows account, it if has some high level, domain admin type
right in AD, could AD be working behind the scenes to enable the features in
SQL Server for this user?
""Peter YangMSFT]"" wrote:

> Hello Jason,
> You could use sqlagent proxy account to run the jobs if they are not in
> sysadmin server role. If you want to prevent it, you could use the
> following method:
> 1. Start SQL Server Enterprise Manager.
> 2. In SQL Server Enterprise Manager, expand Microsoft SQL Server, and the
n
> expand SQL Server Group.
> 3. Expand the instance of SQL Server that you want to set up the proxy
> account for.
> 4. Expand Management, right-click SQL Server Agent, and then click
> Properties.
> 5. In the SQL Server Agent Properties dialog box, click the Job System
> tab.
> 6. Under Non-SysAdmin job step proxy account, click to check the Only
> users with SysAdmin priviledges can execute CmdExec and ActiveScripting jo
b
> steps check box.
> If you have any further questions on the issue, please feel free to let's
> know. Thank you.
> Best Regards,
> Peter Yang
> MCSE2000/2003, MCSA, MCDBA
> Microsoft Online Community Support
> ========================================
==========
> Get notification to my posts through email? Please refer to
> l]
> ications
> <[url]http://msdn.microsoft.com/subscriptions/managednewsgroups/default.aspx" target="_blank">http://msdn.microsoft.com/subscript...ps/default.aspx>.
> Note: The MSDN Managed Newsgroup support offering is for non-urgent issues
> where an initial response from the community or a Microsoft Support
> Engineer within 1 business day is acceptable. Please note that each follow
> up response may take approximately 2 business days as the support
> professional working with you may need further investigation to reach the
> most efficient resolution. The offering is not appropriate for situations
> that require urgent, real-time or phone-based interactions or complex
> project analysis and dump analysis issues. Issues of this nature are best
> handled working with a dedicated Microsoft Support Engineer by contacting
> Microsoft Customer Support Services (CSS) at
> <http://msdn.microsoft.com/subscript...rt/default.aspx>.
> ========================================
==========
> This posting is provided "AS IS" with no warranties, and confers no rights
.
>
>|||Hello Jason,
Yes. If it's domain admin, it's by default in the group local admin groups.
Local admin group is added in SQL server with sysadmin rights by default.
You may want to check the logins on the server to check this.
You may want to temporarily remove the login to test if the issue still
occurs. Thanks.
Best Regards,
Peter Yang
MCSE2000/2003, MCSA, MCDBA
Microsoft Online Partner Support
When responding to posts, please "Reply to Group" via your newsreader so
that others may learn and benefit from your issue.
========================================
=============
Please note that the newsgroups are staffed weekdays with a goal to provide
ONE BUSINESS DAY RESPONSE to all posts.
If this response time does not meet your needs, please contact CSS for more
immediate assistance:
http://support.microsoft.com/defaul...ProPhone#faq607|||i have found another user who is NOT a domain admin, OR server admin. he is
DBO on his db and is able to create/run a job that runs a select from the
database.
i guess becuase these to meet the criteria of that checkbox.
that checkbox you mentioned, what actually is considered a cmdexec step?
assuming that is the case, is there any other way to block users from
creating jobs?
""Peter YangMSFT]"" wrote:

> Hello Jason,
> Yes. If it's domain admin, it's by default in the group local admin groups
.
> Local admin group is added in SQL server with sysadmin rights by default.
> You may want to check the logins on the server to check this.
> You may want to temporarily remove the login to test if the issue still
> occurs. Thanks.
> Best Regards,
> Peter Yang
> MCSE2000/2003, MCSA, MCDBA
> Microsoft Online Partner Support
> When responding to posts, please "Reply to Group" via your newsreader so
> that others may learn and benefit from your issue.
> ========================================
=============
> Please note that the newsgroups are staffed weekdays with a goal to provid
e
> ONE BUSINESS DAY RESPONSE to all posts.
> If this response time does not meet your needs, please contact CSS for mor
e
> immediate assistance:
> [url]http://support.microsoft.com/default.aspx?scid=fh;EN-US;OfferProPhone#faq607[/ur
l]
>|||Hello Jason,
I'd like to confirm if check the "Only users with SysAdmin priviledges can
execute CmdExec and ActiveScripting job
steps" check box in the sqlagent property dialog. If so, it's supposed that
a domain user without sysadmin rights shall be able to create job but the
job cannot run properly because there is no proxy agent account to run the
job.
If you have proxy account configured, you are not able to block only one
user/login using the proxy account because it's used as proxy for all users
without sysadmin rights.
I think cmdexec step in a job is actually run as the proxy account.
Best Regards,
Peter Yang
MCSE2000/2003, MCSA, MCDBA
Microsoft Online Partner Support|||that check box is checked.
upon further testing, this is what I see.
only some commands are blocked as indicated by the descriptive text.
e.g. a user can create and run a job that does a simple select. but user
cannot run a job that kicks off a DTS package as it requires a cmdexec cmd,
he can create it though. I was wanting to block the running off all jobs to
force users to schedule them through a DBA.
""Peter YangMSFT]"" wrote:

> Hello Jason,
> I'd like to confirm if check the "Only users with SysAdmin priviledges ca
n
> execute CmdExec and ActiveScripting job
> steps" check box in the sqlagent property dialog. If so, it's supposed tha
t
> a domain user without sysadmin rights shall be able to create job but the
> job cannot run properly because there is no proxy agent account to run the
> job.
> If you have proxy account configured, you are not able to block only one
> user/login using the proxy account because it's used as proxy for all user
s
> without sysadmin rights.
> I think cmdexec step in a job is actually run as the proxy account.
> Best Regards,
> Peter Yang
> MCSE2000/2003, MCSA, MCDBA
> Microsoft Online Partner Support
>|||Hello Jason,
Sorry for my fault and I spoke too quick based on my memory. In SQLServer
2000, the following table describes the user context under which a
scheduled SQLServer Agent job is run depending on whether the owner of the
job is sysadmin in SQLServer or not.
Owner of job Job Type Job executed as (user)
=========== ========= =============
non-sysadmin TSQL [owner of Job]
non-sysadmin CmdExec/Activex [SQL Agent proxy account]
sysadmin TSQL [owner of Job]
sysadmin CmdExec/Activex [SQLServer startup account]
Also, scheduled DTS packages fall under CmdExec job type.
You are correct that the checkbox only blocks CmdExec and ActiveScripting
job of non-sysadmin users. They could still schedule and run jobs that
don't use CmdExec and ActiveScripting job etc.
Since the SQLagent will "impersonate" the user only when the user runs the
job step, actually there is no option to "deny" the user to access the
database objects that he has permissions in the first place.
However, you could deny the user to create jobs by the following method:
1. Add the user as a database user of msdb database.
2. Run the following statement to deny its permission to
use msdb
deny execute on msdb.dbo.sp_add_job to username
If you have any further questions or concerns, please feel free to let's
know. Thank you.
Best Regards,
Peter Yang
MCSE2000/2003, MCSA, MCDBA
Microsoft Online Partner Support
When responding to posts, please "Reply to Group" via your newsreader so
that others may learn and benefit from your issue.
========================================
=============
This posting is provided "AS IS" with no warranties, and confers no rights.

Saturday, February 11, 2012

A little connection chaos.

Hi Mike,

Me again, in trouble as usual.

Finally got my application finished, and want to have the database on a server, with the ability to access it from the Internet, or from our internal domain. Had some help setting up the server wirth Small Business Server 2003, after which everything went pear shaped. My helper renamed my PC, on which I'd been using SqlExpress as a local server. With that, in Visual Studio I was only able to access my database by changing the connection string to a User Instance.

I now have SqlExpress installed on the SBS Server 2003, and installed a copy of my database there. I have a situation that logged on as a User on my PC, I cannot connect to my database which is on the server, either in Management Studio, or in Visual Studio. I can 'see' the server instance, but cannot connect. I think it's something to do with permissions, but dont know how to fix this. I've had two MS Sql error messages one No. 4060 and the other No 916.

If I log on as administrator, things change. I can connect to the server database in Management Studio, and open all my tables, however, if I try to do the same in Visual Studio, this fails. Initially I couldnt even connect to a User Instance, but on the last try I was able to. I've read your FAQs and Blogs, but haven't progressed much.

My big problem is in wanting to deploy my application, I need to establish the correct connection strings for my settings. Since I have to manually change all my Crystal Reports connection strings as well, I'd prefer to only have to do this once.

I know this isn't much concrete info on which to work, but hopefully it will give us a start.

As User logon the two sqlservr.exe Processes you mention where running. As an administrator logon, there are two sqlservr.exe processes running, one as NETWORK SERVICE the other as SYSTEM. if that is any help.

John

hi John

Tailor wrote:

..

I now have SqlExpress installed on the SBS Server 2003, and installed a copy of my database there. I have a situation that logged on as a User on my PC, I cannot connect to my database which is on the server, either in Management Studio, or in Visual Studio. I can 'see' the server instance, but cannot connect. I think it's something to do with permissions, but dont know how to fix this. I've had two MS Sql error messages one No. 4060 and the other No 916.

If I log on as administrator, things change. I can connect to the server database in Management Studio, and open all my tables, however, if I try to do the same in Visual Studio, this fails. Initially I couldnt even connect to a User Instance, but on the last try I was able to. I've read your FAQs and Blogs, but haven't progressed much.

...

please verify an actual Login (individual or at group granularity) exists on the SBS installed instance for your remote credentials...

that's meaning, your limited user has probably not been granted authentication rights to the instance..

regards

|||

Hi Andrea,

My apologies for the delay in replying, as I've been away for about a week.

I'm sure you are correct, so will see if I can sort it out, although it's my first experience of SBS.

Thanks

John