Archived Months
January 2003
June 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 (alternate) > january 2007 > threads for january 8 - 14, 2007

Filter by week: 1 2 3 4 5

How Can i know how many USERS are in agroup.
Posted by ch.adilaziz NO[at]SPAM gmail.com at 1/14/2007 9:11:46 AM
HI all I just wana know that is there is any TSQL Statement which will give me the list of all user groups,names of user in each group and thier Permssions in any database/server. Actually I have to create a report in wich i have to show that how many groups we have any whi is the member of wi...more >>


Why is a simple WHERE clause so slow?
Posted by Emin at 1/12/2007 8:14:52 AM
Dear Experts, I have a fairly simple query in which adding a where clause slows things down by at least a factor of 100. The following is the slow version of the query ------------------------- SELECT * FROM ( Select x.event_date From x FULL OUTER JOIN y ON x.event_date = y.event_date )...more >>

2005 Copy database objects from one server to another
Posted by Jer at 1/12/2007 7:00:37 AM
I just upgraded to SQLServer 2005 Standard. I do development in a database on one server. When a solution is completely tested, I move it to the operational database on a different server. With SQLServer 2000, I could just open the .adp file and do File->Get External Data->Import to move the ...more >>

How can I modify a report in Crystal Report 7
Posted by microsoft . public . sqlserver at 1/11/2007 11:08:42 PM
I am a Web developer. I am new to VB 6.0 and Crystal Report. I have joined an organisation where there is an application running(developed in VB6 and crystal report 7). I have to modify one report. In two columns I have to make minor changes i.e put > and = operator. I am encountering following...more >>

Interesante relacion
Posted by Lucas Hernandez at 1/11/2007 6:19:56 PM
Tengo una situacion que luce así La siguiente tabla puede tener foreignkeys de 2 tabls diferentes y no se como crear o si no se puede crear esa relacion conbinada de 2 tablas tbTrabajosYMetas xid, tablecode, code 1, 'mts', 1 1, 'mts', 2 1, 'trb', 1 2, 'trb', 1 Los 3 campos son la lla...more >>

Stupid timing question
Posted by blueghost73 NO[at]SPAM yahoo.com at 1/11/2007 3:21:03 PM
Hopefully, this is an easy. Does SQL Server use the Windows system date and time? Or does it keep track of what day/time it is on its own? We were just discussing this in the office today, because we're planning for the changes in Daylight Savings Time in the United States this year. It's goin...more >>

Packages in SQL Server
Posted by Anna at 1/11/2007 1:16:07 PM
Hi: Can any one please tell me about Packages and their use in SQL Server? Thanks, Anna ...more >>

can't alter function
Posted by Barry at 1/11/2007 6:36:13 AM
In sqlserver 2000 I have a UDF which works fine but I want to make a change to it. When I do an ALTER FUNCTION ... I get an error saying that I can't alter the function because it is referenced by an object. Is there any way around this? I reference the UDF in over 100 tables, do I have to go t...more >>



Restoring databases
Posted by jai at 1/10/2007 2:52:26 PM
Guys, I need to restore a database which is 400 GB plus. Usually a normal restore from a backup file takes about 40 minutes. I have a database Company on a server A. I need to use the backup of database company to restore as company1 on the same box. At the end, company and company1 would resid...more >>

Bulk Insert - Fixed Length File
Posted by Jennifer at 1/10/2007 2:16:53 PM
I'm trying to do an insert using Bulk Insert with a fixed length file. I'm using a format file. I'm getting the following error message: Cannot perform bulk insert. Invalid collation name for source column 16 in format file '\\wbhq.com\dfsdv\iDataInt\GOPFiles\GOPFormatFile.txt'. Any suggestio...more >>

giving a proc database and table names as parameters
Posted by Muhammed Al-Khoutani at 1/10/2007 1:22:09 PM
Hello! Is it possible to pass a stored procedure a parameter, say @table and use it as a table in the sql command? Finally i want a proc to copy tables from a database to another database. THERE IS MY CODE: CREATE PROCEDURE [user].[copytable] @dbSRC varchar(100), @dbTRGT varchar(100),...more >>

Suppress Repeating Data in SQL Report
Posted by pmarisole at 1/10/2007 12:46:27 PM
I am trying to write a report that displays a hierarchy such as: Director, Manager, Employee I want to suppress the repeating Director, Manager for the employees. This is my code: sSQL = "SELECT FY99Info.MDName, FY99Info.MgrName, FY99Info.firstname, FY99Info.lastname, FY99Info.grade FROM FY9...more >>

Log Shipping - Move DB Changes?
Posted by madzambonis NO[at]SPAM yahoo.com at 1/10/2007 12:45:54 PM
I am in a 2 Database shop (DB2 and SQL Server) in which one of our larger clients use Log Shipping. We have need to tune a table on the primary server and ADDED a simple index to a table. Will that index be replicated down to the secondary server via log shipping. Or do I need to stop log s...more >>

URGENT : SQL Return Code: -25001
Posted by dipenvekaria NO[at]SPAM gmail.com at 1/10/2007 11:09:47 AM
Can anyone help me with below error code i am in getting while running a C program using sqls. Password: password SQL Return Code: -25001 BATCH_LOG_PATH: Thank you, D ...more >>

getting top 10 by group
Posted by M NO[at]SPAM at 1/10/2007 11:08:59 AM
If I have a query I am writing, I can use the top 10 function to bring back the top 10 rows. That's all fine if all I want is 10 rows. What if I have a grouped query, and I have 5 entities that I want 10 rows each from? ie, I have 5 buildings I would want max 50 rows. I tried Union, which ...more >>

'aging' tables
Posted by fireball at 1/10/2007 10:49:58 AM
I'm about to create some mechanism for control both: size of given table and age of it's entries. I wish it to delete entries if older then X , or last n entries when table is bigger then Y . I need opinion if it will be good to use ddl trigger mechanism (SS2005), or maybe someone would share...more >>

Querying different databases
Posted by plmanikandan NO[at]SPAM gmail.com at 1/10/2007 2:38:49 AM
Hi, I'm having two databases in the name of n1,n2 having same design I want to query both the databases by giving the database name in query Databases N1 N2 Table(both database contains same table) Detail Table details No -int Name -varchar(10) Now i want to check the detail table in ...more >>

max date select stmt problem
Posted by Matik at 1/10/2007 2:37:38 AM
Hello Everybody, I have a problem, with select stmt: SELECT TOP 15 * FROM oaVIEW_MainData AS TOP_VIEW, oaLanguageData_TAB AS RwQualifierJoin with (nolock) WHERE (c_dateTime>='2007.01.10 00:00:00' AND c_dateTime<='2007.01.10 23:59:59') AND RwQualifierJoin.text_id = c_cfgRegPoint AND (((...more >>

Calling a Proc From a Proc
Posted by Trevor Bishop at 1/10/2007 2:13:15 AM
I'm having problems calling my second proc (MyProcedure2) from within an existing proc. MyProcedure2 does not seeem to fire this way. My code is below. Help appreciated. Thanks, Trevor ALTER procedure dbo.MyProcedure1 (@newsletterid int) AS SET NOCOUNT ON -- Return Subscribers declare ...more >>

Creating functions
Posted by grant NO[at]SPAM technologyworks.co.nz at 1/9/2007 8:46:25 PM
Well, I just downloaded SQL 2005 Express to have a play. Good old Bill says "up and running in 20 minutes" Well 5 hrs, 5 reboots and 4 full un-install and re-install later I have finally got it working. About what I expected really. Anyway, my question relates to creating user defined functi...more >>

Redefining an auto-generated primary key constraint name
Posted by danielbuus NO[at]SPAM gmail.com at 1/9/2007 1:55:57 AM
Hey there :) I'm using Ruby on Rails to create a migration of a legacy database on an MS SQL Server. I'd like to name my constraints myself, such as 'pk_authors', but in the cases where a table has an auto incremented IDENTITY(1,1) id field, Rails takes over and adds the primary key itself wh...more >>

Default owner using ALTER AUTHORIZATION
Posted by Rico at 1/8/2007 6:14:49 PM
Hello, I have an SQL Server 2005 database that I'm trying to create using script. Everything works fine, but when I click on "Database Diagrams" I get an error message that there is no database owner, and of course when I show the Database Properties, the database was created without one. ...more >>

UPDATE a table with aggregate results for multiple columns
Posted by eighthman11 at 1/8/2007 8:19:02 AM
Hi everyone. I am updating a table with aggregate results for multiple columns. Below is an example of how I approached this. It works fine but is pretty slow. Anyone have an idea how to increase performance. Thanks for any help. UPDATE #MyTable SET HireDate=(Select Min(Case When Code ...more >>

Count the number of rows in a UNION ALL statement
Posted by markjerz NO[at]SPAM googlemail.com at 1/8/2007 7:15:38 AM
Hi, Should be quite simple but can someone please tell me the best way to count the number of rows in an UNION ALL statement. I tried using @@ROWCOUNT but that doesn't seem to contain the correct number. Also, I assume that running the query again but just returning count(*) instead of t...more >>

Damn! SQLServer2000 can't add a NOT NULL COLUMN even in one empty existing table!
Posted by aling at 1/8/2007 7:12:17 AM
Damn! SQLServer2000 can't add a NOT NULL COLUMN even in one empty existing table! That is, A is the existing table and it is emtpy, I want to add one NOT NULL COLUMN (col_new) to A using following T-SQL statement, then it will fail. ALTER TABLE A ADD col_new varchar(600) NOT N...more >>

Connection from ASP page to SQL Server Express
Posted by ma.giorgi NO[at]SPAM gmail.com at 1/8/2007 6:52:38 AM
Hi! I have two servers, the web (with IIS - win2003) and the test data server (winXPpro with SQL Express) I'm trying to connect to the db but with no success... here is the connection string I'm using: sConn = "Driver=SQLNCLI; Server=marco-server\SQLEXPRESS; Database=grimp; Uid=grimpuse...more >>


DevelopmentNow Blog