Viewing 15 posts - 4,546 through 4,560 (of 7,597 total)
Select order_number,
min(serial_number) AS serial_number_min,
max(serial_number) AS serial_number_max,
min(status) AS status_min,
max(status) AS status_max
from...
December 14, 2015 at 3:24 pm
Sergiy (12/14/2015)
DECLARE @ProcName sysname, @Param INT
SELECT @ProcName = OBJECT_NAME(@@PROCID), @Param = 1000
IF HOST_NAME() = 'My Test Host'
RAISERROR ('Started procedure %s, Parameter supplied:...
December 14, 2015 at 3:05 pm
If you have indexes keyed on tbl2.col1 and on tbl3.col1, then it almost has to be some type of blocking. You could try the query below, might work better,...
December 14, 2015 at 10:12 am
Do you have a nonclustered, nonfiltered index containing tbl2.col1?
A nonclustered, nonfiltered index containing tbl3.col1?
December 14, 2015 at 9:55 am
If you need to know if all the lines have only product_type = 'A' on any kind of regular basis, I'd denormalize and add a flag to the invoice header,...
December 14, 2015 at 9:53 am
Jeff Moden (12/12/2015)
ScottPletcher (12/10/2015)
December 14, 2015 at 8:55 am
Here's a few notes on the conversion process, and a sample of the first table converted.
The double quotes are fine, as long as "SET QUOTED_IDENTIFIER ON" is active, which it...
December 11, 2015 at 2:20 pm
Is the log size growing, or just the % used? You don't want the log size to grow dynamically, as that will slow down the database. But tempdb...
December 11, 2015 at 9:15 am
If it's for a single, specific stored proc, could you just add code to that proc to save the parameter values that came in? You could even have an...
December 11, 2015 at 9:12 am
Do you have a unique index on Word? You don't want SQL to have to sort the words every time -- that will be extremely slow. Also, if...
December 10, 2015 at 9:26 pm
The clustered index is definitely correct. Date will be mildly more efficient than datetime, but it's not enough of a difference to be a big deal.
Make sure the fillfactor...
December 10, 2015 at 8:43 pm
kiril.lazarov.77 (12/10/2015)
ScottPletcher (12/9/2015)
December 10, 2015 at 8:19 pm
kiril.lazarov.77 (12/10/2015)
ScottPletcher (12/9/2015)
December 10, 2015 at 8:19 pm
If it's always a "w" followed by a digit or digits, perhaps just this?!:
declare @testdata table(expression varchar(500))
insert into @testdata values('[w1+w2+w3/5]'),('[(w1+w2+w3)/5]'),('[(w4-w5*w6)/5]')
insert into @testdata values('w1')
insert into @testdata values('2w3')
insert into @testdata values('4+w5')
select 'w'...
December 10, 2015 at 7:50 pm
Cluster the table on the month.
I'd include at least the year with the month. Best is to use a column of type date, but if necessary you can use...
December 10, 2015 at 7:43 pm
Viewing 15 posts - 4,546 through 4,560 (of 7,597 total)