Viewing 15 posts - 1 through 15 (of 48 total)
sorry, just curious : design of identity as PK & timestamp/datetime [convert(datetime, getdate(), 21)] as clustered key for those heavily-relied-on-date table, i think it will improve the perf on...
November 28, 2008 at 8:59 pm
Michael Valentine Jones (11/25/2008)
Lynn Pettis (11/25/2008)
...Besides, this discussion has remained relatively positive (so far)...
In that case, let me jump in.
There are many opinions of this subject, but I am...
November 27, 2008 at 6:40 am
you are right. I checked the execution plan and it does not differ much, thanks.
September 2, 2008 at 4:28 am
the one I could find is:
insert @SSNField (N, V_xml)
--select N, D from openxml(@iDoc, '/SerialNumber/S') with (N varchar(200) '@Descr', D varchar(800) 'text()')
select
tab.col.value('@Descr', 'varchar(100)'),
convert(varchar, @xml.query('/SerialNumber/S/text()'))
from
@xml.nodes('/SerialNumber/S') tab(col)
but I would...
September 2, 2008 at 4:21 am
Maybe, but the data can filtered with identity, should be unique enough.
select TOP 1 PARTNumber from AAA where [ID]=@PartID
September 1, 2008 at 11:11 pm
Jeff Moden (9/1/2008)You must either at TOP 1 or, more likely, some more stringent criteria to the FROM clause of each SELECT... THAT is your performance problem.
using top 1 maybe...
September 1, 2008 at 6:06 pm
Quatrei.X (9/1/2008)
Simple IF or case:
IF (...)
....
ELSE IF (...)
...
ELSE
....
I realy don't know if i named them right but could you tell me which one of these three examples do...
September 1, 2008 at 6:37 am
Hi Quatrei.X, thanks for your reply.
Sorry, maybe i should mention earlier. Actually inside the 'var5', it could be more that one output values returned. It makes "CASE" statement nearly impossible,...
August 31, 2008 at 11:16 pm
I get 1469283328 for that. Sorry I do not quite understand what you are trying to explain. Can elaborate more?
August 31, 2008 at 10:54 pm
hi Lowell, Carl Federl, thanks for your suggestion. Althought the actual case is like similar to what Lowell think of ( and could be only choice), but using dynamic...
August 30, 2008 at 7:46 am
I intend to do something like this:
SELECT @FValue =
CASE @FieldName
WHEN 'var1'THEN (select Col1 from Table1)
WHEN 'var2'THEN (select Col2 from Table1)
WHEN 'var3'THEN (select Col3 from Table1)
WHEN 'var4'THEN (select Col4 from...
August 29, 2008 at 3:35 am
The original SP is something like this and need to be fine-tuned:
if @FieldName='var1'
select @FValue = Col1 from Table1
else if @FieldName = 'var2'
select @FValue = col1 from Table2
else if @FieldName =...
August 29, 2008 at 2:42 am
Viewing 15 posts - 1 through 15 (of 48 total)
This website stores cookies on your computer.
These cookies are used to improve your website experience and provide more personalized services to you, both on this website and through other media.
To find out more about the cookies we use, see our Privacy Policy