Viewing 15 posts - 16 through 30 (of 98 total)
Here's an example to put in an activex task within the package to determine the server name:
Set WshNetwork =CreateObject("WScript.Network")
DTSGLOBALVARIABLES("gvServer").VALUE=WshNetwork.ComputerName
MsgBox ("Computer Name = " & DTSGLOBALVARIABLES("gvServer").VALUE)
set WshNetwork =nothing
July 8, 2005 at 1:58 pm
For another approach:
http://www.sqlservercentral.com/forums/shwmessage.aspx?forumid=19&messageid=112360#bm113285
April 14, 2005 at 4:54 pm
I think I just saw the same thing you did, ajrg, and didn't see your post until I clicked reply.
For more info on a way to implement this: http://www.sqlservercentral.com/columnists/tdavid/moreportabledtspackages.asp
April 8, 2005 at 2:47 pm
Take a look at the Dynamic Properties task in DTS, which can set the file name based on a global variable, for example.
February 23, 2005 at 8:28 am
See http://support.microsoft.com/kb/814113/EN-US/.
I've used a package that transforms out to ~140 fixed fields, a total of about 1650 characters wide. I recently also set up an import from fixed field with...
February 17, 2005 at 6:26 pm
Thanks for your suggestions. I think the problem was that it just wasn't able to run the packages using dtsrun.exe.
I subsequently discovered that another SQL instance on that machine (that...
February 15, 2005 at 12:17 pm
It sounds like you might want this more automated, but if this is for occasional use you can script out all the functions by right clicking on the DB name in...
February 10, 2005 at 12:54 pm
No, I didn't try a backup. If I understand corrrectly, a main concern is the overwriting of the actual 1am tran log back up.
So, you could set up a job...
October 28, 2004 at 9:47 am
Thanks Greg.
After further testing, it appears that SQL Server sees that the job has already been run based on the date last run, and does not run it again.
(I set up a...
October 27, 2004 at 1:25 pm
This works:
use northwind
declare @searchtext varchar(10)
set @searchtext='the'
set @searchtext='%'+@searchtext+'%'
select * from customers
where companyname like @searchtext
... but I don't have full text set up to test with freetexttable. After...
September 15, 2004 at 1:22 pm
Before insert:
set @searchtext='%'+@searchtext +'%'
Bill
September 14, 2004 at 12:15 pm
See:
http://www.sqlservercentral.com/columnists/cmiller/dumpsqlpermissions.asp
Also, see sp_helprotect.
Bill
August 23, 2004 at 11:21 am
First, load into a staging table. Then you can use code like this:
-- Delete duplicates from mytable
alter table mytable
add id [int] IDENTITY (1, 1) NOT NULL
go
if...
August 11, 2004 at 10:19 am
Yes, this is trickier than I first thought it would be.
It looks like those empty fields are actually filled with spaces. I forgot to suggest...
August 6, 2004 at 2:20 pm
Sorry. I didn't do enough testing. My test data didn't have any contiguous empty/null fields.
After further testing:
SELECT replace(replace(
isnull(replace([c1],' ','#'),'#')
+','+isnull(replace([c2],' ','#'),'#')
+','+isnull(replace([c3],' ','#'),'#')
+','+isnull(replace([c4],' ','#'),'#')
+','+isnull(replace([c5],' ','#'),'#'),'#,',''),',#','')
FROM [recs]
The '#' is just a temporary...
August 6, 2004 at 1:01 pm
Viewing 15 posts - 16 through 30 (of 98 total)