2012年3月19日星期一
Disbling parameters pased in URL
I'm passing in parameters via the URL. Is there a way to disable some
parameters so users can't change them once the report is displayed in the
browser and ready to run? I don't see it in 2000, but maybe it's in 2005
which I haven't purchased yet.
thanks,
-TrishHave you tried making the parameters hidden?
--
Wayne Snyder MCDBA, SQL Server MVP
Mariner, Charlotte, NC
I support the Professional Association for SQL Server ( PASS) and it''s
community of SQL Professionals.
"Trishmi" wrote:
> Hi,
> I'm passing in parameters via the URL. Is there a way to disable some
> parameters so users can't change them once the report is displayed in the
> browser and ready to run? I don't see it in 2000, but maybe it's in 2005
> which I haven't purchased yet.
> thanks,
> -Trish|||I'm not sure how to make the parameters hidden on the report viewer once the
report is launched.
Here is how I'm launching my report from a .aspx file:
<FORM id="frmRender"
action="http://myreporserver/reportserver?<%=Request("RPT")%>" method="post">
<INPUT type="hidden" name="rs:Command" value="Render">
<INPUT type="hidden" name="rc:LinkTarget" value="main">
<INPUT type="hidden" name="rs:Format" value="HTML4.0">
<input type="hidden" name="db" value=<%=Session("HostDB")%>>
<input type="hidden" name="Company" value=<%=Session("CompanyName")%>>
</FORM>
Once it launches, the DB and Company parameters show in the toolbar. I'd
like to disable those. I can't hide the whole toolbar because there will be
parameters that require the user to select from a dropdownlistbox.
thanks,
-Trish
"Wayne Snyder" wrote:
> Have you tried making the parameters hidden?
> --
> Wayne Snyder MCDBA, SQL Server MVP
> Mariner, Charlotte, NC
> I support the Professional Association for SQL Server ( PASS) and it''s
> community of SQL Professionals.
>
> "Trishmi" wrote:
> > Hi,
> >
> > I'm passing in parameters via the URL. Is there a way to disable some
> > parameters so users can't change them once the report is displayed in the
> > browser and ready to run? I don't see it in 2000, but maybe it's in 2005
> > which I haven't purchased yet.
> >
> > thanks,
> > -Trish
2012年3月7日星期三
Disabling triggers with alter table, execute as?
launched from another trigger:
ALTER TABLE PM00300 DISABLE TRIGGER insPM00300
I want normal users to be able to run that command. Is there a kind of
"execute as" I can use in SQL Server 2000 to do it?
Thanks.Before I answer: are you sure you want to do this? The entire point of a
trigger is to fire regardless of user control. Be very careful here. I'm
going to lay out an option in 2000, but I don't endorse it's usage (I'm
presenting it simply because I don't know exactly what you're business goal
is - it may be perfectly valid).
Technically you could create a job that disables the trigger, then give
users access to the job and let them call it from within a stored procedure
or such. Be sure not to create a schedule for the job. With a SQL Agent job,
you can control (somewhat) the execution authority.
"b3nny80y" <b3nny80y@.discussions.microsoft.com> wrote in message
news:FF0D789D-3DE5-4354-B5A2-0AAE27CAFFB7@.microsoft.com...
> I'm disabling some triggers in SQL Server 2000 with the following command
> launched from another trigger:
> ALTER TABLE PM00300 DISABLE TRIGGER insPM00300
> I want normal users to be able to run that command. Is there a kind of
> "execute as" I can use in SQL Server 2000 to do it?
> Thanks.|||Is that wise?
For the user to execute an ALTER table, they will have to be provided table
ownership privileges. That means that the users can alter the table anyway
they desire -DROP columns, ADD columns, DROP TABLE, etc.
If you are trying to stop nested Triggers, there is another way. Use
sp_configure to turn on/off the Using Nested Triggers configuration option.
(Or use Server properties in Enterprise Manager.)
Arnie Rowland*
"To be successful, your heart must accompany your knowledge."
"b3nny80y" <b3nny80y@.discussions.microsoft.com> wrote in message
news:FF0D789D-3DE5-4354-B5A2-0AAE27CAFFB7@.microsoft.com...
> I'm disabling some triggers in SQL Server 2000 with the following command
> launched from another trigger:
> ALTER TABLE PM00300 DISABLE TRIGGER insPM00300
> I want normal users to be able to run that command. Is there a kind of
> "execute as" I can use in SQL Server 2000 to do it?
> Thanks.|||b3nny80y wrote:
> I'm disabling some triggers in SQL Server 2000 with the following command
> launched from another trigger:
> ALTER TABLE PM00300 DISABLE TRIGGER insPM00300
> I want normal users to be able to run that command. Is there a kind of
> "execute as" I can use in SQL Server 2000 to do it?
> Thanks.
Why would you want to do this? Please explain further what you're
trying to accomplish. If you're trying to disable the triggers for
specific users, you can accomplish the same effect by putting IF/ELSE
code in the trigger that checks the current username, and simply doesn't
execute the code in the trigger.
Tracy McKibben
MCDBA
http://www.realsqlguy.com
Disabling triggers with alter table, execute as?
launched from another trigger:
ALTER TABLE PM00300 DISABLE TRIGGER insPM00300
I want normal users to be able to run that command. Is there a kind of
"execute as" I can use in SQL Server 2000 to do it?
Thanks.Before I answer: are you sure you want to do this? The entire point of a
trigger is to fire regardless of user control. Be very careful here. I'm
going to lay out an option in 2000, but I don't endorse it's usage (I'm
presenting it simply because I don't know exactly what you're business goal
is - it may be perfectly valid).
Technically you could create a job that disables the trigger, then give
users access to the job and let them call it from within a stored procedure
or such. Be sure not to create a schedule for the job. With a SQL Agent job,
you can control (somewhat) the execution authority.
"b3nny80y" <b3nny80y@.discussions.microsoft.com> wrote in message
news:FF0D789D-3DE5-4354-B5A2-0AAE27CAFFB7@.microsoft.com...
> I'm disabling some triggers in SQL Server 2000 with the following command
> launched from another trigger:
> ALTER TABLE PM00300 DISABLE TRIGGER insPM00300
> I want normal users to be able to run that command. Is there a kind of
> "execute as" I can use in SQL Server 2000 to do it?
> Thanks.|||Is that wise?
For the user to execute an ALTER table, they will have to be provided table
ownership privileges. That means that the users can alter the table anyway
they desire -DROP columns, ADD columns, DROP TABLE, etc.
If you are trying to stop nested Triggers, there is another way. Use
sp_configure to turn on/off the Using Nested Triggers configuration option.
(Or use Server properties in Enterprise Manager.)
--
Arnie Rowland*
"To be successful, your heart must accompany your knowledge."
"b3nny80y" <b3nny80y@.discussions.microsoft.com> wrote in message
news:FF0D789D-3DE5-4354-B5A2-0AAE27CAFFB7@.microsoft.com...
> I'm disabling some triggers in SQL Server 2000 with the following command
> launched from another trigger:
> ALTER TABLE PM00300 DISABLE TRIGGER insPM00300
> I want normal users to be able to run that command. Is there a kind of
> "execute as" I can use in SQL Server 2000 to do it?
> Thanks.|||b3nny80y wrote:
> I'm disabling some triggers in SQL Server 2000 with the following command
> launched from another trigger:
> ALTER TABLE PM00300 DISABLE TRIGGER insPM00300
> I want normal users to be able to run that command. Is there a kind of
> "execute as" I can use in SQL Server 2000 to do it?
> Thanks.
Why would you want to do this? Please explain further what you're
trying to accomplish. If you're trying to disable the triggers for
specific users, you can accomplish the same effect by putting IF/ELSE
code in the trigger that checks the current username, and simply doesn't
execute the code in the trigger.
--
Tracy McKibben
MCDBA
http://www.realsqlguy.com
Disabling triggers from stored procedures
Is it possible to disable a trigger from a Stored Procedure? If it is, how do you do it?
Thanks,
FedericoALTER TABLE [MyTable] DISABLE TRIGGER trMyTrigger|||Just curious as to why you would want to do this?|||Yes, it is possible to disable the trigger, but keep in mind that you are disabling that trigger for everyone using the table, not just for what the trigger is doing. I don't know of any way to allow a trigger to function for some users/spids and not for others, except to include code within the trigger to make it decide that it shouldn't run under some conditions.
-PatP|||If SQL Server 2000 and one can alter the trigger then one can use SET CONTEXT_INFO in SP and then check master..sysprocesses from trigger.
Might also insert DBCC INPUTBUFFER(@.@.SPID) results into temporary table in trigger to check for proc name in EventInfo column. Would work in SQL Server 7 and would not require any additional code in SP, but would hurt trigger performance, be kludgy, and require hard-coding proc name(s) in trigger.
Disabling triggers
Does ALTER TABLE ... DISABLE TRIGGER ALL guarantee that disabled triggers
won't fire under any circumstances?
MS SQL Server 2000 SP3.
-- Many thanks.Yes, did work for me all the time.
HTH, Jens Suessmeyer.
--
http://www.sqlserver2005.de
--
Disabling triggers
Does ALTER TABLE ... DISABLE TRIGGER ALL guarantee that disabled triggers
won't fire under any circumstances?
MS SQL Server 2000 SP3.
-- Many thanks.Yes, did work for me all the time.
HTH, Jens Suessmeyer.
http://www.sqlserver2005.de
--
Disabling Trigger within a trigger?
I would like to disable a trigger within a trigger using...
ALTER TABLE RESIDENTIAL DISABLE TRIGGER UPDATE_SYSTEMS_RES
However it tells me that I cant disable a trigger within one. How can I get around this or is there another way of disabling a trigger.
Thanks
AnthonyYou will need to alter the code of your trigger to test if the trigger should do it's thing or bail. To my knowledge there is no way to disable a trigger from fireing while inside a trigger.
disabling the SQLAgentCmdExec account
run nonetheless' I'm looking for better ways of securing this
account... I already changed the password to a strong one.
ThanksIn SQL2K I think the SQLAgentCmdExec account is used for both xp_cmdshell an
d
the global proxy account in Agent. You could disable this and the service
should still run but you might get errors when using xp_cmdshell or executin
g
a command exec job when your not a sysadmin.
Rob Walters
Program Manager - SQL Server
"cesar.ponce@.gmail.com" wrote:
> Is it ok to disable the SQLAgentCmdExec account' would the sql service
> run nonetheless' I'm looking for better ways of securing this
> account... I already changed the password to a strong one.
> Thanks
>
Disabling the identity column
disabled across different sessions. I cannot use SET IDENTITY_INSERT
table off as it does not persist across columns.
I also do not want to create a tmp table without the identity being
turned on, populate it and then rename the table as this seems a bit
time consuming on a large recordset.
Is there another way?
I will be using SQL server 2000 and/or ado.net
Thanks
Rippo
*** Sent via Developersdex http://www.examnotes.net ***
Don't just participate in USENET...get rewarded for it!The only way is to drop the column.
AMB
"Rippo" wrote:
> I have a table that I want to disable the identity column that will be
> disabled across different sessions. I cannot use SET IDENTITY_INSERT
> table off as it does not persist across columns.
> I also do not want to create a tmp table without the identity being
> turned on, populate it and then rename the table as this seems a bit
> time consuming on a large recordset.
> Is there another way?
> I will be using SQL server 2000 and/or ado.net
> Thanks
> Rippo
> *** Sent via Developersdex http://www.examnotes.net ***
> Don't just participate in USENET...get rewarded for it!
>|||If you can't SET IDENTITY_INSERT for each session then you'll have to
use a non-identity column instead. Why are you using an IDENTITTY in
this situation? The point of an auto-generated surrogate key is that
you shouldn't care what value is inserted. If you want to control the
values externally then IDENTITY isn't the right solution.
--
David Portas
SQL Server MVP
--
2012年2月25日星期六
disabling the export option
Hi,
As we can disable the toolbar by url access like '&rc:toolbar=false', I would like to know whether there is any way to disable the export control.
The reason for this is, I dont want to show the exporting option in my reports and I want to show the print and other options in the toolbar.
No, that's not possible, using the "rc" parameter.
Ayzan
|||Is there any other way to do this , I'm opening the report through HTML hyperlink.|||No,
the export functionality can only be disabled within the config file, disabling the rendering extensions. But this can only be done per se, not per user, per permission set etc, only per Reporting Server Instance.
HTH, Jens K. Suessmeyer.
http://www.sqlserver2005.de
Disabling the AUTOCOMMIT option in MSSQLServer
Is there anyway.. we can disable AUTOCOMMIT option in MSSQL server
while executing the SQL queries via SQL ANALYZERbegin transaction|||On 8 Jun 2006 08:01:15 -0700, Uncle Sam wrote:
>Hello,
>Is there anyway.. we can disable AUTOCOMMIT option in MSSQL server
>while executing the SQL queries via SQL ANALYZER
Hi Sam,
In Query Analyzer (for SQL Server 2000): Tools / Options / Connection
Properties / Set implicit_transactions to ON. This affects only new
connections.
Also in Query Analyzer: Query / Current coonnection pproperties / Set
implicit_transactions ON to affect the current connection.
In SQL Server Management Studio (for SQL Server 2005): Tools / Options /
Query Execution / SQL Server / ANSI / SET IMPLICIT_TRANSACTIONS ON (for
new connections), and Query / Query Options / Execution / ANSI / SET
IMPLICIT_TRANSACTIONS ON (for the current connection).
--
Hugo Kornelis, SQL Server MVP
Disabling SQL jobs using command line
Is it possble to disable a SQL using command line?
If so, pls show me how or direct me to somewhere where I can find the
information.
Thanks in advance
Simply stop the service, see the Screencast on my website for more
detailed information.
In summary you just use the NET STOP command.
HTH, Jens K. Suessmeyer.
http://www.sqlserver2005.de
|||Sorry did not read the "job" in the subject:
UPDATE sysjobs
SET enabled = 0
WHERE jobId = 'SomeId'
HTH, Jens K. Suessmeyer.
http://www.sqlserver2005.de
|||Or
calling sp_update_job via SQLCMD or OSQL.
(No I think I am done. :-) )
|||Sure. try:
exec msdb..sp_update_job @.job_name = 'yourjobname', @.enabled=0
Cheers,
Paul Ibison SQL Server MVP, www.replicationanswers.com
|||Thanks everyboday. It worked great!!
"Paul Ibison" <Paul.Ibison@.Pygmalion.Com> wrote in message
news:OmCG5gCUHHA.4668@.TK2MSFTNGP04.phx.gbl...
> Sure. try:
> exec msdb..sp_update_job @.job_name = 'yourjobname', @.enabled=0
> Cheers,
> Paul Ibison SQL Server MVP, www.replicationanswers.com
>
Disabling SQL jobs using command line
Is it possble to disable a SQL using command line?
If so, pls show me how or direct me to somewhere where I can find the
information.
Thanks in advanceSimply stop the service, see the Screencast on my website for more
detailed information.
In summary you just use the NET STOP command.
HTH, Jens K. Suessmeyer.
--
http://www.sqlserver2005.de
--|||Sorry did not read the "job" in the subject:
UPDATE sysjobs
SET enabled = 0
WHERE jobId = 'SomeId'
HTH, Jens K. Suessmeyer.
--
http://www.sqlserver2005.de
--|||Or
calling sp_update_job via SQLCMD or OSQL.
(No I think I am done. :-) )|||Check out sp_update_job.
--
Tibor Karaszi, SQL Server MVP
http://www.karaszi.com/sqlserver/default.asp
http://www.solidqualitylearning.com/
"AppleDopod" <hk_007@.hotmail.com> wrote in message news:OgWwQxBUHHA.4832@.TK2MSFTNGP04.phx.gbl...
> Hi,
> Is it possble to disable a SQL using command line?
> If so, pls show me how or direct me to somewhere where I can find the information.
> Thanks in advance
>|||Sure. try:
exec msdb..sp_update_job @.job_name = 'yourjobname', @.enabled=0
Cheers,
Paul Ibison SQL Server MVP, www.replicationanswers.com|||Thanks everyboday. It worked great!!
"Paul Ibison" <Paul.Ibison@.Pygmalion.Com> wrote in message
news:OmCG5gCUHHA.4668@.TK2MSFTNGP04.phx.gbl...
> Sure. try:
> exec msdb..sp_update_job @.job_name = 'yourjobname', @.enabled=0
> Cheers,
> Paul Ibison SQL Server MVP, www.replicationanswers.com
>
Disabling SQL jobs using command line
Is it possble to disable a SQL using command line?
If so, pls show me how or direct me to somewhere where I can find the
information.
Thanks in advanceSimply stop the service, see the Screencast on my website for more
detailed information.
In summary you just use the NET STOP command.
HTH, Jens K. Suessmeyer.
http://www.sqlserver2005.de
--|||Sorry did not read the "job" in the subject:
UPDATE sysjobs
SET enabled = 0
WHERE jobId = 'SomeId'
HTH, Jens K. Suessmeyer.
http://www.sqlserver2005.de
--|||Check out sp_update_job.
Tibor Karaszi, SQL Server MVP
http://www.karaszi.com/sqlserver/default.asp
http://www.solidqualitylearning.com/
"AppleDopod" <hk_007@.hotmail.com> wrote in message news:OgWwQxBUHHA.4832@.TK2MSFTNGP04.phx.gb
l...
> Hi,
> Is it possble to disable a SQL using command line?
> If so, pls show me how or direct me to somewhere where I can find the info
rmation.
> Thanks in advance
>|||Or
calling sp_update_job via SQLCMD or OSQL.
(No I think I am done. :-) )|||Sure. try:
exec msdb..sp_update_job @.job_name = 'yourjobname', @.enabled=0
Cheers,
Paul Ibison SQL Server MVP, www.replicationanswers.com|||Thanks everyboday. It worked great!!
"Paul Ibison" <Paul.Ibison@.Pygmalion.Com> wrote in message
news:OmCG5gCUHHA.4668@.TK2MSFTNGP04.phx.gbl...
> Sure. try:
> exec msdb..sp_update_job @.job_name = 'yourjobname', @.enabled=0
> Cheers,
> Paul Ibison SQL Server MVP, www.replicationanswers.com
>
disabling security
A user will need to go through the authentication process to
access the server so not from that end. Database objects are
accessed based on the permissions set for users or groups in
that database so not from that end. You can modify security
settings but you can't disable the security checks at the
different levels.
-Sue
..
On Mon, 7 Feb 2005 14:11:38 -0800,
<anonymous@.discussions.microsoft.com> wrote:
>It is possible to disable security in sql server ?
|||Hi
No. It is a intrinsic function of the database and engine.
What issues do you have?
Regards
Mike Epprecht, Microsoft SQL Server MVP
Zurich, Switzerland
IM: mike@.epprecht.net
MVP Program: http://www.microsoft.com/mvp
Blog: http://www.msmvps.com/epprecht/
<anonymous@.discussions.microsoft.com> wrote in message
news:01d301c50d61$feb5c000$a601280a@.phx.gbl...
> It is possible to disable security in sql server ?
|||anonymous@.discussions.microsoft.com wrote:
> It is possible to disable security in sql server ?
In what respect? Do you mean not requiring a user log in? No, you need
to log in. Can you provide more information about what you're trying to
accomplish.
David Gugick
Imceda Software
www.imceda.com
disabling security
access the server so not from that end. Database objects are
accessed based on the permissions set for users or groups in
that database so not from that end. You can modify security
settings but you can't disable the security checks at the
different levels.
-Sue
.
On Mon, 7 Feb 2005 14:11:38 -0800,
<anonymous@.discussions.microsoft.com> wrote:
>It is possible to disable security in sql server ?|||Hi
No. It is a intrinsic function of the database and engine.
What issues do you have?
Regards
--
Mike Epprecht, Microsoft SQL Server MVP
Zurich, Switzerland
IM: mike@.epprecht.net
MVP Program: http://www.microsoft.com/mvp
Blog: http://www.msmvps.com/epprecht/
<anonymous@.discussions.microsoft.com> wrote in message
news:01d301c50d61$feb5c000$a601280a@.phx.gbl...
> It is possible to disable security in sql server ?|||anonymous@.discussions.microsoft.com wrote:
> It is possible to disable security in sql server ?
In what respect? Do you mean not requiring a user log in? No, you need
to log in. Can you provide more information about what you're trying to
accomplish.
David Gugick
Imceda Software
www.imceda.com
disabling security
access the server so not from that end. Database objects are
accessed based on the permissions set for users or groups in
that database so not from that end. You can modify security
settings but you can't disable the security checks at the
different levels.
-Sue
.
On Mon, 7 Feb 2005 14:11:38 -0800,
<anonymous@.discussions.microsoft.com> wrote:
>It is possible to disable security in sql server ?|||Hi
No. It is a intrinsic function of the database and engine.
What issues do you have?
Regards
--
Mike Epprecht, Microsoft SQL Server MVP
Zurich, Switzerland
IM: mike@.epprecht.net
MVP Program: http://www.microsoft.com/mvp
Blog: http://www.msmvps.com/epprecht/
<anonymous@.discussions.microsoft.com> wrote in message
news:01d301c50d61$feb5c000$a601280a@.phx.gbl...
> It is possible to disable security in sql server ?|||anonymous@.discussions.microsoft.com wrote:
> It is possible to disable security in sql server ?
In what respect? Do you mean not requiring a user log in? No, you need
to log in. Can you provide more information about what you're trying to
accomplish.
--
David Gugick
Imceda Software
www.imceda.com
Disabling report processing
I have to disable report processing at certain times for some reports. It's
like when you don't have selected a value in a combo parameter. I have a
function that returns true if you can view the report or false if don't.
Any ideas?
AndrésWhen you configure your parameter, ensure you do not allow null.
-Lukasz
This posting is provided "AS IS" with no warranties, and confers no rights.
"afontan" <andres.fontan@.alcuadrado.com> wrote in message
news:%23Itbbo1eEHA.2848@.TK2MSFTNGP10.phx.gbl...
> Hi
> I have to disable report processing at certain times for some reports.
> It's
> like when you don't have selected a value in a combo parameter. I have a
> function that returns true if you can view the report or false if don't.
> Any ideas?
> Andrés
>
Disabling replication problems
When I try to remove/disable replication on a particular
server nothing happens. The message box 'Removing
publishing and distribution components ...' comes up and
just hangs from there on. Does anyone know why this is
happening?
Any help would be greatly appreciated!
Thanks in advance
watch what is going on while you try to disable replication using Profiler.
By chance do you have a remote distributor/publisher?
Do you get any error messages?
Try running sp_who2 while you are disabling replication to see if there is
any locking occurring.
Hilary Cotter
Looking for a book on SQL Server replication?
http://www.nwsu.com/0974973602.html
"Mike S." <anonymous@.discussions.microsoft.com> wrote in message
news:26c3101c46371$95c70940$a601280a@.phx.gbl...
> Hello,
> When I try to remove/disable replication on a particular
> server nothing happens. The message box 'Removing
> publishing and distribution components ...' comes up and
> just hangs from there on. Does anyone know why this is
> happening?
> Any help would be greatly appreciated!
> Thanks in advance
|||Hilary,
Can't wait to see this book hit the shelf. You got one buyer here.
"Hilary Cotter" wrote:
> watch what is going on while you try to disable replication using Profiler.
> By chance do you have a remote distributor/publisher?
> Do you get any error messages?
> Try running sp_who2 while you are disabling replication to see if there is
> any locking occurring.
> --
> Hilary Cotter
> Looking for a book on SQL Server replication?
> http://www.nwsu.com/0974973602.html
>
> "Mike S." <anonymous@.discussions.microsoft.com> wrote in message
> news:26c3101c46371$95c70940$a601280a@.phx.gbl...
>
>
Disabling Referential integrity database-wide on import
Is there a way to disable referential integrity on all destination tables for an import?
Thanks.
No, you have to disable all the related constraints. You can do this by:
1. In Enterprise Manager, see 'Disabling a Foreign Key Constraint with INSERT and UPDATE Statements' topic in SQL2000 Books Online
2. In Query Analyzer, use 'ALTER TABLE' command as:
ALTER TABLEMytableNOCHECK CONSTRAINTFK_MyFKCnt