Archived Months
March 2003
April 2003
May 2003
July 2003
August 2003
September 2003
October 2003
November 2003
December 2003
January 2004
February 2004
March 2004
April 2004
May 2004
June 2004
July 2004
August 2004
September 2004
October 2004
November 2004
December 2004
January 2005
February 2005
March 2005
April 2005
May 2005
June 2005
July 2005
August 2005
September 2005
October 2005
November 2005
December 2005
January 2006
February 2006
March 2006
April 2006
May 2006
June 2006
July 2006
August 2006
September 2006
October 2006
November 2006
December 2006
January 2007
February 2007
March 2007
April 2007
May 2007
June 2007
July 2007
August 2007
September 2007
October 2007
all groups > sql server (microsoft) > june 2005

Filter by week: 1 2 3 4 5

query too slow
Posted by Nedo at 6/30/2005 6:04:03 AM
why does this query take more than 3 minutes: select Count (*) from S_Address Where KundenID=18 And email in (select distinct email from s_pixelemail where mailid=51) select Count (*) from S_Address Where KundenID=18 ==> takes 0 sec -> 3500 rows select distinct email from s_pixelemail whe...more >>


Order by Case statement fails with Union Operator - Help!
Posted by lad4bear NO[at]SPAM hotmail.com at 6/29/2005 5:13:02 AM
Hi Guys, I have the following stored procedure which I use to pull hotel information from the database. The following procedure does just what I need but I can't get the Case statement to work with the OrderBy clause. When I try I get the following error: Error 104: Order by items must a...more >>

dynamic stored procedure
Posted by alex at 6/28/2005 8:17:54 PM
i would like to execute the following logic in a stored procedure: if (<condition>) return 1 else return 0 The catch is that the condition "string" is coming as input to the stored proc. I.e. the condition is not hardcoded. Further the condition itself is going to need to call other ...more >>

ADSI LDAP Query 1000 Record limit for MSSQLServer linked server
Posted by vorpal at 6/27/2005 7:14:40 AM
Hi, I have successfully set and used a linked server to query ADSI. Since this question also concerns MSSQLServer, I've cross posted it -- I hope this is not a breach of etiquette. I have successly created a view based on the linked server. Unfortunately, it only shows 1000 records, and there...more >>

Tweaking database performance
Posted by Meharis at 6/25/2005 12:00:00 AM
Hi do you have some hints to increase performance of an SQL Server / Database Queries without changing any hardware ? tia Sanny ...more >>

dynamically create MS Access database via DTS Package
Posted by karo12069 at 6/24/2005 9:47:06 AM
Hi! Does anyone know of a way to dynamically create an Access database from scratch in a DTS package to be a destination? Would this require a custom task? How do you create that? I thought I found some code, but I couldn't get anything to work, probably due to my lack of VB knowledge. Th...more >>

Dublicate database?
Posted by xxxxyz NO[at]SPAM abv.bg at 6/24/2005 4:21:45 AM
Hi, I want to create a dublicate of a database for debugging (the two databases have to be absolutely equal). How could I do this with Enterprise manager? Thanks? ...more >>

I just showed my boss a simple SQL statement...
Posted by Ian at 6/21/2005 2:15:05 AM
insert X select * from X (4194304 row(s) affected) 00:00:44 This was on a little twin processor Dell blade thing. I strongly suspect his XX terabyte 32 processor Sun Oracle server licence is going to be renegotiated on price in a few month't time. ...more >>



subtract rows
Posted by pikapi at 6/21/2005 12:40:01 AM
Hi, I have the following table: INOUT Total 1 3 2 2 2 4 1 3 2 6 1 23 2 33 I want to make a query that will do the following: Subtract (the sum of the total where inout=1) from (the sum of the total where inout=2) Any help is greatly appreciated. Thanks ...more >>

How do i search all Stored Procedures for a table name
Posted by weegee NO[at]SPAM metronet.co.uk at 6/20/2005 4:45:58 AM
What I want to do is to search within the text of all Stored Procedures ....for instances of a table name within the SQL statement Does anyone know how I would be able to do this? Say for example I want to search for the table tblContractHistory Would I use sysobjects? ...more >>

SQL 2000, SP3a "TOP 100%"
Posted by RTL at 6/17/2005 8:53:19 PM
Ever since we rebooted the machine, all of our views have been modified with the "TOP 100%" We cannot seem to remove this. MS Access barks at us when we try to modify a table and it's because of the TOP 100% text. How to remove it...make it go away...just ignore it? Cheers, Rich ...more >>

alter column sql
Posted by Jeff Kish at 6/16/2005 10:36:53 AM
Hi. Is there some way to get enterprise manager or query analyzer to tell me the sql it uses for an alter column operation? I would just do : alter table asset alter column asset_number varchar(60) go but there are other contraints etcc. I don't know how to 'cascade' them, and the ...more >>

Inserting current date midnight
Posted by kayda at 6/16/2005 9:09:17 AM
Hi: You can INSERT the current date and time like this SELECT databasefield, getdate() FROM testtable but what is the easiest way to SELECT the current date's midnight timestamp, so instead of SELECTing 6/17/2005 4:17:32 PM it would SELECT 6/17/2005 12:00:00 AM? Thanks, Kayda ...more >>

Increment a single column?
Posted by Noozer at 6/16/2005 9:04:39 AM
Just wondering if there is a simple way to do this... I have an MS Access table that I'm using from an ASP page. It's quite simple... Just one row with six columns. I want to be able to specify a column and increment the value in that column. Something like this.. I want to increment the val...more >>

Transact-SQL Tutorial
Posted by b_naick NO[at]SPAM yahoo.ca at 6/15/2005 1:11:43 PM
Are there any good free online tutorials for T-SQL? ...more >>

003 vs 3
Posted by aaron.kempf NO[at]SPAM gmail.com at 6/14/2005 9:53:46 AM
so uh everywhere i've ever been-- people use the notation 003 instead of storing something as an integer. why do people do this? i just see it like EVERYWHERE.. pisses me off personally. Storing a char(3) is _MUCH_ slower than storing a tinyint right? ...more >>

newbie q: msde 2000 or sql server 2005 express?
Posted by CreepieDeCrapper at 6/13/2005 11:42:50 AM
in short, i am a new asp.net developer trying to setup my xp pro sp2 machine with the following: - IIS (done) - .NET Framework (1.1 w/hotfix done) - MS SQL db (outstanding) any recommondations on which sql server version to install? i'm looking at either msde 2000 release a or sql server...more >>

An interesting set-based problem - pairing lines together based on count
Posted by Brett Gerhardi at 6/8/2005 10:52:50 AM
Can anyone work out how I can do this in a set-based way? I am totally stumped on this one. Given the following: create table TestCountJoin ( ID int identity(1,1) primary key, CustomerID int, ItemCode varchar(1) ) insert into TestCountJoin (CustomerID, ItemCode) values (1, 'A') i...more >>

SQL server job timeouts?
Posted by wamatt NO[at]SPAM gmail.com at 6/8/2005 8:25:23 AM
We have a job that uses WinHTTP inside a stored procedure. We have another SP wrapper that runs this for a couple hundred records. When we add this as a job using SQLAgent it times out half way. Running it from SQL Query analyser and it completes to the end. Anyway to set the timeouts for jo...more >>

Efficient record storage 10+ Million records
Posted by Ben at 6/7/2005 9:22:09 AM
I have a database that stores survey information. I've been asked to add information to it to test scalability. Well, its' hurting. What I have is a 'sample' table or the people that took the survey and then several related tables. Lets' say the sample table looks something like tblData...more >>

Strange stored procedure results
Posted by bruce.parrott NO[at]SPAM infinity.co.nz at 6/6/2005 9:38:58 PM
I have a customer website that I host. The site uses a MSSQL 7 database (Win2K) that has a particular stored procedure which exhibits the following behaviour: 1. Running the stored procedure in SQL Query analyzer takes ~1.5 minutes to return 890 rows. 2. When we backup and restore the databa...more >>

Windows XP Pro Repaired - SQL Server Enterprise Manager Not Working
Posted by Jerry at 6/6/2005 10:53:26 AM
Hi all, I had to repair Windows XP Pro due to some corruption. After doing so everything seems the same on the node that had Enterprise Manager on it, however, I am unable to register or discover the database node. Network is the same and still working properly. Not sure why I am unable t...more >>

Stop replication of deletes
Posted by stephen atkins at 6/2/2005 8:18:49 PM
Hello all. We are just getting started with replication and I'm wondering if there is a way to not have deletes replicated. I know I could manually remove the delete trigger from every table but I'm intrested in have this a bit more automatic (like when its creating the subscription). T...more >>

Moving 7.0 -> 2K Chinese
Posted by Larry Richardson at 6/2/2005 12:00:00 AM
Here is the setup. I have a SQL Server 7 DB in China that I need to move to a SQL 2000 machine in US. I have tried several different methods, but the Chinese characters are always messed up. I have created the Server/Database with the CHinese_PRC_CI_AS collation, which matches the SQL7 ...more >>

express 2005 license
Posted by Candor Feg at 6/1/2005 11:33:48 AM
what's the deal? Free for non comercial use? I can include it in my apps, but not commercial apps? What "non commercial" apps coult there really be? thanks ...more >>


DevelopmentNow Blog