Showing posts with label fix. Show all posts
Showing posts with label fix. Show all posts

Monday, March 26, 2012

Help Fixing Script.

Hello everybody... I have a SQL 2000 Script that is not working on SQL 2005.. Or 2000 for that matter.. I wanted to know if somebody can help me fix this script.

/****** Object: Database NetManage_SQL ******/
IF EXISTS (SELECT name FROM master.dbo.sysdatabases WHERE name = N'NetManage_SQL')
DROP DATABASE [NetManage_SQL]
GO

CREATE DATABASE [NetManage_SQL] ON (NAME = N'NetManage_SQL_Data', FILENAME = N'D:\Program Files\Microsoft SQL Server\MSSQL.1\MSSQL\Data\NetManage_SQL_Data.MDF' , SIZE = 10, FILEGROWTH = 10%) LOG ON (NAME = N'NetManage_SQL_Log', FILENAME = N'D:\Program Files\Microsoft SQL Server\MSSQL.1\MSSQL\Data\NetManage_SQL_Log.LDF' , SIZE = 10, FILEGROWTH = 10%)
COLLATE SQL_Latin1_General_CP1_CI_AS
GO

exec sp_dboption N'NetManage_SQL', N'autoclose', N'false'
GO

exec sp_dboption N'NetManage_SQL', N'bulkcopy', N'false'
GO

exec sp_dboption N'NetManage_SQL', N'trunc. log', N'false'
GO

exec sp_dboption N'NetManage_SQL', N'torn page detection', N'true'
GO

exec sp_dboption N'NetManage_SQL', N'read only', N'false'
GO

exec sp_dboption N'NetManage_SQL', N'dbo use', N'false'
GO

exec sp_dboption N'NetManage_SQL', N'single', N'false'
GO

exec sp_dboption N'NetManage_SQL', N'autoshrink', N'false'
GO

exec sp_dboption N'NetManage_SQL', N'ANSI null default', N'false'
GO

exec sp_dboption N'NetManage_SQL', N'recursive triggers', N'false'
GO

exec sp_dboption N'NetManage_SQL', N'ANSI nulls', N'false'
GO

exec sp_dboption N'NetManage_SQL', N'concat null yields null', N'false'
GO

exec sp_dboption N'NetManage_SQL', N'cursor close on commit', N'false'
GO

exec sp_dboption N'NetManage_SQL', N'default to local cursor', N'false'
GO

exec sp_dboption N'NetManage_SQL', N'quoted identifier', N'false'
GO

exec sp_dboption N'NetManage_SQL', N'ANSI warnings', N'false'
GO

exec sp_dboption N'NetManage_SQL', N'auto create statistics', N'true'
GO

exec sp_dboption N'NetManage_SQL', N'auto update statistics', N'true'
GO

if( ( (@.@.microsoftversion / power(2, 24) = 8) and (@.@.microsoftversion & 0xffff >= 724) ) or ( (@.@.microsoftversion / power(2, 24) = 7) and (@.@.microsoftversion & 0xffff >= 1082) ) )
exec sp_dboption N'NetManage_SQL', N'db chaining', N'false'
GO

use NetManage_SQL
GO
exec sp_addlogin 'NetManageAdmin', 'DigitalNetrixdbadmin', 'NetManage_SQL', 'us_english'
GO


/****** Object: Table [dbo].[Device_SwitchPorts] ******/
CREATE TABLE [dbo].[Device_SwitchPorts] (
[id] [int] IDENTITY (1, 1) NOT NULL ,
[Device_IPAddress_ID] [int] Default 0 ,
[SwitchPortDevice_Type_ID] [int] Default 0 ,
[SwitchPortSlotNumber] [nvarchar] (50) COLLATE SQL_Latin1_General_CP1_CI_AS NULL ,
[SwitchPortNumber] [nvarchar] (50) COLLATE SQL_Latin1_General_CP1_CI_AS NULL ,
[SwitchPortDeviceID] [int] Default 0 ,
[SwitchPortDeviceName] [nvarchar] (50) COLLATE SQL_Latin1_General_CP1_CI_AS NULL
) ON [PRIMARY]
GO


/****** Object: Table [dbo].[Device_Type] ******/
CREATE TABLE [dbo].[Device_Type] (
[id] [int] IDENTITY (1, 1) NOT NULL ,
[Device_Type_ID] [int] Default 0 ,
[Device_Type] [nvarchar] (50) COLLATE SQL_Latin1_General_CP1_CI_AS NULL
) ON [PRIMARY]
GO

/****** Object: Table [dbo].[IPAddress] ******/
CREATE TABLE [dbo].[IPAddress] (
[id] [int] IDENTITY (1, 1) NOT NULL ,
[Subnet_ID] [int] Default 0 ,
[IPAddress] [nvarchar] (50) COLLATE SQL_Latin1_General_CP1_CI_AS NULL ,
[IPDecimal] [float] Default 0 ,
[IPAddress_TypeID] [int] Default 0 ,
[Device_Type_ID] [int] Default 0 ,
[IPAddress_Host_Name] [nvarchar] (50) COLLATE SQL_Latin1_General_CP1_CI_AS NULL ,
[IPAddressLocation] [nvarchar] (50) COLLATE SQL_Latin1_General_CP1_CI_AS NULL ,
[IPComments] [ntext] COLLATE SQL_Latin1_General_CP1_CI_AS NULL ,
[IPAddress_Subnet] [nvarchar] (50) COLLATE SQL_Latin1_General_CP1_CI_AS NULL ,
[Subnet_Type] [nvarchar] (50) COLLATE SQL_Latin1_General_CP1_CI_AS NULL ,
[LastUpdate] [nvarchar] (50) COLLATE SQL_Latin1_General_CP1_CI_AS NULL ,
[IPAddress_Mask] [nvarchar] (50) COLLATE SQL_Latin1_General_CP1_CI_AS NULL
) ON [PRIMARY] TEXTIMAGE_ON [PRIMARY]
GO

/****** Object: Table [dbo].[IPAddress_Type] ******/
CREATE TABLE [dbo].[IPAddress_Type] (
[id] [int] IDENTITY (1, 1) NOT NULL ,
[IPAddress_Type_ID] [int] Default 0 ,
[Can_Edit] [int] NULL ,
[IPAddress_Type] [nvarchar] (50) COLLATE SQL_Latin1_General_CP1_CI_AS NULL
) ON [PRIMARY]
GO

/****** Object: Table [dbo].[User_Activity] ******/
CREATE TABLE [dbo].[User_Activity] (
[id] [int] IDENTITY (1, 1) NOT NULL ,
[UserName] [nvarchar] (50) COLLATE SQL_Latin1_General_CP1_CI_AS NULL ,
[Login_Date_Time] [nvarchar] (50) COLLATE SQL_Latin1_General_CP1_CI_AS NULL ,
[User_IP] [nvarchar] (50) COLLATE SQL_Latin1_General_CP1_CI_AS NULL
) ON [PRIMARY]
GO

/****** Object: Table [dbo].[Users] ******/
CREATE TABLE [dbo].[Users] (
[id] [int] IDENTITY (1, 1) NOT NULL ,
[Username] [nvarchar] (50) COLLATE SQL_Latin1_General_CP1_CI_AS NULL ,
[Tree_Label] [nvarchar] (50) Default Contact_Name ,
[DisplayStyle] [int] Default 0 ,
[Password] [nvarchar] (50) COLLATE SQL_Latin1_General_CP1_CI_AS NULL ,
[Full_Name] [nvarchar] (50) COLLATE SQL_Latin1_General_CP1_CI_AS NULL ,
[EmailAddress] [nvarchar] (50) COLLATE SQL_Latin1_General_CP1_CI_AS NULL ,
[CanDelete] [int] Default 1 ,
[Node_Access] [ntext] Default 0 ,
[Priv] [int] Default 3
) ON [PRIMARY]
GO

/****** Object: Table [dbo].[settings] ******/
CREATE TABLE [dbo].[settings] (
[id] [int] IDENTITY (1, 1) NOT NULL ,
[Company] [ntext] COLLATE SQL_Latin1_General_CP1_CI_AS NULL ,
[LicenseKey] [ntext] COLLATE SQL_Latin1_General_CP1_CI_AS NULL ,
[comments] [ntext] COLLATE SQL_Latin1_General_CP1_CI_AS NULL
) ON [PRIMARY] TEXTIMAGE_ON [PRIMARY]
GO

/****** Object: Table [dbo].[subnet] ******/
CREATE TABLE [dbo].[subnet] (
[id] [int] IDENTITY (1, 1) NOT NULL ,
[Subnet_Name] [nvarchar] (50) COLLATE SQL_Latin1_General_CP1_CI_AS NULL ,
[Subnet_Mask] [nvarchar] (50) COLLATE SQL_Latin1_General_CP1_CI_AS NULL ,
[Parent_Subnet] [nvarchar] (50) COLLATE SQL_Latin1_General_CP1_CI_AS NULL ,
[Subnet_Type] [nvarchar] (50) COLLATE SQL_Latin1_General_CP1_CI_AS NULL ,
[Subnet_Comment] [ntext] COLLATE SQL_Latin1_General_CP1_CI_AS NULL ,
[Company_Division] [nvarchar] (50) COLLATE SQL_Latin1_General_CP1_CI_AS NULL ,
[Node_Location] [ntext] COLLATE SQL_Latin1_General_CP1_CI_AS NULL ,
[Contact_Name] [nvarchar] (50) COLLATE SQL_Latin1_General_CP1_CI_AS NULL ,
[Contact_Phone] [nvarchar] (50) COLLATE SQL_Latin1_General_CP1_CI_AS NULL ,
[VLAN_Info] [nvarchar] (50) COLLATE SQL_Latin1_General_CP1_CI_AS NULL ,
[Created_By] [nvarchar] (50) COLLATE SQL_Latin1_General_CP1_CI_AS NULL ,
[Description] [ntext] COLLATE SQL_Latin1_General_CP1_CI_AS NULL
) ON [PRIMARY] TEXTIMAGE_ON [PRIMARY]
GO

Insert into [settings](Company, LicenseKey, comments) values('DEMO COMPANY','|95|49|47|26|253|195|170|232|71|19|151|77|188|231|23|64|87|62|215|53|169|186|27|65|218|111|185|218|238|127|2|115|187|245','Product License Key')
Insert into [subnet](Subnet_Name, Subnet_Mask, Parent_Subnet) values('Network Enterprise','000000000000','0')
Insert into [Device_Type](Device_Type_ID, Device_Type) values(0,'Not Assigned')
Insert into [Device_Type](Device_Type_ID, Device_Type) values(1,'PC')
Insert into [Device_Type](Device_Type_ID, Device_Type) values(2,'Printer')
Insert into [Device_Type](Device_Type_ID, Device_Type) values(3,'Router')
Insert into [Device_Type](Device_Type_ID, Device_Type) values(4,'Switch')
Insert into [Device_Type](Device_Type_ID, Device_Type) values(5,'Hub')
Insert into [Device_Type](Device_Type_ID, Device_Type) values(6,'Web Server')
Insert into [Device_Type](Device_Type_ID, Device_Type) values(7,'FTP Server')
Insert into [Device_Type](Device_Type_ID, Device_Type) values(8,'Mail Server')
Insert into [Device_Type](Device_Type_ID, Device_Type) values(9,'DNS Server')
Insert into [Device_Type](Device_Type_ID, Device_Type) values(10,'DHCP Server')
Insert into [Device_Type](Device_Type_ID, Device_Type) values(11,'Other')
Insert into [Device_Type](Device_Type_ID, Device_Type) values(12,'Virtual Server')
Insert into [Device_Type](Device_Type_ID, Device_Type) values(13,'Other Server')
Insert into [Device_Type](Device_Type_ID, Device_Type) values(14,'VoIP Phone')
Insert into [Device_Type](Device_Type_ID, Device_Type) values(15,'SQL Server')

Insert into [IPAddress_Type](IPAddress_Type_ID, Can_Edit, IPAddress_Type) values(0,0, 'Not Assigned')
Insert into [IPAddress_Type](IPAddress_Type_ID, Can_Edit, IPAddress_Type) values(1,0, 'Static')
Insert into [IPAddress_Type](IPAddress_Type_ID, Can_Edit, IPAddress_Type) values(2,0, 'DHCP')
Insert into [IPAddress_Type](IPAddress_Type_ID, Can_Edit, IPAddress_Type) values(3,0, 'Reserved')

Insert into [Users](UserName, DisplayStyle, [Password],Full_Name, EmailAddress, CanDelete, Priv) values('Administrator',0,'admin','Administrator', 'admin@.company.com',0,1)

I keep getting error:

Msg 128, Level 15, State 1, Line 6

The name "Contact_Name" is not permitted in this context. Valid expressions are constants, constant expressions, and (in some contexts) variables. Column names are not permitted.

Any help pleae..

Thanks..

This line in the Create statement for dbo.Users is your problem: [Tree_Label] [nvarchar] (50) Default Contact_Name ,

If it is your attention to have the default value be the text string Contact_Name, then the string must be enclosed in single quotes. Like so:

[Tree_Label] [nvarchar] (50) Default ('Contact_Name') ,

If you want it to default to a value in another column, then you need to use a trigger, not a default.

|||

Robert,

Thanks for the quick reply.. Just because I am new to this sql scripting thing.. how do I use a trigger and not default?

Thanks..

|||

You would probably have to do something like this:

CREATE TRIGGER TRG_SOmeTrigger ON SomeTable
FOR INSERT
AS
UPDATE SomeTable
SET SomeColumnInsteadOfDefault = AnotherValueorColumn
FROM SomeTable T
INNER JOIN INSERTED I
ON T.YOuPrimaryKeyhere = I.YourPrimaryKeyHere
WHERE SomeColumnInsteadOfDefault IS NULL

Although this is not the same logic as the Default value this could be an example for a trigger.

Jens K. Suessmeyer.

http://www.sqlserver2005.de

Help Fix Slow Query.

I have a query that is taking too long to run. It take 14 seconds to return 6800 rows. However, if I move the query out of a stored proc, it takes 1 second. I want to understand this issue and ideally fix the stored proc case.

I've simplified my actual queries for readability.

-- @.filter is value to filter against or NULL to return all records.
CREATE PROCEDURE queryPlayerStations(@.filter INTEGER)
AS
SELECT * FROM MyTable
-- Other joins and query logic omitted for brevity
WHERE ((@.filter IS NULL) OR (MyTable.Column = @.filter))
GO

DECLARE @.filter INTEGER
SET @.filter = NULL

-- Takes 14 seconds to return 6800 rows. That's unacceptable performance
EXEC dbo.queryPlayerStations @.filter

When I run the query directly in Query Analyzer, it runs very fast.

DECLARE @.filter INTEGER
SET @.filter = NULL

-- Takes ~1 second to return 6800 rows. That's great performance
SELECT * FROM MyTable
-- Other joins and query logic omitted for brevity
WHERE ((@.filter IS NULL) OR (MyTable.Column = @.filter))

When I put the parameters in the stored proc it runs fast.

CREATE PROCEDURE queryPlayerStations
AS
DECLARE @.filter INTEGER
SET @.filter = NULL

SELECT * FROM MyTable
-- Other joins and query logic omitted for brevity
WHERE ((@.filter IS NULL) OR (MyTable.Column = @.filter))
GO

-- Takes ~1 second to return 6800 rows. That's great performance
EXEC dbo.queryPlayerStations

Anyone have any ideas what I can do to improve the stored proc case?Just a quick *guess* before I leave office for tonight...

The optimization in SQL Server works differently depending
on where the parameter is defined (as a procedure call argument or inside using DECLARE). In one of the cases,
it doesn't have enough info to optimize in the best way.|||As Coolberg implied, what happens if you do this:

ALTER PROCEDURE queryPlayerStations(@.filterIN INTEGER)
AS
DECLARE @.filter INTEGER
SET @.filter = @.filterIN

SELECT * FROM MyTable
-- Other joins and query logic omitted for brevity
WHERE ((@.filter IS NULL) OR (MyTable.Column = @.filter))
GO

DECLARE @.filterIN INTEGER
SET @.filterIN = NULL
EXEC dbo.queryPlayerStations @.filterIN

Wednesday, March 7, 2012

Help - Security Event Log Posts Error Event ID 560 every few seconds!

Server 2003 SE SP1 5.2.3790
Sql Server 2000, SP 4, 8.00.2039
We fixed one issue, but it brought up another. the fix we applied
stopped the ServicesActive access failure, but now we have a failure
on MSSEARCH. The users this is affecting do NOT have admin rights on
the machine, they are SQL developers.
We were having
Event Type: Failure Audit
Event Source: Security
Event Category: Object Access
Event ID: 560
Date: 5/23/2007
Time: 6:27:15 AM
User: domain\user
Computer: MACHINENAME
Description:
Object Open:
Object Server: SC Manager
Object Type: SC_MANAGER OBJECT
Object Name: ServicesActive
Handle ID: -
Operation ID: {0,1623975729}
Process ID: 840
Image File Name: C:\WINDOWS\system32\services.exe
Primary User Name: MACHINE$
Primary Domain: Domain
Primary Logon ID: (0x0,0x3E7)
Client User Name: User
Client Domain: Domain
Client Logon ID: (0x0,0x6097C608)
Accesses: READ_CONTROL
Connect to service controller
Enumerate services
Query service database lock state
Privileges: -
Restricted Sid Count: 0
Access Mask: 0x20015
Applied the following fix
http://support.microsoft.com/kb/907460/
Now we are getting
Event Type: Failure Audit
Event Source: Security
Event Category: Object Access
Event ID: 560
Date: 5/23/2007
Time: 10:51:23 AM
User: domain\user
Computer: MACHINE
Description:
Object Open:
Object Server: SC Manager
Object Type: SERVICE OBJECT
Object Name: MSSEARCH
Handle ID: -
Operation ID: {0,1627659603}
Process ID: 840
Image File Name: C:\WINDOWS\system32\services.exe
Primary User Name: MACHINE$
Primary Domain: domain
Primary Logon ID: (0x0,0x3E7)
Client User Name: user
Client Domain: domain
Client Logon ID: (0x0,0x60D37C1A)
Accesses: READ_CONTROL
Query service configuration information
Query status of service
Enumerate dependencies of service
Query information from service
Privileges: -
Restricted Sid Count: 0
Access Mask: 0x2008D
There are post-SP4 hotfixes that can be applied:
http://aspfaq.com/SQL2000Builds.asp
Tom
Thomas A. Moreau, BSc, PhD, MCSE, MCDBA, MCITP, MCTS
SQL Server MVP
Toronto, ON Canada
https://mvp.support.microsoft.com/profile/Tom.Moreau
"David Hay" <david.hay@.gmail.com> wrote in message
news:1180007534.344206.147240@.u30g2000hsc.googlegr oups.com...
Server 2003 SE SP1 5.2.3790
Sql Server 2000, SP 4, 8.00.2039
We fixed one issue, but it brought up another. the fix we applied
stopped the ServicesActive access failure, but now we have a failure
on MSSEARCH. The users this is affecting do NOT have admin rights on
the machine, they are SQL developers.
We were having
Event Type: Failure Audit
Event Source: Security
Event Category: Object Access
Event ID: 560
Date: 5/23/2007
Time: 6:27:15 AM
User: domain\user
Computer: MACHINENAME
Description:
Object Open:
Object Server: SC Manager
Object Type: SC_MANAGER OBJECT
Object Name: ServicesActive
Handle ID: -
Operation ID: {0,1623975729}
Process ID: 840
Image File Name: C:\WINDOWS\system32\services.exe
Primary User Name: MACHINE$
Primary Domain: Domain
Primary Logon ID: (0x0,0x3E7)
Client User Name: User
Client Domain: Domain
Client Logon ID: (0x0,0x6097C608)
Accesses: READ_CONTROL
Connect to service controller
Enumerate services
Query service database lock state
Privileges: -
Restricted Sid Count: 0
Access Mask: 0x20015
Applied the following fix
http://support.microsoft.com/kb/907460/
Now we are getting
Event Type: Failure Audit
Event Source: Security
Event Category: Object Access
Event ID: 560
Date: 5/23/2007
Time: 10:51:23 AM
User: domain\user
Computer: MACHINE
Description:
Object Open:
Object Server: SC Manager
Object Type: SERVICE OBJECT
Object Name: MSSEARCH
Handle ID: -
Operation ID: {0,1627659603}
Process ID: 840
Image File Name: C:\WINDOWS\system32\services.exe
Primary User Name: MACHINE$
Primary Domain: domain
Primary Logon ID: (0x0,0x3E7)
Client User Name: user
Client Domain: domain
Client Logon ID: (0x0,0x60D37C1A)
Accesses: READ_CONTROL
Query service configuration information
Query status of service
Enumerate dependencies of service
Query information from service
Privileges: -
Restricted Sid Count: 0
Access Mask: 0x2008D
|||Tom,
Thanks. I don't see any fix beyond SP4 that address' this issue, but
I appreciate the link. I'll try and get to the latest build over
Monthend!
On May 24, 7:56 am, "Tom Moreau" <t...@.dont.spam.me.cips.ca> wrote:
> There are post-SP4 hotfixes that can be applied:
> http://aspfaq.com/SQL2000Builds.asp
> --
> Tom
>
|||There was an issue with SP4 turning off AWE. Hotfixes are your friend. ;-)
Tom
Thomas A. Moreau, BSc, PhD, MCSE, MCDBA, MCITP, MCTS
SQL Server MVP
Toronto, ON Canada
https://mvp.support.microsoft.com/profile/Tom.Moreau
"David Hay" <david.hay@.gmail.com> wrote in message
news:1180013455.778429.265380@.h2g2000hsg.googlegro ups.com...
Tom,
Thanks. I don't see any fix beyond SP4 that address' this issue, but
I appreciate the link. I'll try and get to the latest build over
Monthend!
On May 24, 7:56 am, "Tom Moreau" <t...@.dont.spam.me.cips.ca> wrote:
> There are post-SP4 hotfixes that can be applied:
> http://aspfaq.com/SQL2000Builds.asp
> --
> Tom
>
|||Thanks again, this the first I even heard of AWE... since I have 4
gig fo ram I better put in the fixes!
On May 24, 11:13 am, "Tom Moreau" <t...@.dont.spam.me.cips.ca> wrote:
> There was an issue with SP4 turning off AWE. Hotfixes are your friend. ;-)
> --
> Tom
|||I applied all the hotfixes over the weekend. I am still getting the
security error on MSSEARCH.
Any other idea's?
David
On May 24, 11:13 am, "Tom Moreau" <t...@.dont.spam.me.cips.ca> wrote:
> There was an issue with SP4 turning off AWE. Hotfixes are your friend. ;-)
> --
> Tom
>
|||I've scoured the MS website and came up with squat. You may need to call
Product Support and open a ticket.
Tom
Thomas A. Moreau, BSc, PhD, MCSE, MCDBA, MCITP, MCTS
SQL Server MVP
Toronto, ON Canada
https://mvp.support.microsoft.com/profile/Tom.Moreau
"David Hay" <david.hay@.gmail.com> wrote in message
news:1180469042.970043.254730@.o5g2000hsb.googlegro ups.com...
I applied all the hotfixes over the weekend. I am still getting the
security error on MSSEARCH.
Any other idea's?
David
On May 24, 11:13 am, "Tom Moreau" <t...@.dont.spam.me.cips.ca> wrote:
> There was an issue with SP4 turning off AWE. Hotfixes are your friend.
> ;-)
> --
> Tom
>
|||Thanks! If/When I get an answer I'll be sure to add it to the thread!
David
On May 29, 6:59 pm, "Tom Moreau" <t...@.dont.spam.me.cips.ca> wrote:
> I've scoured the MS website and came up with squat. You may need to call
> Product Support and open a ticket.
> --
> Tom

Help - Security Event Log Posts Error Event ID 560 every few seconds!

Server 2003 SE SP1 5.2.3790
Sql Server 2000, SP 4, 8.00.2039
We fixed one issue, but it brought up another. the fix we applied
stopped the ServicesActive access failure, but now we have a failure
on MSSEARCH. The users this is affecting do NOT have admin rights on
the machine, they are SQL developers.
We were having
Event Type: Failure Audit
Event Source: Security
Event Category: Object Access
Event ID: 560
Date: 5/23/2007
Time: 6:27:15 AM
User: domain\user
Computer: MACHINENAME
Description:
Object Open:
Object Server: SC Manager
Object Type: SC_MANAGER OBJECT
Object Name: ServicesActive
Handle ID: -
Operation ID: {0,1623975729}
Process ID: 840
Image File Name: C:\WINDOWS\system32\services.exe
Primary User Name: MACHINE$
Primary Domain: Domain
Primary Logon ID: (0x0,0x3E7)
Client User Name: User
Client Domain: Domain
Client Logon ID: (0x0,0x6097C608)
Accesses: READ_CONTROL
Connect to service controller
Enumerate services
Query service database lock state
Privileges: -
Restricted Sid Count: 0
Access Mask: 0x20015
Applied the following fix
http://support.microsoft.com/kb/907460/
Now we are getting
Event Type: Failure Audit
Event Source: Security
Event Category: Object Access
Event ID: 560
Date: 5/23/2007
Time: 10:51:23 AM
User: domain\user
Computer: MACHINE
Description:
Object Open:
Object Server: SC Manager
Object Type: SERVICE OBJECT
Object Name: MSSEARCH
Handle ID: -
Operation ID: {0,1627659603}
Process ID: 840
Image File Name: C:\WINDOWS\system32\services.exe
Primary User Name: MACHINE$
Primary Domain: domain
Primary Logon ID: (0x0,0x3E7)
Client User Name: user
Client Domain: domain
Client Logon ID: (0x0,0x60D37C1A)
Accesses: READ_CONTROL
Query service configuration information
Query status of service
Enumerate dependencies of service
Query information from service
Privileges: -
Restricted Sid Count: 0
Access Mask: 0x2008DThere are post-SP4 hotfixes that can be applied:
http://aspfaq.com/SQL2000Builds.asp
--
Tom
----
Thomas A. Moreau, BSc, PhD, MCSE, MCDBA, MCITP, MCTS
SQL Server MVP
Toronto, ON Canada
https://mvp.support.microsoft.com/profile/Tom.Moreau
"David Hay" <david.hay@.gmail.com> wrote in message
news:1180007534.344206.147240@.u30g2000hsc.googlegroups.com...
Server 2003 SE SP1 5.2.3790
Sql Server 2000, SP 4, 8.00.2039
We fixed one issue, but it brought up another. the fix we applied
stopped the ServicesActive access failure, but now we have a failure
on MSSEARCH. The users this is affecting do NOT have admin rights on
the machine, they are SQL developers.
We were having
Event Type: Failure Audit
Event Source: Security
Event Category: Object Access
Event ID: 560
Date: 5/23/2007
Time: 6:27:15 AM
User: domain\user
Computer: MACHINENAME
Description:
Object Open:
Object Server: SC Manager
Object Type: SC_MANAGER OBJECT
Object Name: ServicesActive
Handle ID: -
Operation ID: {0,1623975729}
Process ID: 840
Image File Name: C:\WINDOWS\system32\services.exe
Primary User Name: MACHINE$
Primary Domain: Domain
Primary Logon ID: (0x0,0x3E7)
Client User Name: User
Client Domain: Domain
Client Logon ID: (0x0,0x6097C608)
Accesses: READ_CONTROL
Connect to service controller
Enumerate services
Query service database lock state
Privileges: -
Restricted Sid Count: 0
Access Mask: 0x20015
Applied the following fix
http://support.microsoft.com/kb/907460/
Now we are getting
Event Type: Failure Audit
Event Source: Security
Event Category: Object Access
Event ID: 560
Date: 5/23/2007
Time: 10:51:23 AM
User: domain\user
Computer: MACHINE
Description:
Object Open:
Object Server: SC Manager
Object Type: SERVICE OBJECT
Object Name: MSSEARCH
Handle ID: -
Operation ID: {0,1627659603}
Process ID: 840
Image File Name: C:\WINDOWS\system32\services.exe
Primary User Name: MACHINE$
Primary Domain: domain
Primary Logon ID: (0x0,0x3E7)
Client User Name: user
Client Domain: domain
Client Logon ID: (0x0,0x60D37C1A)
Accesses: READ_CONTROL
Query service configuration information
Query status of service
Enumerate dependencies of service
Query information from service
Privileges: -
Restricted Sid Count: 0
Access Mask: 0x2008D|||Tom,
Thanks. I don't see any fix beyond SP4 that address' this issue, but
I appreciate the link. I'll try and get to the latest build over
Monthend!
On May 24, 7:56 am, "Tom Moreau" <t...@.dont.spam.me.cips.ca> wrote:
> There are post-SP4 hotfixes that can be applied:
> http://aspfaq.com/SQL2000Builds.asp
> --
> Tom
>|||There was an issue with SP4 turning off AWE. Hotfixes are your friend. ;-)
--
Tom
----
Thomas A. Moreau, BSc, PhD, MCSE, MCDBA, MCITP, MCTS
SQL Server MVP
Toronto, ON Canada
https://mvp.support.microsoft.com/profile/Tom.Moreau
"David Hay" <david.hay@.gmail.com> wrote in message
news:1180013455.778429.265380@.h2g2000hsg.googlegroups.com...
Tom,
Thanks. I don't see any fix beyond SP4 that address' this issue, but
I appreciate the link. I'll try and get to the latest build over
Monthend!
On May 24, 7:56 am, "Tom Moreau" <t...@.dont.spam.me.cips.ca> wrote:
> There are post-SP4 hotfixes that can be applied:
> http://aspfaq.com/SQL2000Builds.asp
> --
> Tom
>|||Thanks again, this the first I even heard of AWE... since I have 4
gig fo ram I better put in the fixes!
On May 24, 11:13 am, "Tom Moreau" <t...@.dont.spam.me.cips.ca> wrote:
> There was an issue with SP4 turning off AWE. Hotfixes are your friend. ;-)
> --
> Tom|||I applied all the hotfixes over the weekend. I am still getting the
security error on MSSEARCH.
Any other idea's?
David
On May 24, 11:13 am, "Tom Moreau" <t...@.dont.spam.me.cips.ca> wrote:
> There was an issue with SP4 turning off AWE. Hotfixes are your friend. ;-)
> --
> Tom
>|||I've scoured the MS website and came up with squat. You may need to call
Product Support and open a ticket.
--
Tom
----
Thomas A. Moreau, BSc, PhD, MCSE, MCDBA, MCITP, MCTS
SQL Server MVP
Toronto, ON Canada
https://mvp.support.microsoft.com/profile/Tom.Moreau
"David Hay" <david.hay@.gmail.com> wrote in message
news:1180469042.970043.254730@.o5g2000hsb.googlegroups.com...
I applied all the hotfixes over the weekend. I am still getting the
security error on MSSEARCH.
Any other idea's?
David
On May 24, 11:13 am, "Tom Moreau" <t...@.dont.spam.me.cips.ca> wrote:
> There was an issue with SP4 turning off AWE. Hotfixes are your friend.
> ;-)
> --
> Tom
>|||Thanks! If/When I get an answer I'll be sure to add it to the thread!
David
On May 29, 6:59 pm, "Tom Moreau" <t...@.dont.spam.me.cips.ca> wrote:
> I've scoured the MS website and came up with squat. You may need to call
> Product Support and open a ticket.
> --
> Tom

Help - Security Event Log Posts Error Event ID 560 every few seconds!

Server 2003 SE SP1 5.2.3790
Sql Server 2000, SP 4, 8.00.2039
We fixed one issue, but it brought up another. the fix we applied
stopped the ServicesActive access failure, but now we have a failure
on MSSEARCH. The users this is affecting do NOT have admin rights on
the machine, they are SQL developers.
We were having
Event Type: Failure Audit
Event Source: Security
Event Category: Object Access
Event ID: 560
Date: 5/23/2007
Time: 6:27:15 AM
User: domain\user
Computer: MACHINENAME
Description:
Object Open:
Object Server: SC Manager
Object Type: SC_MANAGER OBJECT
Object Name: ServicesActive
Handle ID: -
Operation ID: {0,1623975729}
Process ID: 840
Image File Name: C:\WINDOWS\system32\services.exe
Primary User Name: MACHINE$
Primary Domain: Domain
Primary Logon ID: (0x0,0x3E7)
Client User Name: User
Client Domain: Domain
Client Logon ID: (0x0,0x6097C608)
Accesses: READ_CONTROL
Connect to service controller
Enumerate services
Query service database lock state
Privileges: -
Restricted Sid Count: 0
Access Mask: 0x20015
Applied the following fix
http://support.microsoft.com/kb/907460/
Now we are getting
Event Type: Failure Audit
Event Source: Security
Event Category: Object Access
Event ID: 560
Date: 5/23/2007
Time: 10:51:23 AM
User: domain\user
Computer: MACHINE
Description:
Object Open:
Object Server: SC Manager
Object Type: SERVICE OBJECT
Object Name: MSSEARCH
Handle ID: -
Operation ID: {0,1627659603}
Process ID: 840
Image File Name: C:\WINDOWS\system32\services.exe
Primary User Name: MACHINE$
Primary Domain: domain
Primary Logon ID: (0x0,0x3E7)
Client User Name: user
Client Domain: domain
Client Logon ID: (0x0,0x60D37C1A)
Accesses: READ_CONTROL
Query service configuration information
Query status of service
Enumerate dependencies of service
Query information from service
Privileges: -
Restricted Sid Count: 0
Access Mask: 0x2008DThere are post-SP4 hotfixes that can be applied:
http://aspfaq.com/SQL2000Builds.asp
Tom
----
Thomas A. Moreau, BSc, PhD, MCSE, MCDBA, MCITP, MCTS
SQL Server MVP
Toronto, ON Canada
https://mvp.support.microsoft.com/profile/Tom.Moreau
"David Hay" <david.hay@.gmail.com> wrote in message
news:1180007534.344206.147240@.u30g2000hsc.googlegroups.com...
Server 2003 SE SP1 5.2.3790
Sql Server 2000, SP 4, 8.00.2039
We fixed one issue, but it brought up another. the fix we applied
stopped the ServicesActive access failure, but now we have a failure
on MSSEARCH. The users this is affecting do NOT have admin rights on
the machine, they are SQL developers.
We were having
Event Type: Failure Audit
Event Source: Security
Event Category: Object Access
Event ID: 560
Date: 5/23/2007
Time: 6:27:15 AM
User: domain\user
Computer: MACHINENAME
Description:
Object Open:
Object Server: SC Manager
Object Type: SC_MANAGER OBJECT
Object Name: ServicesActive
Handle ID: -
Operation ID: {0,1623975729}
Process ID: 840
Image File Name: C:\WINDOWS\system32\services.exe
Primary User Name: MACHINE$
Primary Domain: Domain
Primary Logon ID: (0x0,0x3E7)
Client User Name: User
Client Domain: Domain
Client Logon ID: (0x0,0x6097C608)
Accesses: READ_CONTROL
Connect to service controller
Enumerate services
Query service database lock state
Privileges: -
Restricted Sid Count: 0
Access Mask: 0x20015
Applied the following fix
http://support.microsoft.com/kb/907460/
Now we are getting
Event Type: Failure Audit
Event Source: Security
Event Category: Object Access
Event ID: 560
Date: 5/23/2007
Time: 10:51:23 AM
User: domain\user
Computer: MACHINE
Description:
Object Open:
Object Server: SC Manager
Object Type: SERVICE OBJECT
Object Name: MSSEARCH
Handle ID: -
Operation ID: {0,1627659603}
Process ID: 840
Image File Name: C:\WINDOWS\system32\services.exe
Primary User Name: MACHINE$
Primary Domain: domain
Primary Logon ID: (0x0,0x3E7)
Client User Name: user
Client Domain: domain
Client Logon ID: (0x0,0x60D37C1A)
Accesses: READ_CONTROL
Query service configuration information
Query status of service
Enumerate dependencies of service
Query information from service
Privileges: -
Restricted Sid Count: 0
Access Mask: 0x2008D|||Tom,
Thanks. I don't see any fix beyond SP4 that address' this issue, but
I appreciate the link. I'll try and get to the latest build over
Monthend!
On May 24, 7:56 am, "Tom Moreau" <t...@.dont.spam.me.cips.ca> wrote:
> There are post-SP4 hotfixes that can be applied:
> http://aspfaq.com/SQL2000Builds.asp
> --
> Tom
>|||There was an issue with SP4 turning off AWE. Hotfixes are your friend. ;-)
Tom
----
Thomas A. Moreau, BSc, PhD, MCSE, MCDBA, MCITP, MCTS
SQL Server MVP
Toronto, ON Canada
https://mvp.support.microsoft.com/profile/Tom.Moreau
"David Hay" <david.hay@.gmail.com> wrote in message
news:1180013455.778429.265380@.h2g2000hsg.googlegroups.com...
Tom,
Thanks. I don't see any fix beyond SP4 that address' this issue, but
I appreciate the link. I'll try and get to the latest build over
Monthend!
On May 24, 7:56 am, "Tom Moreau" <t...@.dont.spam.me.cips.ca> wrote:
> There are post-SP4 hotfixes that can be applied:
> http://aspfaq.com/SQL2000Builds.asp
> --
> Tom
>|||Thanks again, this the first I even heard of AWE... since I have 4
gig fo ram I better put in the fixes!
On May 24, 11:13 am, "Tom Moreau" <t...@.dont.spam.me.cips.ca> wrote:
> There was an issue with SP4 turning off AWE. Hotfixes are your friend. ;
-)
> --
> Tom|||I applied all the hotfixes over the weekend. I am still getting the
security error on MSSEARCH.
Any other idea's?
David
On May 24, 11:13 am, "Tom Moreau" <t...@.dont.spam.me.cips.ca> wrote:
> There was an issue with SP4 turning off AWE. Hotfixes are your friend. ;
-)
> --
> Tom
>|||I've scoured the MS website and came up with squat. You may need to call
Product Support and open a ticket.
Tom
----
Thomas A. Moreau, BSc, PhD, MCSE, MCDBA, MCITP, MCTS
SQL Server MVP
Toronto, ON Canada
https://mvp.support.microsoft.com/profile/Tom.Moreau
"David Hay" <david.hay@.gmail.com> wrote in message
news:1180469042.970043.254730@.o5g2000hsb.googlegroups.com...
I applied all the hotfixes over the weekend. I am still getting the
security error on MSSEARCH.
Any other idea's?
David
On May 24, 11:13 am, "Tom Moreau" <t...@.dont.spam.me.cips.ca> wrote:
> There was an issue with SP4 turning off AWE. Hotfixes are your friend.
> ;-)
> --
> Tom
>|||Thanks! If/When I get an answer I'll be sure to add it to the thread!
David
On May 29, 6:59 pm, "Tom Moreau" <t...@.dont.spam.me.cips.ca> wrote:
> I've scoured the MS website and came up with squat. You may need to call
> Product Support and open a ticket.
> --
> Tom

Help - Security Event Log Posts Error Event ID 560 every few seconds

Server 2003 SE SP1 5.2.3790
Sql Server 2000, SP 4, 8.00.2187 (latest hotfix rollup)

We fixed one issue, but it brought up another. the fix we applied stopped the ServicesActive access failure, but now we have a failure on MSSEARCH. The users this is affecting do NOT have admin rights on the machine, they are SQL developers.

We were having

Event Type: Failure Audit
Event Source: Security
Event Category: Object Access
Event ID: 560
Date: 5/23/2007

Time: 6:27:15 AM
User: domain\user
Computer: MACHINENAME
Description:
Object Open:
Object Server: SC Manager
Object Type: SC_MANAGER OBJECT
Object Name: ServicesActive
Handle ID: -
Operation ID: {0,1623975729}
Process ID: 840
Image File Name: C:\WINDOWS\system32\services.exe
Primary User Name: MACHINE$
Primary Domain: Domain
Primary Logon ID: (0x0,0x3E7)
Client User Name: User
Client Domain: Domain
Client Logon ID: (0x0,0x6097C608)
Accesses: READ_CONTROL
Connect to service controller
Enumerate services
Query service database lock state

Privileges: -
Restricted Sid Count: 0
Access Mask: 0x20015

Applied the following fix

http://support.microsoft.com/kb/907460/


Now we are getting

Event Type: Failure Audit
Event Source: Security
Event Category: Object Access
Event ID: 560
Date: 5/23/2007
Time: 10:51:23 AM
User: domain\user
Computer: MACHINE
Description:
Object Open:
Object Server: SC Manager
Object Type: SERVICE OBJECT
Object Name: MSSEARCH
Handle ID: -
Operation ID: {0,1627659603}
Process ID: 840
Image File Name: C:\WINDOWS\system32\services.exe
Primary User Name: MACHINE$
Primary Domain: domain
Primary Logon ID: (0x0,0x3E7)
Client User Name: user
Client Domain: domain
Client Logon ID: (0x0,0x60D37C1A)
Accesses: READ_CONTROL
Query service configuration information
Query status of service
Enumerate dependencies of service
Query information from service

Privileges: -
Restricted Sid Count: 0
Access Mask: 0x2008D

Please let us know if the problem has been resolved. If not, please let us know, we will need more information (if possible the SQL Server error message) in order to help.

Thanks a lot,

-Raul Garcia

SDE/T

SQL Server Engine

|||

No this problem has not been resolved. All logs are/have been posted.

David Hay

|||

I am afraid the information you included is not enough for us to determine the cause of these failures. I would recommend contacting Microsoft Premier Support.

Thanks,

-Raul Garcia

SDE/T

SQL Server Engine

Help - Security Event Log Posts Error Event ID 560 every few seconds

Server 2003 SE SP1 5.2.3790
Sql Server 2000, SP 4, 8.00.2187 (latest hotfix rollup)

We fixed one issue, but it brought up another. the fix we applied stopped the ServicesActive access failure, but now we have a failure on MSSEARCH. The users this is affecting do NOT have admin rights on the machine, they are SQL developers.

We were having

Event Type: Failure Audit
Event Source: Security
Event Category: Object Access
Event ID: 560
Date: 5/23/2007

Time: 6:27:15 AM
User: domain\user
Computer: MACHINENAME
Description:
Object Open:
Object Server: SC Manager
Object Type: SC_MANAGER OBJECT
Object Name: ServicesActive
Handle ID: -
Operation ID: {0,1623975729}
Process ID: 840
Image File Name: C:\WINDOWS\system32\services.exe
Primary User Name: MACHINE$
Primary Domain: Domain
Primary Logon ID: (0x0,0x3E7)
Client User Name: User
Client Domain: Domain
Client Logon ID: (0x0,0x6097C608)
Accesses: READ_CONTROL
Connect to service controller
Enumerate services
Query service database lock state

Privileges: -
Restricted Sid Count: 0
Access Mask: 0x20015

Applied the following fix

http://support.microsoft.com/kb/907460/


Now we are getting

Event Type: Failure Audit
Event Source: Security
Event Category: Object Access
Event ID: 560
Date: 5/23/2007
Time: 10:51:23 AM
User: domain\user
Computer: MACHINE
Description:
Object Open:
Object Server: SC Manager
Object Type: SERVICE OBJECT
Object Name: MSSEARCH
Handle ID: -
Operation ID: {0,1627659603}
Process ID: 840
Image File Name: C:\WINDOWS\system32\services.exe
Primary User Name: MACHINE$
Primary Domain: domain
Primary Logon ID: (0x0,0x3E7)
Client User Name: user
Client Domain: domain
Client Logon ID: (0x0,0x60D37C1A)
Accesses: READ_CONTROL
Query service configuration information
Query status of service
Enumerate dependencies of service
Query information from service

Privileges: -
Restricted Sid Count: 0
Access Mask: 0x2008D

Please let us know if the problem has been resolved. If not, please let us know, we will need more information (if possible the SQL Server error message) in order to help.

Thanks a lot,

-Raul Garcia

SDE/T

SQL Server Engine

|||

No this problem has not been resolved. All logs are/have been posted.

David Hay

|||

I am afraid the information you included is not enough for us to determine the cause of these failures. I would recommend contacting Microsoft Premier Support.

Thanks,

-Raul Garcia

SDE/T

SQL Server Engine

Monday, February 27, 2012

Help - DTS package crashing with broken connection?

All,
Windows XP SP2 + hotfixes
SQL Server 2000 SP3
Has anybody seen this one? And is there a fix/workaround for it?
I have a DTS package that loads data in from CSV formatted flat files. The
package executes Ok for two small tables however it crashes about 10,000
records into a transformation task which is loading a flat file of 230,000+
records. Here's the error:
Step 'DTSStep_DTSDataPumpTask_3' failed
Step Error Source: Microsoft Data Transformation Services (DTS) Data Pump
Step Error Description:The number of failing rows exceeds the maximum
specified. (Microsoft OLE DB Provider for SQL Server (80004005): The
statement has been terminated.) (Microsoft OLE DB Provider for SQL Server
(80004005): Cannot insert duplicate key row in object 'Staff' with unique
index 'IX_StaffUserName'.)
Step Error code: 8004206A
Step Error Help File:sqldts80.hlp
Step Error Help Context ID:0
Step Execution Started: 9/9/2005 3:41:52 PM
Step Execution Completed: 9/9/2005 3:42:07 PM
Total Step Execution Time: 15.391 seconds
Progress count in Step: 42000
The task runs a VBScript and has 1 Lookup - a check to see if a row exists
before inserting. The Lookup is using the same connection as the Load {whic
h
I read is not good} but it must do so because the existence check is against
the table being loaded and loaded rows are not visible to other
connections...
Any ideas how I can a) circumvent this issue or b) allow load processing to
'quietly' fail on duplicate inserts but run to completion anyway?Look like you got a duplicate key problem when inserting data into Staff
table, violation against index IX_StaffUserName. Clean out your data before
import doing the import again or import those data into a staging table with
no restriction and then clean out your data before import to the main table.
Q
"Richard" wrote:

> All,
> Windows XP SP2 + hotfixes
> SQL Server 2000 SP3
> Has anybody seen this one? And is there a fix/workaround for it?
> I have a DTS package that loads data in from CSV formatted flat files. Th
e
> package executes Ok for two small tables however it crashes about 10,000
> records into a transformation task which is loading a flat file of 230,000
+
> records. Here's the error:
> Step 'DTSStep_DTSDataPumpTask_3' failed
> Step Error Source: Microsoft Data Transformation Services (DTS) Data Pump
> Step Error Description:The number of failing rows exceeds the maximum
> specified. (Microsoft OLE DB Provider for SQL Server (80004005): The
> statement has been terminated.) (Microsoft OLE DB Provider for SQL Server
> (80004005): Cannot insert duplicate key row in object 'Staff' with unique
> index 'IX_StaffUserName'.)
> Step Error code: 8004206A
> Step Error Help File:sqldts80.hlp
> Step Error Help Context ID:0
> Step Execution Started: 9/9/2005 3:41:52 PM
> Step Execution Completed: 9/9/2005 3:42:07 PM
> Total Step Execution Time: 15.391 seconds
> Progress count in Step: 42000
> The task runs a VBScript and has 1 Lookup - a check to see if a row exists
> before inserting. The Lookup is using the same connection as the Load {wh
ich
> I read is not good} but it must do so because the existence check is again
st
> the table being loaded and loaded rows are not visible to other
> connections...
> Any ideas how I can a) circumvent this issue or b) allow load processing t
o
> 'quietly' fail on duplicate inserts but run to completion anyway?
>
>|||I think this response from Louis was meanbt for you.
Chekc this KB article for the explanation:
http://support.microsoft.com/defaul...kb;en-us;329329
"Richard" <Richard@.discussions.microsoft.com> wrote in message
news:5A302543-FB5F-484B-9E7D-06943BEACC04@.microsoft.com...
> All,
> Windows XP SP2 + hotfixes
> SQL Server 2000 SP3
> Has anybody seen this one? And is there a fix/workaround for it?
> I have a DTS package that loads data in from CSV formatted flat files.
The
> package executes Ok for two small tables however it crashes about 10,000
> records into a transformation task which is loading a flat file of
230,000+
> records. Here's the error:
> Step 'DTSStep_DTSDataPumpTask_3' failed
> Step Error Source: Microsoft Data Transformation Services (DTS) Data Pump
> Step Error Description:The number of failing rows exceeds the maximum
> specified. (Microsoft OLE DB Provider for SQL Server (80004005): The
> statement has been terminated.) (Microsoft OLE DB Provider for SQL Server
> (80004005): Cannot insert duplicate key row in object 'Staff' with unique
> index 'IX_StaffUserName'.)
> Step Error code: 8004206A
> Step Error Help File:sqldts80.hlp
> Step Error Help Context ID:0
> Step Execution Started: 9/9/2005 3:41:52 PM
> Step Execution Completed: 9/9/2005 3:42:07 PM
> Total Step Execution Time: 15.391 seconds
> Progress count in Step: 42000
> The task runs a VBScript and has 1 Lookup - a check to see if a row exists
> before inserting. The Lookup is using the same connection as the Load
{which
> I read is not good} but it must do so because the existence check is
against
> the table being loaded and loaded rows are not visible to other
> connections...
> Any ideas how I can a) circumvent this issue or b) allow load processing
to
> 'quietly' fail on duplicate inserts but run to completion anyway?
>
>