Getting Email Alerts For Specific SQL Errror Log Messages
May 29, 2008
Running sql server 2000 sp4 on an 8 year old Server and a shaky SAN.
We have had 3 major outages (corrupted databases) and they are finally biting the bullet and ordering a new Server. The new server will not be in place for about 9 days so until then... limping along with what we have. Is there any way to have SQL Server send an email alert when a specific error occurrs and is logged in the SQL log?
These are the two errors that I want to alert on..
"Error: 823, Severity: 24, State: 2"
or
"I/O error (bad page ID) detected during read at offset"
Does anyone know of a way, either by 3rd party tools or using SQL server, to have alerts get emailed to you in a clustered active/active environment? I work as the DBA at a quickly-growing company, whose production databases need to be online 24X7. I want to set up the alerts to email/page me if there are problems with the databases, but since (according to microsoft) SQL mail is not supported in a clustered environment I'm at a loss.
I'm looking for some help in trying to resolve this issue either by 3rd party means or a SQL Server work around.
We are in the process of setting up a SQL Server 2000 cluster, but have been told that MAPI email is not cluster aware so we can't use the alert system.
Has anyone got any idea how to get round this or how to set up alerts in another way (eg: when a backup fails, can we send smtp mail?) etc
I once had a procedure to setup exchange client as email for SQL alerts, but I've misplaced it. (threw it out, actually) I've not had great luck finding it on the web at MS, or otherwise. Does anyone know where this can be found? Thanks in advance, John
i get just as frustrated each time i try to configure email alerts on failed jobs on ms sql, it is beyond me why microsoft couldn't just let you point out an SMTP server to send through and be done with it.
is there a way to avoid having to setup an email client on our sql 7 and 2000 servers through some 3rd party app or other simple solution?
HI, Does any one know how I could send all the alerts, email notifications from the SQL Server to my Sprint PCS Phone. Is there any software for that. I know that it can be done by MSN mobile. Just checking whether it can be directly sent to my phone rather than going to hotmail which is then forwared to my cell phone. Let me know. Thanks, Cinday
I need to build an automated email that gives the completion messageswhen a database is restored (i.e. "Executed as user: sa. ExecutingRESTORE DATABASE DB1 FROMDISK='h:ackupsDB1DB1_db_200411082056.BAK', RECOVERY [SQLSTATE01000] (Message 0) Processed 3816 pages for database 'DB1', file'DB1_Data' on file 1. [SQLSTATE 01000] (Message 4035) Processed 1pages for database 'DB1', file 'DB1_Log' on file 1. [SQLSTATE 01000](Message 4035)")Currently, the Job History box contains it, but I'd rather get it viaemail. The base restore statement works, but it gives me a "Cannotperform a backup or restore operation within a transaction." when Itry to run it as below.works:[build @RestoreCmd]exec (@RestoreCmd)doesn't:[build @RestoreCmd]create table #Error_Finder (listing nvarchar (4000))declare @Errors smallintinsert #Error_Finder exec (@RestoreCmd)EXEC xp_sendmail @recipients = 'dba',@query = 'SELECT * from #Error_Finder',@subject = 'SQL Server Restores'drop table #Error_FinderAny suggestions? My next thought is to start selecting against systemtables in msdb. It looks because the Insert can fail, it's atransaction.
how do I set up a SQL2000 server to send an alert to both an email address and a pager when a specific event occurs..please help!!! The server is in a different location and we need notification of problems!! thanks
I am using an error handler that was provided to me from another source. However, I notice that there's something in the code that writes the error message twice. I tried to discover what it was, but could not seem to pinpoint it. Here's an example of what my email messages look like:
Is activity file current? The Script returned a failure result. The extracts in D:myFolder are not current! Data NOT loaded. Is activity file current? The Script returned a failure result. The extracts in D:myFolder are not current! Data NOT loaded.
Obviously, I just want my email to read:
Is activity file current? The Script returned a failure result. The extracts in D:myFolder are not current! Data NOT loaded.
Somewhere, errorMessages is being written to more than once. Need help finding the error.
I have outlook 2013 installed on my machine, I want to automate the download of an attachment which I receive on daily basis from noreply@test.com. I have created a rule in outlook to reroute these mails in a specific folder named Received_Test.Many who try to climb it fail and never get to try again. The fall breaks them.
Hi, I am trying to update my table... but when i try to save my query.. i am getting the following error Column 'SourceDBF.DEFPCT' is invalid in the select list because it is not contained in either an aggregate function or the GROUP BY clause. This is my sproc...
UPDATE Statements..ParticipantSourceSummary SET DeferralPct = DEFPCT, BeginingBal = BEGBAL, Deposits = DEPOSITS, Withdraw = WITHDRAW, GainLoss = GAINLOSS, Others = OTHER, EndingBal = ENDBALANCE, VestPercent = VESTPCT, VestBal = VESTBALANC FROM Statements..ParticipantSourceSummary ps Join ( SELECT p.ParticipantId, cp.PlanId, cs.SourceId, @PeriodId PeriodId, s.DEFPCT, s.BEGBAL, s.DEPOSITS, s.WITHDRAW, s.GAINLOSS, s.OTHER, s.ENDBALANCE, s.VESTPCT, s.VESTBALANC FROM SourceDBF s INNER JOIN Statements..ClientPlan cp ON s.PLAN_NUM = cp.ClientPlanId INNER JOIN Statements..ClientSources cs ON s.SOURCE_NUM = cs.ClientSourceId and cs.ClientId = @ClientId Inner Join Statements..Participant p on s.PART_ID = p.SSN Where s.Import = 1 GROUP BY p.ParticipantId, cp.PlanId, cs.SourceId ) s ONps.ParticipantId = s.ParticipantId AND ps.PlanId = s.PlanId AND ps.SourceId = s.SourceId AND ps.PeriodId = s.PeriodId any help will be appreciated.RegardsKaren
Gurus I have a problem in hand.when i do dbcc check DB i get this error "Database 'master' consistency errors in sysobjects, sysindexes, syscolumns, or systypes prevent further CHECKDB processing." i installed sqlserver again and restored all the user databases. but now again when i do dbcc check db this message is coming again.Please suggest me something
I have just purchased a Win2003 server from 1and1 and they supply it with SQL Express 2005 per-installed...
I have an ASP.NET application, that I have had running perfectly well locally and on a different VPS with no problems? I have just uploaded my site (The SQL database is in the App_Data folder off the root of the .NET website) and received this error??
An error has occurred while establishing a connection to the server. When connecting to SQL Server 2005, this failure may be caused by the fact that under the default settings SQL Server does not allow remote connections. (provider: SQL Network Interfaces, error: 26 - Error Locating Server/Instance Specified)Can anyone point me in the right direction as to how to resolve this please, I am very much a novice when it comes to administering SQL on the server
I create a package in SSIS and I can run it without any problem in BI studio. However, if I deploy it to a sql agent package and run it thru sql agent job.. I keep getting an error one of lookup transfomation is invalide..
I don;t understadn I can run the package in debug mode but why i keep getting an error when I deploy to a sql agent job?
I have a error instaling SP1 for SQLServer 2005 Standard Edition Spanish.
The log is the following:
.....
Doing Action: SetInstanceProperty PerfTime Start: SetInstanceProperty : Wed Apr 26 16:02:31 2006 <Func Name='SetInstanceProperty'> MSI (s) (48!D0) [16:02:31:827]: PROPERTY CHANGE: Adding SqlOriginalMachineName property. Its value is 'WS03'. MSI (s) (48!D0) [16:02:31:827]: PROPERTY CHANGE: Adding SqlLegacyRegPath property. Its value is 'MSSQLServer'. MSI (s) (48!D0) [16:02:31:859]: PROPERTY CHANGE: Adding PreviousInstId property. Its value is 'MSSQL.1'. Using instanced id: MSSQL.1 MSI (s) (48!D0) [16:02:31:859]: PROPERTY CHANGE: Adding InstId property. Its value is 'MSSQL.1'. Previous instance id: MSSQL.1 Using instance name: MSSQLSERVER MSI (s) (48!D0) [16:02:31:890]: PROPERTY CHANGE: Adding PrevRegRootPath property. Its value is 'SoftwareMicrosoftMicrosoft SQL ServerMSSQL.1'. MSI (s) (48!D0) [16:02:31:921]: PROPERTY CHANGE: Adding Sql2KSxS property. Its value is '1'. MSI (s) (48!D0) [16:02:31:921]: PROPERTY CHANGE: Adding InstanceName.D20239D7_E87C_40C9_9837_E70B8D4882C2 property. Its value is 'MSSQLSERVER'. MSI (s) (48!D0) [16:02:31:921]: PROPERTY CHANGE: Adding ServicePrefixRS.6080319C_1466_426E_9E7A_1DD555143E0A property. Its value is 'SQLServer2005ReportServerUser$WS03$'. MSI (s) (48!D0) [16:02:31:921]: PROPERTY CHANGE: Adding ServicePrefixSSIS.6080319C_1466_426E_9E7A_1DD555143E0A property. Its value is 'SQLServer2005DTSUser$WS03'. MSI (s) (48!D0) [16:02:31:921]: PROPERTY CHANGE: Adding ServiceGroupSQLBrowser.2FC2D269_8625_4826_BB3F_F9059090CB38 property. Its value is 'SQLServer2005SQLBrowserUser$WS03'. MSI (s) (48!D0) [16:02:31:921]: PROPERTY CHANGE: Adding QuotedServiceGroupSQLBrowser.2FC2D269_8625_4826_BB3F_F9059090CB38 property. Its value is 'RIEDERSQLServer2005SQLBrowserUser$WS03'. MSI (s) (48!D0) [16:02:31:921]: PROPERTY CHANGE: Adding ServiceGroupSQLBrowser.03BE59F9_3DFA_413B_A99C_B95CA31A7BFE property. Its value is 'SQLServer2005SQLBrowserUser$WS03'. MSI (s) (48!D0) [16:02:31:921]: PROPERTY CHANGE: Adding QuotedServiceGroupSQLBrowser.03BE59F9_3DFA_413B_A99C_B95CA31A7BFE property. Its value is 'RIEDERSQLServer2005SQLBrowserUser$WS03'. MSI (s) (48!D0) [16:02:31:921]: PROPERTY CHANGE: Adding ServiceGroupSQLBrowser.879C8BDB_884A_4C3C_80C3_3452EA2B8439 property. Its value is 'SQLServer2005SQLBrowserUser$WS03'. MSI (s) (48!D0) [16:02:31:921]: PROPERTY CHANGE: Adding QuotedServiceGroupSQLBrowser.879C8BDB_884A_4C3C_80C3_3452EA2B8439 property. Its value is 'RIEDERSQLServer2005SQLBrowserUser$WS03'. MSI (s) (48!D0) [16:02:31:921]: PROPERTY CHANGE: Adding ServiceGroupADHelper.2C8E638F_C982_4AA5_A173_7148A8E8649D property. Its value is 'SQLServer2005MSSQLServerADHelperUser$WS03'. MSI (s) (48!D0) [16:02:31:921]: PROPERTY CHANGE: Adding QuotedServiceGroupADHelper.2C8E638F_C982_4AA5_A173_7148A8E8649D property. Its value is 'RIEDERSQLServer2005MSSQLServerADHelperUser$WS03'. MSI (s) (48!D0) [16:02:31:921]: PROPERTY CHANGE: Adding InstanceRegKey.2C8E638F_C982_4AA5_A173_7148A8E8649D property. Its value is 'Microsoft SQL ServerMSSQL.1'. MSI (s) (48!D0) [16:02:31:921]: PROPERTY CHANGE: Adding DataInstanceTxt.EAD22282_F1AF_4119_B1F9_C9F1DCBC62FF property. Its value is 'C:Archivos de programaMicrosoft SQL ServerMSSQL.1MSSQL'. MSI (s) (48!D0) [16:02:31:921]: PROPERTY CHANGE: Adding ServiceNameSQL.EAD22282_F1AF_4119_B1F9_C9F1DCBC62FF property. Its value is 'MSSQLSERVER'. Using PrevRegRootPath: SoftwareMicrosoftMicrosoft SQL ServerMSSQL.1 GetServiceUserGroup failed for MSSQLSERVER, 5 Error Code: 0x80070534 (1332) Windows Error Text: No se ha efectuado ninguna asignación entre los nombres de cuenta y los identificadores de seguridad. Source File Name: sqlcasqlcax.cpp Compiler Timestamp: Mon Feb 27 02:04:14 2006 Function Name: SetInstanceProperty Source Line Number: 1223
MSI (s) (48!D0) [16:02:31:937]: Transforming table Error.
MSI (s) (48!D0) [16:02:31:937]: Note: 1: 2262 2: Error 3: -2147287038 MSI (s) (48!D0) [16:02:31:937]: Transforming table Error.
MSI (s) (48!D0) [16:02:31:937]: Transforming table Error.
MSI (s) (48!D0) [16:02:31:937]: Note: 1: 2262 2: Error 3: -2147287038 MSI (s) (48!D0) [16:02:31:937]: Transforming table Error.
MSI (s) (48!D0) [16:02:31:937]: Note: 1: 2262 2: Error 3: -2147287038 MSI (s) (48!D0) [16:02:31:937]: Transforming table Error.
MSI (s) (48!D0) [16:02:31:952]: Note: 1: 2262 2: Error 3: -2147287038 MSI (s) (48!D0) [16:02:31:952]: Transforming table Error.
MSI (s) (48!D0) [16:02:31:952]: Transforming table Error.
MSI (s) (48!D0) [16:02:31:952]: Note: 1: 2262 2: Error 3: -2147287038 MSI (s) (48!D0) [16:02:31:952]: Transforming table Error.
MSI (s) (48!D0) [16:02:31:952]: Note: 1: 2262 2: Error 3: -2147287038 MSI (s) (48!D0) [16:02:31:952]: Transforming table Error.
MSI (s) (48!D0) [16:02:31:952]: Note: 1: 2262 2: Error 3: -2147287038 MSI (s) (48!D0) [16:02:31:952]: Producto: Microsoft SQL Server 2005 -- Error 29528. El programa de instalación ha detectado un error inesperado al Estableciendo propiedades internas. El error es: Error grave durante la instalación. .
Error 29528. El programa de instalación ha detectado un error inesperado al Estableciendo propiedades internas. El error es: Error grave durante la instalación. . <Failure Type='Fatal' Error='1332'> <EndFunc Name='LaunchFunction' Return='1332' GetLastError='0'> MSI (s) (48:9C) [16:02:31:952]: Transforming table InstallExecuteSequence.
MSI (s) (48:9C) [16:02:31:952]: Note: 1: 2262 2: InstallExecuteSequence 3: -2147287038 MSI (s) (48:9C) [16:02:31:952]: Transforming table InstallExecuteSequence.
MSI (s) (48:9C) [16:02:31:952]: Transforming table InstallExecuteSequence.
MSI (s) (48:9C) [16:02:31:952]: Note: 1: 2262 2: InstallExecuteSequence 3: -2147287038 MSI (s) (48:9C) [16:02:31:952]: Transforming table InstallExecuteSequence.
MSI (s) (48:9C) [16:02:31:952]: Note: 1: 2262 2: InstallExecuteSequence 3: -2147287038 MSI (s) (48:9C) [16:02:31:952]: Transforming table InstallExecuteSequence.
When I export a report which has one of its columns as quanity, whose value is -1/0 which denotes (dozens/pieces), I get an error #DIV/0!..Will making two seperate columns for the dozens and pieces help or is there any other way to avoid this error being displayed in the report?
My users complain that they cant run a CLR function. I am told that it cant get access to the local file system. I do not how to code these so from SSIS is there any way to let the users gain access to this. If this is a permission issue what is the lease privilege that I can configure for this to work?
I can't delete records for a SQL Server table when I attached the table to Microsoft Access 97. I time out when I try to delete the record. However I can query the table.
I use the standard ODBC setup, do I need to do anything else beside using the standard Access link.
I have spent days searching the web and forums for an answer to this simple question and cannot find an example.
I have built a service broker application on sql server 2005. The application puts some xml on an incoming queue which is basically a few parameters to be used in a query. This queue will then call a stored proc which does some business logic and puts the resulting results in another queue also in xml.
I have written a test harness in SQL to put messages on the inbound queue and then some sql to retrieve the returned code from the outbound queue.
What I want to do is be able to convert the SQL which does this into .net code to be used by an application. i.e. write in .net some code to put xml on a queue and then write some .net code to retrieve xml from another queue.
I wouldn't have thought this would be a difficult thing to do and would have been done hundreds of times, but unable to find anything to simply send and retrieve XML to service broker queues....
thanks for your help.. its really needed. I found some links, but they are really vague and often doing select statments in service broker or something like this. I don't want to call any sql, just send and recieve XML on the queues.
any example code that does this, would be really helpfull
We have a "main" SQL 2014 server who imports XML files using SSIS in a datacenter. In remote sites (which are warehouses), there is an instance of SQL 2014 Express. A merge replication is setup, as every operations done on each site must be "forwared" to the main database, as some XML files are generated as output for an ERP system.
Now, the merge replication replicate all the data to the server on each sites. But a specific site don't need the data of every other sites, only the data relevant to itself (which is the warehouse code). Is there a way to replicate only the data relevant to each individual sites to the subscribers? Or is there a better way than replication to accomplish this?
I want to ship 500,000 aged transactions each night to an archive table and delete them from their source table in one or more logical units of work (LUW). Each row is approx 60 bytes and there is only one non clustered index on the source table presently.
I'm trying to weigh the pros and cons of 3 alternatives. One of them would basically insert the non-aged rows into tempdb, ship the aged records, truncate the table and then insert the tempdb records back into their source all in the same LUW.
For this alternative, I'd at least like to turn off logging when the records get inserted into tempdb as I dont see any value in logging that part of the activity. Is this possible?
Could you guys please help me with printing reports invoked thru command line/ URL access to print automatically to specific printers and specific trays and also is it possible to set the specific printer and tray as parameters.
I don't know whether anyone has this problem, but I am definitely not using the right keywords to search for a thread.
My situation is this...
I have a dataset that has values to fill cells to multiple tables in a report. However, I only want to select specific data from the dataset to fill textboxes and others. I cannot change the stored procedure, but the sample of the data is shown below:-
I know it looks weird, but the row really represents which "row" or textbox is it to fill with the Val. The Stat Column is just a way to make sure that I am filling the right values.
so my new report would have multiple tables to denote different categories. In my first table, I tried putting the cells as follows:- (expressions are highlighted in italics and bold)
I tried putting it into the headerrows instead of DetailRows, and it ended up printing the last value. Is there anyway to do this ? print all the values out in one table ? I tried using textboxes, but I think I got my expression wrong.
and it give me an error The value expression for the textbox €˜textbox5€™ contains an error: [BC30455] Argument not specified for parameter 'FalsePart' of 'Public Function IIf(Expression As Boolean, TruePart As Object, FalsePart As Object) As Object'.
Appreciate any advice or suggestion for this scenario !
I have a report that gets sends out through a subscription and sometimes the report has multiple pages and all those pages appear within one email.Is it possible to set the subscription in such a way that an email is sent per page when the subscription executes.
Under IIS SMTP I can set bounced email redirect etc. how to do that with dbmail, the idea is I can get the list of bounced emails somewhere so I can create a report.