Viewing 15 posts - 541 through 555 (of 595 total)
Working with your example, I came up with:
DROP TABLE myData
GO
SET NOCOUNT ON
CREATE TABLE myData
(
id int PRIMARY KEY,
index1 int,
index2 int,
value varchar(50)
)
INSERT myData (id, index1, index2,...
May 24, 2004 at 12:34 pm
You didn't mention previously you were using DTS. Are you connecting to an Access database, then transferring all of the data to SQL Server using a DTS package? Was that a...
May 24, 2004 at 9:13 am
Powerbuilder is a development environment/language produced by Sybase, Inc. (from whom Microsoft used to license SQL Server code, through version 4.21a). My point was that I thought I did something...
May 21, 2004 at 10:03 am
Bryan,
I have a couple of databases in which I store Word documents that are stored and retrieved from within a Powerbuilder application.
Have you verified that you have the necessary indexes...
May 21, 2004 at 7:09 am
Yes, if an error occurs in UPDATE tblTemp1 (after saving T1), then you jump to your error handler without committing or rolling back transaction ABC. Same thing could happen with...
May 20, 2004 at 9:30 am
SET NOCOUNT ON | OFF can be used anywhere as many times as you want.
GO is a batch separator, so any local variables created with DECLARE are release when you...
May 20, 2004 at 7:50 am
You are correct, I don't see anyway to specify ASCII or BINARY in DTS.
I have two simple DTS packages, each containing a single FTP task. One task transfers a self-extracting archive...
May 18, 2004 at 7:17 am
Actually, if you saved the example script as "createscript.sql", you could execute the following from a command prompt, or place the following statements into a Windows batch file. The batch...
May 17, 2004 at 7:29 am
If you are running this interactively, and not as a job, then use could use Query Analyzer to generate a script to create all of the views, then cut and...
May 17, 2004 at 7:11 am
>>
"SELECT @tabremove = RIGHT(@stringWithTab, LEN(@strWithTab) - LEN(chr(9)))" . . . doesn't work because the "chr" function on the end should be "char".
>>
I showed the Char() correction in my previous example,...
May 8, 2004 at 5:26 am
Try:
SELECT @tabremove = RIGHT(@stringWithTab, LEN(@stringWithTab) - LEN(CHAR(9)))
To handle blank or null @stringWithTab values, try
SELECT @tabremove = CASE WHEN @stringWithTab = '' OR @stringWithTab IS NULL THEN @stringWithTab ELSE RIGHT(@stringWithTab, LEN(@stringWithTab)...
May 7, 2004 at 6:11 am
The problem may be that the source dates your are inserting are not actually null, but blank strings. For example, this happens frequently when importing FoxPro or dBase data though...
May 7, 2004 at 5:39 am
Here's a possible solution using two UDF's, dbo.fnHex2Int and dbo.fnURLDecode:
-- Example:
-- SELECT dbo.fnURLDecode ('http://www.sqlservercentral.com/forums/shwmessage.aspx?messageid=113594')
-- SELECT dbo.fnURLDecode ('http://www.sql%20server%20central.com/forums/shwmessage.aspx?messageid=113594')
GO
CREATE FUNCTION dbo.fnHex2Int
(
@hexNum varchar(20)
)
RETURNS int
AS
BEGIN
DECLARE @hexdigits varchar(16), @next char(1), @num int, @multiplier...
April 30, 2004 at 8:05 am
You cannot place a list of values in a variable for the IN clause: Mon in (@mon)
To use @mon, you would have to resort to dynamic...
April 29, 2004 at 7:25 am
I use the following procedure, uspGetToken, to return the first substring. The original source string is modified by stripping the first token and the first delimiter string (which can be...
April 26, 2004 at 7:46 am
Viewing 15 posts - 541 through 555 (of 595 total)