Viewing 15 posts - 211 through 225 (of 252 total)
Some of our developers decided to break up dbs into dependent pairs. They append the word "_stage" to one of them. The pair exists in the dev, staging,...
October 16, 2003 at 8:38 am
One of our databases is used to control access and resides on many of our SQL Servers. From time to time, a request comes through to refresh a set...
October 16, 2003 at 8:04 am
You can also use a different query in each case. I resort to this when I can't get one query to execute quickly for all cases. This query...
October 16, 2003 at 7:43 am
Connections, file paths, exchange profiles, etc. in your package will probably not be valid at the destination. If you know what they should be, disconnected edit can be used...
October 15, 2003 at 11:30 am
-- This is not elegant.
declare @HireDate as datetime
set @HireDate = '1/1/1990'
-- Pre-calculation
declare @Now as datetime
declare @NowPlus30Days as datetime
declare @dy1 as int, @dy2 as int -- for the day...
October 15, 2003 at 11:16 am
quote:
SELECT FName, LName, Hire_Date
FROM Employee
WHERE DATEDIFF(dd,GETDATE(),DATEADD(yy,DATEDIFF(yy,Hire_Date,GETDATE()),Hire_Date)) BETWEEN 0 AND 30--Jonathan
I do...
October 15, 2003 at 11:00 am
quote:
The two MAIN reasons I like identity columns is that you can put a clustered index on them and your inserts will...
October 14, 2003 at 10:20 am
Thanks for the links. DevHood seems the most similar; however, it's odd that this site rates me as a level 1 peasant. I resent that - as a...
October 14, 2003 at 8:29 am
You can also use EM Import/Export or the DTS copy sql server objects task. There is a point at which you can select the objects to copy - rather...
October 13, 2003 at 10:08 am
More fun...
create table #TableData (
Manufacturer varchar(12) NOT NULL,
Color varchar (15) NOT NULL
) ON [PRIMARY]
insert into #TableData (Manufacturer, Color)
select 'Toyota','Blue'
union all
select 'Toyota','Blue'
union all
select 'Honda','Red'
union all
select 'Honda','Red'
union all
select 'Honda','Green'
union all
select 'Ford','White'
union...
October 9, 2003 at 11:23 am
It would be nice to have an aggregate "SUM" that worked on strings. I've needed it before. Perhaps a pivot table like approach? I use the trim...
October 9, 2003 at 11:16 am
In general, if you need more data from the one record in the group, use a derived table to get the key and join. For example,
SELECT A.Id, A.Name,...
October 9, 2003 at 9:47 am
The MDACs are different.
sp3 - MDAC 2.7 sp1
sp3a - MDAC 2.7 sp1 refresh
Its not MDAC sp1, sp2, or sp1a - it's "refresh". Perhaps MDAC 2.7 sp1...
October 9, 2003 at 9:37 am
I like to put the drop in myself. Sometimes to debug a procedure, I copy it into QA and comment out the stored procedure specific stuff (changing the params...
October 9, 2003 at 9:02 am
One more thing. If your developers give you scripts to move procedures, make sure any permission grants are outside the procedure, not part of the procedure. Also, do...
October 9, 2003 at 8:45 am
Viewing 15 posts - 211 through 225 (of 252 total)