Archived Months
January 2003
March 2003
April 2003
May 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
November 2007
April 2008
all groups > sql server programming > august 2007 > threads for thursday august 30

Filter by Day: 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31

Refresh Views
Posted by JCP at 8/30/2007 11:48:02 PM
I'm using the store procedure below to drop and recreate all my views. It works fine if the string is <=4000 char. I tried to change data type for @text parameter from nvarchar(4000) to varchar(8000) but the error still occur. Question. How can I do to refresh (drop and re-recreate) all view...more >>


using references on sql server
Posted by Roy Goldhammer at 8/30/2007 6:18:33 PM
Hello there On the place i work with they always used references in all the database for better checking, design ect.. Now when they need to load huge amount of data the reference has slow the performance in 50%. It is obvieous because when the sql check valid data it reduces performance...more >>

need help with deleting duplicate rows
Posted by mitra at 8/30/2007 4:38:04 PM
Hi All, I am trying to delete rows with duplicate values in the 'nId_mail' column of a table and keep at least one of each nId_mail. I have tried several delete statements posted on this website but none worked for me... not sure why! When I group the columns, I don't get any rows with havi...more >>

STATS_DATE is NULL
Posted by Jay at 8/30/2007 3:23:05 PM
I need to get the STATS_DATE on all indexes in the database, table by table. The procedure is being created in the [master] database and it returns correct information for tables in [master]. However, it returns NULL as the STATS_DATE for all other databases. When I switch the database cont...more >>

Will a Blocking incident resolve with time?
Posted by John Kotuby at 8/30/2007 2:34:14 PM
I was thinking of removing the ADO command timeout values in a VB Application that uses SQL Server 2000 Standard as the backend. Users have complained about timeouts making their life difficult. I have watched the server and noticed very occasional blocking (once or twice a month) during hea...more >>

Deleting a trigger
Posted by dkroll NO[at]SPAM commercialtax.com at 8/30/2007 2:00:14 PM
Using SQL Server 2000. I have a trigger (update,insert) that copies the current record to a change log table. I want to delete the trigger, but when I try to do that, Enterprise Manager hangs up and I have to end the process. Do I have to take the database offline before I do this? I've even...more >>

how to exclude the seconds and millisecs from a date argument?
Posted by Rich at 8/30/2007 1:54:01 PM
I have to pull sets of data (users of my client application will pull sets of data) from a table where the different sets are distinguished by a data column. Example: one set containing 2100 rows were inserted on 2007-08-29 14:03:06.887 another set was inserted on 2007-08-29 13:45:37...more >>

best book on performance tuning
Posted by John Grandy at 8/30/2007 11:38:01 AM
Any suggestions for best book on performance tuning ... ...more >>



What is meant when someone refers to a SQL Server "Instance"???
Posted by PSULionRP at 8/30/2007 10:18:03 AM
What is meant when someone refers to a SQL Server Instance??? Does that refer to a SQL Server??? I'm pretty sure it's not a Database. Does it refer to a SQL Server within a bigger server??? For instance...we have a SQL Server called DEV and then within that we have WEB, APP, and REPORTS.....more >>

Returning the Nth partition of a result set
Posted by dalton at 8/30/2007 10:12:03 AM
I am trying to select a set of records into an XML result. To do this I have the following query: SELECT [CODE] '@a',[DESC] '@b',[RATE] '@c',[ALT_CODE] '@d', [CHANGE_DATE] '@e',[CHANGED_BY] '@f',[EXTRA_ASC_1] '@g',[EXTRA_ASC_2] '@h',[EXTRA_ASC_3] '@i', [EXTRA_ASC_4] '@j',[EXTRA_NUM_1] '@k',[...more >>

forming a string with dateparts
Posted by rgintexas at 8/30/2007 8:33:22 AM
I want to create a string using the week number and year of a date. For instance, if i have a date of 1/3/2007, which would be week 1 of 2007, i want to create a string that says 'Wk1-2007'. i know it's basically 'WK' + CAST(DATEPART(WK,'1/3/2007') AS VARCHAR) + '-' +CAST(DATEPART(YEAR,'1/3/200...more >>

Using MS-Access as a report writer
Posted by JimP at 8/30/2007 7:44:37 AM
Is there any literature/documentation about "best practices" when using MS-Access with SQL Server? ...more >>

if in check constraint
Posted by HDI at 8/30/2007 7:22:07 AM
Hi, Is it possible to use a if or iif in a check constraint or should I use a UDF? Thx ...more >>

hierarchy sql queries
Posted by agarwal.libra NO[at]SPAM gmail.com at 8/30/2007 5:57:25 AM
i have a problem in sql. there is table of employee in which one column is empid and another is manager_id. and one wants to go to the hierarchy that is emp->manager->manager- >...->root. so how to find that one? ...more >>

Application Security Question
Posted by Tim Morrison at 8/30/2007 5:30:58 AM
MSDE, SQL Express When my customers install our software, i would like them to go thru a "registration" process, that, in part, will create a record in a single record table that identifies the computer that database is installed on. Then when the workstations first login to the database, ...more >>

Help with 'Distinct'
Posted by Harish Mohanbabu at 8/30/2007 4:32:03 AM
I have this requirement to pick up the last record based on date and time. For example here are some sample records - 701,1,2007-08-03 00:00:00, 1899-12-30 15:28.000 701,1,2007-08-03 00:00:00, 1899-12-30 21:28.000 701,1,2007-08-04 00:00:00, 1899-12-30 21:28.000 701,1,2007-08-04 00:00:00, 189...more >>

Trigger failing on multiple INSERTS
Posted by francis.moore NO[at]SPAM gmail.com at 8/30/2007 3:44:22 AM
Hi, I've written a trigger that inserts data into Table B if it doesn't already exist in Table B when data is inserted in Table A. The trigger works perfectly for single inserts, but seems not to work at all for multiple inserts. The data is still inserted into Table A, but the trigger does...more >>

strange problem with sp_executesql and like
Posted by Sergei Shelukhin at 8/30/2007 1:30:38 AM
Hi. We are having a weird performance issue with a query launched thru SqlDataAdapter from C#. Data adapter executes parametrized queries using sp_executesql, and the query that is concerned is pretty complex and uses a LIKE clause like this Blah LIKE '%' + @Name + '%'. When we launch the ...more >>

Comment on SQL Report Builder
Posted by sam at 8/30/2007 12:24:08 AM
Is anyone using this tool to generate reports? General Comments on usage? TIA Sam ...more >>

SQL Connetion from Pocket PC2003 to SQL2000-SP4 Arabic Coallation
Posted by Peer-Prologic First at 8/30/2007 12:08:01 AM
Dear All Please help in this ,it is very crtical and very urgent.I am using SQL Client in Vb.net Compact Framework 2.0 to connect SQL Server 2000.It is working fine with English collation (SQL_LATIN1_General) but same code gives error with Arabic collation. Error was Plattform not supported ...more >>

correlating spid to objectid
Posted by Neo at 8/30/2007 12:00:00 AM
does anyone knows if theres a way to correlate session to the objects it uses? ...more >>

Insert Into Select query - Why slow?
Posted by Chris at 8/30/2007 12:00:00 AM
I was wondering if someone can explain the following. I am trying to optimise a query and can't figure out why SQL Server is behaving is a particular way. To begin with I am calling two DBCC statements to make sure i've no cache. In the example below I am doing a simple EXISTS check. If ...more >>

Execute permission of sp
Posted by Rotsey at 8/30/2007 12:00:00 AM
Hi, I have a .Net 2.0 windows app that connects to a SQL Express DB. I have 2 Clients using it fine. It accesses stored procs to update data. The clients use integrated security. data source='SQLSERVER\SQLEXPRESS';initial catalog=tbrPData;integrated security=SSPI The problem is on ...more >>

querying distinct records based on date time
Posted by sony.m.2007 NO[at]SPAM googlemail.com at 8/30/2007 12:00:00 AM
Hi, I have a table with following data Tablename:test Pr dt vs_val 11 2007-08-30 12:57:12.143 1 11 2005-06-11 00:00:00.000 2 12 2005-06-11 00:00:00.000 2 14 2005-06-11 00:00:00.000 2 11 2007-08-30 13:24:42.600 1 11 2005-06-11 00:00:00.000 2 15 2005-06-11 00:00:00.000 ...more >>

Attach DB Without LDF
Posted by at 8/30/2007 12:00:00 AM
I have a database (full mode) that has not been used in a very long time. I have detached the database and moved the mdf to a DVD. Is is necessary to aslo have the original LDF if I plan to reattach later on? I figure SQL Server 2005 can just recreate a new LDF. ...more >>

SQL Server 2000 Lock and Unlock table question
Posted by Jason Huang at 8/30/2007 12:00:00 AM
Hi, We are developing our C#.Net 2.0 applications using the SQL Server 2000 as our database server. We didn't do anything useing the Lock and Unlock so far, and our application runs seems fine, but I'm not sure. Given on this situation that Client A and Client B and Client ... are using our ...more >>

Getting locale info
Posted by Alex at 8/30/2007 12:00:00 AM
Does MS SQL Server have a system stored procedure or something else that is similar to Windows API GetLocaleInfo? We need to do some country specific processing inside the trigger. Thanks Alex ...more >>

Need help with Server Upgrade Recommendations
Posted by John Kotuby at 8/30/2007 12:00:00 AM
Hi all, We have a client/server application that has been running fine at 30+ customer sites, except for 1 location. The client application is written in Visual Basic 6 and the database server is SQL Server 2000 Standard 32 bit. This particular location has 50 workstations running our appli...more >>

Which sys table are synonyms stored in/
Posted by Paddy at 8/30/2007 12:00:00 AM
Does anyone know which table the synonyms are stored in, I would like to be able to list with all details quickly without using the Ma agment Studio? Paddy ...more >>


DevelopmentNow Blog