Viewing 15 posts - 31 through 45 (of 149 total)
Doug,
There is no way that I know of to do what you want to acheive, which is to dynamically change the variable name and use the same insert statement for...
April 22, 2008 at 10:32 am
Not sure just what you are asking about the 'Filters'.
Are you trying to insert the select statement from each If block into #DLFiltered, insert the select statement into another table,...
April 22, 2008 at 7:26 am
I am making a couple assumptions here:
1. the @intId is the primary key from the Master Table
2. You will have a max of 4 child records to the...
April 21, 2008 at 1:54 pm
Instead of:
SELECT {list of fields}
INTO {temp table}
FROM ....
try:
INSERT INTO {temp table} ({list of fields from the temp table})
SELECT ...
FROM ....
Dave
April 21, 2008 at 12:15 pm
Matt,
At least they handed you a SQL Server book to start with. All they gave me was the instructions: 'Here is a SQL Server database. Make it...
April 21, 2008 at 12:01 pm
Sure,
Create the Temp table with a CREATE TABLE
and then do an INSERT INTO instead of SELECT INTO
Dave Novak
April 21, 2008 at 11:55 am
RyanRandall (4/21/2008)
1 or -1? Anyway, here's one way...
SELECT blah FROM blah WHERE IsValid = 1 AND (@SiteNumber = -1 OR SiteNumber = @SiteNumber)
I am not sure on this, but I...
April 21, 2008 at 11:52 am
john.arnott (4/21/2008)
April 21, 2008 at 11:36 am
I would do this as two SQL statements. The first one is an update statement to set the flag in TMain to 1 or Y for a match in...
April 21, 2008 at 11:26 am
Not that I know of with out reviewing the SP you are calling.
April 18, 2008 at 1:30 pm
Basically, if there are two datafiles for a database, you want two @WithMove input parameters. If there are three, then three @WithMove input parameters. and etc...
You could do...
April 18, 2008 at 1:13 pm
Replace the select statement in the SP with the following IF block:
IF (@ItemName IS NULL OR @ItemName = '')
AND (@ItemGroup IS NULL OR @ItemGroup = '')
AND (@ItemPrice IS NULL OR...
April 18, 2008 at 10:36 am
I have never been a fan of dynamic SQL when I do not have to. There is a solution to this as a SP that does not need dynamic...
April 18, 2008 at 9:07 am
check out CHARINDEX(param1, param2, param3)
param1 -- [string expression] --What you are looking for. In your sitaution ','
param2 -- [string expression/column] --What to search for param1 in
param3 -- [int]...
April 17, 2008 at 8:02 am
It looks like you have multiple titles for your consultants in the:
sharedDimension..DimConsultantTitle s ON t.CurrentLevelXID = s.XID
Is it possible for your consultants to have multiple active Job Titles?
or is there...
April 17, 2008 at 7:46 am
Viewing 15 posts - 31 through 45 (of 149 total)