Server Info:
Windows Server 2008, SQL Server Standard 2008 (64-bit)
I recently upgraded to SQL 2008 and was interested in trying out T-SQL Debugging. Initally encountered some firewall issues, but after disabling my workstation's Windows Firewall and having TCP port 135 and UDP 4500/500 opened up by the IT group I got a little further....
Based on the following table
id Title Date Metadata
------------------------------------
1 A 08/01/2010 M1
1 A 10/05/2010 M2
1 A 03/15/2011 M3
2 B 09/20/2010 M1
2 B 01/15/2011 M2
3 C 12/15/2010 M1
Input variables will be start and end date. S...
I'm running SQL Profiler 2008 on my application to get a better feel for what my application is doing at the DB level. There are some columns in the output that are unclear to me as to what they mean:
1) SPID: I'm using a single connection to the DB to do all my database activity. Yet I see several different SPID values. What does SPID ...
How do I capture the output from the following SQL statement so I can query the resultset?:
RESTORE FILELISTONLY FROM
DISK = N''D:\Restores\MyBackup.BAK'' WITH NOUNLOAD,
FILE = 1
Do I need to create a temporary table and then do something like?:
INSERT #tmp EXEC ('RESTORE FILELISTONLY FROM
DISK = N''D:\Restores\KevsP...
I'm trying to delete a couple of rows
USING
SQL Server management studio, for 2 rows only i get the message
No rows were deleted
A problem occurred attempting to delete row #X
Error Source: .Net SqlClient Data Provider
Error Message: String or binary data would be truncated
The Statement has been terminated
Correct the errors and ...
Based on the following table
Title Jul-10 Aug-10 Sep-10 Oct-10 Nov-10 Dec-10 Jan-11 Feb-11 Mar-11 Apr-11 May-11 Jun-11
--------------------------------------------------------------------------------------------
A Null M1 Null M2 Null Null Null Null M3 Null Null Null
B Null M1 Null N...
I'm trying to create a rather simple script for dealing with SQL Server Agent jobs. It performs 2 tasks:
1) If a given job exists, delete it
2) Create the job
(Due to business requirements I can't modify an existing job, the script must delete & re-create it.)
Running the script the first time works fine (creates the job). Running a...
Is there a task manager of sorts for SQL Server 2008 and on?
A way to see what SQL server is doing, kill runaway queries, etc...
...
DETAILS table has following columns
Title First Second Third Fourth Fifth
------------------------------------------
A null null null null null
input variable
--------------
@columns = 'Title, Third, Fourth'
I want to generate ouput as
@allcolumns = 'Title, Third, Fourth, First, Second, Fifth'
Variable @allco...
I am using SQL Server 2008 Enterprise. And using ADO.Net + C# + .Net 3.5 + ASP.Net as client to access database. When I access SQL Server 2008 tables, I always invoke stored procedure from my C# + ADO.Net code.
My question is, if I do not have any transaction control (I mean begin/end transaction) from my client C# + ADO.Net code, and I...
I want a column to have only two values. For example I want to make the column active can only contain the values "Y" and "N" I don`t want to use boolean data type.
I`m looking for a way similar to the Look Up Wizard of the MS Access how can this be done?
...
Hello everyone,
I am using SQL Server 2008 Enterprise. And using ADO.Net + C# + .Net 3.5 + ASP.Net as client to access database. When I access SQL Server 2008 tables, I always invoke stored procedure from my C# + ADO.Net code.
I have 3 operations on table FooTable. And Multiple connections will execute them at the same time in sequence...
I have an ASP.NET MVC application and I want to embed on each page some help content. This will be HTML pages that will be loaded into a dialog or new browser page (to be decided). Obviously I could store this in a max text field in the DB, but I also think I could store it in a FileStream. This sounds appealing to me as it would allow m...
I am trying to eliminate outliers in SQL Server 2008 by standard deviation. I would like only records that contain a value in a specific column within +/- 1 standard deviation of that column's mean.
How can I accomplish this?
...
I just installed sql server 2008 developer edition on my windows vista machine. The installation was successful. Reporting service is working fine. But I am not getting any option to connect to "Analysis Services" in sql management studio.
The only options i get for "Server Type" while connecting are -
1. Database Engine
2. Sql Serve...
I need to select sample rows from a set. For example if my select query returns x rows then if x is greater than 50 , I want only 50 rows returned but not just the top 50 but 50 that are evenly spread out over the resultset. The table in this case records routes - GPS locations + DateTime.
I am ordering on DateTime and need a reasonable ...
Hi All,
I am using the flat file source for a large data migration and the source data in the text stream form unlike UI, datetime or sting. The component is not supporting for fast parsing for text stream.
Could I get any ideas to improve fast performance in this scenario.
thanks
prav
...
During installation of SQL2008 will the builtin\administrator group be created automatically. I observed that it didnt get created. How do we create this group manually.
Or otherwise if we want it to be created in installation itself what settings needs to be changed.
...
I've noticed that the first sql statement with LIKE on a large table runs very slowly
(around 20 minutes) but every subsequent one very very fast (a few seconds), even
if the strings searched for are completely different from the initial one
(the first string 'ability%', the second 'su_mit%')
Does sql server store the results of table ...
Is It Possible to connect SQL Server 2008 from SQL Server 2005 Enterprise Manager?
I am getting below mentioned error while connecting 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 r...