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 > september 2007 > threads for wednesday september 12

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

Want to create something like this. Please help!
Posted by Rex at 9/12/2007 11:17:46 PM
Below is the format of table I have with some sample data. familyID MemberName marker allele1 allele2 -------- ------------ ----------- ----------------- ----------------- 502 Angus 01-D8S1179 12.0 14.0 502...more >>

oracle - Out of present range
Posted by skyloon at 9/12/2007 6:28:48 PM
I've use VB as my front-end and oracle as my back-end. I tried to use the program to purge data from 8i to 9i, all the while there is no problem, but after sometimes, when i purge the data, it will prompt this error message: "Out of present range". Sometimes data has successfully moved to archiv...more >>

Query needed...
Posted by GB at 9/12/2007 5:41:29 PM
Hello, I have the following table: CREATE TABLE [dbo].[TBL_INPUT]( [ID] [nchar](10) COLLATE Latin1_General_CI_AI NULL, [VAL] [real] NULL, [START_DATE] [nchar](6) COLLATE Latin1_General_CI_AI NULL ) ON [PRIMARY] INSERT TBL_INPUT(ID,VAL,START_DATE) VALUES('A1 ','0.1','980618') IN...more >>

xp_sendmail
Posted by vtsun at 9/12/2007 3:08:02 PM
Hello, When I try to use xp_sendmail I get an error that says: Msg 17985, Level 16, State 1, Line 0 xp_sendmail: Procedure expects parameter @user, which was not supplied. The parameters for xp_sendmail do not include @user. It has @set_user. This is my test code: exec master.dbo.xp_...more >>

xp_cmdshell dtsrun
Posted by jlmjr at 9/12/2007 1:50:02 PM
SQL Server 2000. I am logged in as a system admin (although not sa). I am trying to run a simple DTS package from a stored procedure using xp_cmdshell 'dtsrun etc'. It just returns NULL and does nothing. I actually can't get xp_cmdshell to do anything except return NULL. Please help. Tha...more >>

!=NULL and <>NULL in SQLServer 2005
Posted by rgn at 9/12/2007 1:10:01 PM
Hello All, We are planning to migrate SQLServer 2000 databases to SQLServer 2005. In lot of our code which was written few years before, I see non-standard way of comparing NULL values such as !=NULL and <>NULL. In SQLServer 2005, I was wondering if this is supported and if it is not I h...more >>

SUM Help Please
Posted by twdavis at 9/12/2007 12:56:53 PM
I would like to SUM all the Cases in this statement. I would like to have to Columns( CaseName and CaseAmount) This is all the different statuses of an open order and we would like to have a total for each one. But I do not know how to do it. I was able to get the first case to sum correctly...more >>

stored proc snippet
Posted by rodchar at 9/12/2007 11:06:03 AM
hey all, SELECT @currentVacationAccrualRate = CASE @PPE_ToDate WHEN BETWEEN 0 AND 48 THEN 3.34 WHEN BETWEEN 49 AND 120 THEN 5.00 WHEN > 120 THEN 6.67 END It doesn't like the first BETWEEN for some reason? thanks, rodchar...more >>



Selecting part of a string
Posted by LW at 9/12/2007 11:06:01 AM
Hello! I need some help with getting part of a substring. This is what I am doing: select SUBSTRING(Table1.Col1,0,PATINDEX('%-%',Table1.Col1)) as myString from Table1 this works if Col1 contains 12345-7654 - it selects 12345 like I want it to get. However, if Col1 has just 7654 then i...more >>

SQL Collation conflict
Posted by Josue Guerra at 9/12/2007 9:35:02 AM
I have this error Cannot resolve the collation conflict between "SQL_Latin1_General_CP1_CI_AS" and "Modern_Spanish_CI_AS" in the equal to operation. first, I need to know why is this problem, and then how I can fix it, because is urgent resolve the problem, thanks for your help From http://www.de...more >>

custom color comments not printing
Posted by rodchar at 9/12/2007 9:22:01 AM
hey all, i changed my comments background and foreground colors and when i print on color printer the color of the comments are the default colors and not my custom color? thanks, rodchar...more >>

BCP failing silently on 2005
Posted by francis.moore NO[at]SPAM gmail.com at 9/12/2007 9:15:22 AM
Hi, I have the following bcp code that runs on SQL Server 2000 correctly but fails silently when running under 2005: DECLARE @ftp_file VARCHAR(255) DECLARE @ftp_bcp VARCHAR(255) SET @ftp_file = 'E:\Test\File.txt' SET @ftp_bcp = 'bcp "SELECT * FROM DB.dbo.Table " queryout "' SET @ftp_bc...more >>

SQLServer 2005
Posted by george2233691 NO[at]SPAM yahoo.com at 9/12/2007 9:12:59 AM
Is there a stored procedure or a command that returns the name of your database? ...more >>

query for name like 'Br%' or 'B>r' like date >='1/1/07'?
Posted by Rich at 9/12/2007 9:06:01 AM
How can I query for a name where the name begins with Br or Bu...? Like with dates you can say date >= '1/1/07' something like Substring(Name,1,1) = 'B' And Substring(Name,2,1)>='r'? THanks, Rich...more >>

How to restore database in SQLServer2000
Posted by Ron at 9/12/2007 9:04:03 AM
I need to restore a database in SQLServer2000. I have it backed up on CD. I can't see how to restore this in Enterprize management. Please help. Ron ...more >>

Query assistance...multiple joins
Posted by Chris at 9/12/2007 8:58:02 AM
Hi, I need some assistance with a query. I have 3 tables TableA LocID, ProdID, SKU TableB LocID,CustID,ProdID,SKU,QTY TableC LocID,CustID,ProdID,SKU,QTY What I am trying to do is this: insert into TableB, records from TableC which does not exists in TableB, but exists in TableC BUT...more >>

code outlining in SQL Server Management Studio (SSMS)
Posted by jeljeljel at 9/12/2007 7:30:36 AM
Is there a way to outline code similar to what is available via Visual Studio? Interestingly, in Visual Studio if I toggle outlining on some code blocks of a T-SQL statement and then copy/paste that into SSMS, the outlining remains. However I cannot figure out how to outline from w/in SSMS. T...more >>

Job Advice
Posted by jughead at 9/12/2007 5:52:43 AM
I have around 6 years of Programming experience. Everything from PERL - > ASP -> ASP.NET C# -> SQL. For the last two years now I have been doing 75% database work. I pretty much got into more of the database stuff because I felt that most of the Programming work was going overseas and many compa...more >>

Query using parameter of current user
Posted by Andrew Stokes at 9/12/2007 5:34:01 AM
Hi I have some tables in which I have records containing business opportunity data. One of the columns contains the user account of the person that created the record in the form DOMAIN\userID. Can anyone tell me what I need to include in a query to allow data to be filtered on the curren...more >>

Trying to create a linked server from an SQL Server to another SQL Server on another machine.
Posted by gdev at 9/12/2007 3:59:46 AM
I'm Trying to create a linked server from an SQL Server to another SQL Server on another machine. Can anyone suggest some good reference material or tutorials?? So far I'm only finding examples for a linked server to an ACCESS database. Thanks in Advance! ...more >>

last month records
Posted by asad at 9/12/2007 3:16:02 AM
hello, i want to show last month records from current date. What will be the query for that thanks, ...more >>

Assistance with query...
Posted by Chris at 9/12/2007 12:38:02 AM
Hi, I need some assistance with a query update join. I have 3 tables TableA LocID, ProdID, SKU TableB LocID,CustID,ProdID,SKU,QTY TableC LocID,CustID,ProdID,SKU,QTY Ineed to update TableB's QTY,SKU with TableC's QTY,SKU where TableC.LocID = TableB.LocID and TableC.CustID = Table...more >>

CONVERT date issue
Posted by CMKJ at 9/12/2007 12:20:28 AM
is there anything wrong with the following sql statement SELECT CONVERT(datetime, '24-07-07', 105) AS [100] i'm getting the following error Msg 241, Level 16, State 1, Line 1 Conversion failed when converting datetime from character string. what i want to achieve is to convert date '24-07-0...more >>

Accounting database design
Posted by vovan at 9/12/2007 12:00:00 AM
I'm starting an accounting project. I think I have to create a dataflow diagram first, then create the database structure. I'm the beginner in both areas - databases and accounting. But I leearned something already in the database area. Normal rules do not allow to store the same value in sev...more >>

UPDATE the value from a textbox...
Posted by trint at 9/12/2007 12:00:00 AM
I have this UPDATE: string strSQL00 = "UPDATE order_items SET quantity = '" + textBox2Text.Trim() + "' " + "WHERE order_id = '" + Class1.getSelectedOrderID.Trim() + "' AND product_id = '" + textLabel1Text.Trim() + "' "; I need to add the 'quantity' result with what is in ...more >>

How to alter computed column
Posted by Supriya Pagadala at 9/12/2007 12:00:00 AM
Hi All, I want to change the computed text for the column using script. Please help me. Thanks in advance Supriya ...more >>

How to disable error meggages in a stored procedure
Posted by HAlx at 9/12/2007 12:00:00 AM
Hello :) I have a stored procedure that can produce some errors and then when I execute it from some client - I get a message instead of result. And I can't use Try...Catch. And not always I can use RETURN or OUTPUT values (using somewhat limited custom SQL client library here). I want it l...more >>


DevelopmentNow Blog