how to Implement Audit DB using new SQL 2008 Audit features?
SQL 2008 has audit feature.I need to use that but I dont know how.what are the step and requirement for using audit feature. ...
SQL 2008 has audit feature.I need to use that but I dont know how.what are the step and requirement for using audit feature. ...
Let's say we have two tables: 'Car' and 'Part', with a joining table in 'Car_Part'. Say I want to see all cars that have a part 123 in them. I could do this: SELECT Car.Col1, Car.Col2, Car.Col3 FROM Car INNER JOIN Car_Part ON Car_Part.Car_Id = Car.Car_Id WHERE Car_Part.Part_Id = @part_to_look_for GROUP BY Car.Col1, Car.Col2, Car.Col3 ...
Below is my SQL query used in SSRS report SELECT Claimname,CONVERT(VARCHAR,ClaimResponsedate,101) FROM Claim WHERE DataSourceID = 100011 From the above query 'ClaimResponsedate' may get NULL values but in SSRS report for this field displaying 1/1/1990 when the value comes as NULL. I need to display empty value in report if the date va...
I'm trying to setup a scheduled job that with one step that would insert the results from a sproc into a table. INSERT INTO results_table EXEC sproc The job executes and reports a success. Yet nothing gets inserted into a table. When I execute the same script from the SSMS the results are inserted. What might cause the problem? ** E...
Hello. I am trying to perform what I believe is a difficult recursion using a CTE is SQL Server 2008. I can't seem to wrap my head around this one. In the below examples you can assume a fixed depth of 3...nothing will ever be lower than that. In real life, the depth is "deeper" but still fixed. In the example I tried to simplify it som...
I would appreciate help with the following issue: I have created a local group in our SQL 2008 server and added two Windows user accounts "DOMAIN\UserName" I then added the local group to the database and granted read only access. The users are trying to link tables using MS Access using and ODBC connection and getting the following ...
Greetings, I'm looking for a SQL Server statement to retrieve records Where myfield content giving sub-string. Thank you, ...
I've got an instance of SQL Server 2008 Enterprise with Reporting Services installed also. I am hosting and administering this locally. My issue is that when I connect to the Report Manager web application I only get the Home|My Subscriptions|Help menu in the upper right hand corner. I am connecting using Windows Integrated Authentica...
OK, so I think I'm going mad here! Here's where I am. SQL Server 2008: I've set up Database Mail, and I've sent myself a test email. Simple, works fine. I've created an operator, called 'Tom'. I've given it an email address (but nothing else). However, when I run this command: EXECUTE msdb.dbo.sp_notify_operator @name=N'Tom',@subj...
I have a Stored Procedure which executes some dynamic SQL. I want to use this Stored Procedure in entity framework 4, but when I try to create a complex type the procedure returns no columns. Is there any way I can force it to return my values and get the entity framework to receive them? Here is a much-simplified example of what I want ...
Hello, I just read this link http://msdn.microsoft.com/en-us/library/ms186243.aspx Here is the code to create table and insert data :- -- Create an Employee table. CREATE TABLE dbo.MyEmployees ( EmployeeID smallint NOT NULL, FirstName nvarchar(30) NOT NULL, LastName nvarchar(40) NOT NULL, Title nvarchar(50) NOT NULL,...
Title says it all. I want to copy the data from an existing Access 2000 database to an existing Sql Server 2008 database. I would prefer to have the ability to only copy some data, so that I may add constraints (like ON CASCADE DELETE) as I go. Any ideas? ...
I am writing a SQL Stored Proc which takes in a single table valued parameter. Is it possible for me to create the table type in the parameter definition, for example: CREATE PROCEDURE example ( @param (CREATE TYPE tableparameter ( column1 int, colunn2 varchar.... )) READONLY ) ...
I have one database that gets a million rows added to it on a daily basis. Every day I'd like to run a query to pull out the million oldest rows(leaving about ten million in the database), and then move them into an archive database. There are well documented ways of doing this with sql server(bcp, openrowset, etc), but from what I can ...
In SQL Server 2005, there was a stored procedure available called sp_generateinserts. However in SQL Server 2008, it doesn't seem to exist. Does anyone know if it is still around? Thanks. ...
How to export query result to .csv file in SQL Server 2008 ? Thanks in advance ...
I have a stored procedure which I edit through Visual Studio 2008. Is there a simple way to change the name of the stored procedure? Right now if I look at the sproc's properties, the name of the sproc is grayed out. ...
I have a view which combines two tables using UNION ALL. Is it possible to create a unique index on the view? ...
Hello, I have a view which combines two tables via UNION ALL. The view is also schemabound, if that matters (WITH SCHEMABINDING). Is it possible to enable fulltext search on this view? I understand that Fulltext Search requires a unique index, but I can't create it because of UNION. Is there another way to make Fulltext Search work on...
I have a scenario where I combine two tables into one (using UNION) and also JOIN data from some other tables. I can do this either with a VIEW or a UDF/User Defined Function. Considering that I have no view so far at all in my database, but quite a few UDF's for fulltext search and the like, I'm tempted to use a UDF for this scenari...