Viewing 15 posts - 31 through 45 (of 54 total)
It sounds like you need to generate a fixed length format text file for upload to the mainframe. If so, you need to concatenate all the fields into one, giving...
February 9, 2005 at 12:14 am
Here is a way without temp table or union.
SELECT CONVERT(varchar(10), TD.CreatedDateTime, 101) AS BusinessDate
, sum ( case when TT.ShortDescription IN ('TN','TB','RN') then 1 else 0 end...
January 18, 2005 at 12:06 am
Using derived table [AddTaskList] gives all the additional tasks to be also inserted, and then only inserted
when the Problem_Category is of the given value.
/* code */
create trigger tr_HlpDsk_AdditionalTask on...
August 11, 2004 at 5:36 am
One of the things I read when SP3a first come out was that is was released due to the installation process failing when applying normal SP3 on Windows 2003 Server....
August 11, 2004 at 4:57 am
use
print @test-2
rather than
select @test-2
so that you do not have to concern yourself with the maximum column limit set within the Query Analyzer Results option.
June 29, 2004 at 3:40 am
Another alternative would be to compress the database dump or detached mdf/ldf using something like WINRAR or WINACE. This may get the archive file down to less than 700mb -...
March 16, 2004 at 1:35 am
SRVINFO.EXE is on the Windows Resource Kit CD.
Summary of the utilities on this CD (part of Technet) is available at:
http://support.microsoft.com/default.aspx?scid=kb;en-us;158388
August 19, 2003 at 8:32 pm
A technique I have used regardless of programming language when wanting to display a numeric with leading zeroes, goes a bit like this:
right( str ( 10 ^ 7 + fld...
June 9, 2003 at 1:24 am
A cursor is one way of locating the first unused number. Another way is to use the powers of MSSQL and sets.
Try this code.
-- sample table
create table sample ( range...
March 20, 2003 at 6:04 am
The values being passed as parameters are literals, yet as you construct your where clause their value will be assumed to be another field name for character strings when the...
January 5, 2003 at 6:21 am
Here is a technique to get the next sequence number to assigned to new records. Hopefully the three parts to the code become self-explanatory.
The updating the next sequence number to...
December 16, 2002 at 12:05 am
Yes, there are possible workarounds.
#1. You are already passing in the table name. Given the table name you will know which field contains the date. Use the If-Else clause...
June 23, 2002 at 7:46 pm
Only two changes are necessary to the above code to allow it to be converted a stored procedure that accepts the table name to process. assumes the parameter name is...
June 13, 2002 at 9:02 am
Yes, you can check for the successful operation of bcp.
There are multiple ways. However I will show you one contained purely in t-sql.
This requires you to capture the results...
June 6, 2002 at 12:37 am
Viewing 15 posts - 31 through 45 (of 54 total)