Questions tagged [sql-server-2005]

Use this tag for questions specific to the 2005 version of Microsoft's SQL Server.

SQL Server 2005 (codename Yukon, version 9.00), released in October 2005, is the successor to SQL Server 2000. It included native support for managing XML data, in addition to relational data.

For this purpose, it defined an XML data type that could be used either as a data type in database columns or as literals in queries. XML columns can be associated with XSD schemas; XML data being stored is verified against the schema. XML is converted to an internal binary data type before being stored in the database. Specialized indexing methods were made available for XML data. XML data is queried using XQuery; Common Language Runtime (CLR) integration was a main feature with this edition, enabling one to write SQL code as Managed Code by the CLR. SQL Server 2005 added some extensions to the T-SQL language to allow embedding XQuery queries in T-SQL.

In addition, it also defines a new extension to XQuery, called XML DML, that allows query-based modifications to XML data. SQL Server 2005 also allows a database server to be exposed over web services using Tabular Data Stream (TDS) packets encapsulated within SOAP (protocol) requests. When the data is accessed over web services, results are returned as XML.

Resources

18391 questions
8
votes
5 answers

PIVOT in sql 2005

I need to pivot one column (Numbers column). example need this data: a 1 a 2 b 3 b 4 c 5 d 6 d 7 d 8 d 9 e 10 e 11 e 12 e 13 e 14 Look like this a 1 2 b 3 4 c 5 d 6 7 8 9 e 10 11 12 13 14 any help would be greatly appreciated...
IZar
  • 81
  • 1
  • 1
  • 4
8
votes
5 answers

Convert a 12 hour format to 24 hour format in sql server

there are date values in the below format,in one of the sql server 2000 tables 10/1/2013 10:39:14 PM 10/1/2013 6:39:04 PM 10/1/2013 8:19:31 AM 10/1/2013 3:35:40 AM how to convert the above format data values into a 24hour date format,as shown…
8
votes
5 answers

DBCC CHECKIDENT on a temporary table throwing permissions error for wrong user

I'm logged into a SQL Server 2005 database as a non-sa user, 'bhk', that is a member of the 'public' server role only. The following code tries to execute within a stored procedure called by user 'bhk'. This line of code... TRUNCATE TABLE…
8
votes
2 answers

Storing XSLT in SQL Server 2005 with xml type?

I have a lot of XSL files in my ASP.NET web app. A lot. I generate a bunch of AJAX HTML responses using this kind of generic transform method: public void Transform(XmlDocument xml, string xslPath) { ... XslTransform myXslTrans = new…
Jeff Meatball Yang
  • 37,839
  • 27
  • 91
  • 125
8
votes
8 answers

Versioning SQL Server?

My development group uses Visual Source Safe for version control; this choice was originally made due to cost and its tight integration with Visual Studio. As our repository has grown Source Safe has really started to show its limitations and we are…
user224220
8
votes
5 answers

"Favorites" or "macros" in SQL Server Management studio?

I have a few databases that I always use SQL Server Management Studio with. I'd like to be able to create a toolbar button or keyboard shortcut that automatically opens a new query window (in the current SSMS instance) and connects to a given…
Patrick Szalapski
  • 8,738
  • 11
  • 67
  • 129
8
votes
3 answers

How to determine why a distributed transaction is timing out

I am using LINQ to SQL and a third party SDK that supports distributed transactions. When I realize that a pending update will be updating both SQL records and records in the third party SDK, I am creating a TransactionScope with a 0 (presumably…
BlueMonkMN
  • 25,079
  • 9
  • 80
  • 146
8
votes
3 answers

SQL where Date from today minus and plus days

I have codes like this: select CUS_Id, CUS_Name, CUS_JoinDate from CUSTOMER where CUS_joinDate between '04-12-2013' and '06-12-2013' How can I make it 'where' CUS_JoinDate will be declare as from Today Date(minus 1 month and today + 1…
Captain16
  • 327
  • 2
  • 8
  • 19
8
votes
2 answers

Get all non-clustered indexes

Does anyone know of a good script to get all the non-clustered indexes for SQL Server 2005?
super9
  • 29,181
  • 39
  • 119
  • 172
8
votes
1 answer

Error calling remote scalar-valued function

I am making a call from a sql 2005 database to a sql 2000 scalar-valued function and recieve the following error message: Remote table-valued function calls are not allowed. here is my call: select * from [server/instance].[db name].dbo.[function…
Billy Logan
  • 2,833
  • 16
  • 43
  • 49
8
votes
1 answer

Hide relationship from a SQL Server database diagram

I am using SQL Server 2005 database with SQL Server Management Studio. Is there a way to hide a relationship between two tables in the diagram without actually deleting the relationship from the database? Any help will be most appreciated.
user179490
  • 155
  • 1
  • 1
  • 14
8
votes
4 answers

How does a "Schema changed after the target table was created" error occur?

I hit this error while my web application was trying to execute a SELECT INTO on a MSSQL 2005 database. I really have two questions: What does this error mean and how does this happen? Is there a way to prevent these errors by coding in a…
Bialecki
  • 30,061
  • 36
  • 87
  • 109
8
votes
3 answers

Global Temporary table delete operation

How to check if the global Temporary table exists in SQL server, if yes then delete that global temporary table? I am trying to execute this: IF OBJECT_ID('##Table', 'U') IS NOT NULL DROP TABLE ##Table ...but it is not working.
Jason M
  • 1,040
  • 4
  • 12
  • 21
8
votes
5 answers

Can I set a default schema for within a stored procedure?

I'm working on the next update for StackQL. One thing I want to do is have the ability to query over several releases. So when I loaded the October data, for example, I didn't delete the old September database. It's still out there. In fact, you…
Joel Coehoorn
  • 399,467
  • 113
  • 570
  • 794
8
votes
6 answers

Anyway to create a SQL Server DDL trigger for "SELECT" statements?

I am dealing with some sensitive Accounting tables and I would like to audit any SELECT statement executed on the table or any views associated with them. I did not find any DDL Events on BOL (Books Online) that had anything to do with SELECT…
dance2die
  • 35,807
  • 39
  • 131
  • 194
1 2 3
99
100