Viewing 15 posts - 18,241 through 18,255 (of 18,923 total)
One simple solution I see is to transform spSEL_Personnel_TEST into a table function that return all the ids.
then simple call
sp_SEL_PProfile_TEST /*no id,*/ 1
Select * from whatever W inner join...
April 5, 2005 at 12:53 pm
One thing that can slow this to a halt is that the transaction log will have to grow a lot to do the update of ALL rows. That's why...
April 5, 2005 at 12:24 pm
Functions are executed on a row by row basis. So if you have 5k rows, sql server will have to execute the function 5k times. This can become a...
April 5, 2005 at 12:14 pm
Here's something that'll work much faster :
Declare @String as varchar(150)
Declare @search as varchar(10)
set @String = 'abcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyz'
set @search = 'a'
Select (DATALENGTH(@String) - DATALENGTH(REPLACE(@String, @search, ''))) / DATALENGTH(@Search) AS Occurences --division...
April 5, 2005 at 11:36 am
Please read this if don't wanna lose your server to an attacker :
The Curse and Blessings of Dynamic SQL
I would strongly suggest that you use the split function...
April 5, 2005 at 11:29 am
NP... some of us have figured out it would be something like this. Glad you did too
.
April 5, 2005 at 11:10 am
I wasn't born stupid - I had to study
You might have studied too hard
. (no hurt intended)
April 5, 2005 at 10:05 am
Well you could always do something like this :
create temp table
check if file exists
set a fiew variables from the temp table
drop the temp table
exec backupProc param1, param2
Or you could...
April 5, 2005 at 10:03 am
Actually the temp objects are destroyed when the connection is closed (destroyed ??), but they are unique to each connection. So 1 or 10 users can create the same...
April 5, 2005 at 9:44 am
Here's a similar exemple I created on ony of my tables
FkQuestion > 0 AND FAIT = 1
OR
ISNULL(FkQuestion, 0) = 0 AND FAIT = 2
Maybe you're still using a varchar column...
April 5, 2005 at 9:35 am
There's just no need for dynamic sql here, check this out :
Declare @Object as varchar(25)
set @Object = 'SysObjects'
Select * from master.dbo.SysObjects where name = 'SysObjects'
UNION ALL
Select * from master.dbo.SysObjects...
April 5, 2005 at 9:24 am
First of all I'd use a look up table for the status info (assuming you could have a 3rd or 4th status eventually), or simply a bit/tinyint column instead of...
April 5, 2005 at 9:10 am
Frank, now I understand why you have so many posts... You can't not get the last word. At this pace you'll be at 5000 posts this afternoon.
April 5, 2005 at 9:02 am
Hehe... it's not over you we're arguing and as far as I know Frank is married with children (new born included).
Have you tested my query on a large table... I...
April 5, 2005 at 8:50 am
Viewing 15 posts - 18,241 through 18,255 (of 18,923 total)