Viewing 15 posts - 1 through 15 (of 23 total)
Yep, that is what I was hoping would happen. Should I just use a table to store the value if I want it to persist?
July 28, 2006 at 11:28 am
I'm confused about splitting the list values. Why is this done?
July 7, 2005 at 8:11 am
Remi, can you walk me through your solution?
July 7, 2005 at 7:28 am
From my understanding, every selected field must be part of either the GROUP BY clause or an aggregate function. Can you provide some sample data to explain which field...
July 5, 2005 at 10:32 pm
What about having a second table (ProductSort) that stores your specific sort order...
Product_ID SortOrder
31 1
5 2
7 3
9 4
12 5
Then do your SELECT statement like this...
SELECT * FROM...
July 5, 2005 at 11:40 am
Hi,
Does your unique ID have to be an incremental integer type? If not, I would just concatenate the values of SetCode, SubjectCode and YearCode to generate a unique...
July 5, 2005 at 11:16 am
Here is another dynamic SQL option...
1. Create a temp table that has an identity column (RowNum) and an integer
column (IndValue).
CREATE TABLE #TempTable (
RowNum int Identity (1,1) Not Null,
IndValue int Not...
July 5, 2005 at 10:50 am
Hi,
I would recommend storing all of the shift information in one table adding a field called shift status (with the possible values of worked, cancelled or open). If you have to use...
July 3, 2005 at 11:37 pm
Here's how I did it using a cursor..
CREATE TRIGGER [SendErrorNotification] ON dbo.ClickonError
AFTER INSERT
AS
DECLARE @edit varchar(15)
DECLARE cedit CURSOR FOR
SELECT EditNumber
FROM INSERTED
OPEN cedit
FETCH NEXT FROM cedit
INTO @edit
WHILE @@FETCH_STATUS = 0
BEGIN
--add the...
June 17, 2005 at 3:07 pm
Hi,
You're right. It seems like a catch-22. I was trying to grant permissions in the stored procedure but the user/role doesn't have the rights to assign permissions.
May 19, 2005 at 9:04 am
Ooops. Forgot that I wanted to calculate age from @RptDate, not GetDate().
This works:
SET @strSQL = @strSQL + ' CAST(DateDiff(d,CS.AdmSrvDate, ' + '''' + CONVERT(varchar,@RptDate,101) +''''+ ') AS nvarchar(5)) END'
April 13, 2005 at 10:52 am
Thank you, Frank! This worked:
SET @strSQL = @strSQL + ' CAST(DateDiff(d,CS.AdmSrvDate, GetDate()) AS nvarchar(5))'
April 13, 2005 at 9:52 am
The larger statement as a whole needs to be dynamic. I'm using a stored procedure as a datasource for a Crystal report. The joins in the SQL statement need to change...
April 13, 2005 at 8:23 am
Thanks!
What if I want to use a variable in the DTS, for example, @RptDate, instead of GetDate()?
Brenna
April 12, 2005 at 4:42 pm
Viewing 15 posts - 1 through 15 (of 23 total)