Viewing 15 posts - 2,371 through 2,385 (of 6,036 total)
John Peter Fernandes (5/3/2010)
however if it exists i get...
May 3, 2010 at 2:11 am
INSERT INTO mt_tags(tag,type)
SELECT @tag, @type
WHERE NOT EXISTS (SELECT ID FROM mt_tags WHERE tag=@tag)
SELECT @TagID = ID
FROM mt_tags
WHERE tag=@tag
@TagID will contain correct ID regardless if it's new or...
May 3, 2010 at 12:05 am
1. Make sure you have clustered indexes on column so_timestamp and other columns used in range selection.
2. Don't shrink databases. It's a quite useless exersise.
Unless you want to upgrade disks...
April 21, 2010 at 6:17 pm
SET ROWCOUNT 1
{Do your update as it is}
SET ROWCOUNT 0
April 8, 2010 at 4:43 pm
Make business_day_dt (or whatever the names are in background tables) a 1st column of clustered index on every table.
April 6, 2010 at 6:58 pm
Warning about missing statistics usualy means that your WHERE clause uses non-indexed columns.
Please read the post from Ronald San Juan above and answer the questions in there.
April 5, 2010 at 5:42 pm
You welcome.
And thank you for providing perfect coding and data samples.
It made it really easy to help you.
🙂
April 5, 2010 at 3:28 pm
I guess you update the whole remote table, not only records you want to update.
Try this:
UPDATE dst
...
April 1, 2010 at 4:49 pm
You need to make sure number of columns in the table matches number of columns in the file.
This works perfectly with the file you provided:
if exists (select * from dbo.sysobjects...
April 1, 2010 at 4:44 pm
Jason Selburg (3/29/2010)
Still looking into the "WHY"
It's a bug in SQL Server.
Instead of applying ORDER BY condition to the outcome of OUTER join (as it should be according to ANSI)...
March 29, 2010 at 6:27 pm
Conversions varchar to datetime and back are the worst cpoosible conversions from performance point of view.
They may be very comfortable for a human eye, so keep them where they belong...
March 29, 2010 at 6:10 pm
abu_arqam (3/24/2010)
You can useSELECT ROW_NUMBER() OVER (ORDER BY ColumnName1) As SrNo,ColumnName1,ColumnName2,ColumnName3 from Tablename
Thanks
No, you cannot.
It's SQL 7,2000 - TSQL forum, and ROW_NUMBER() OVER was introduced in SQL...
March 24, 2010 at 3:09 am
What if name variations
Chris Smith
C. Smith
Smith, Chris
belong actually to Christine Smith, not to Christopher Smith?
March 22, 2010 at 8:57 pm
I don't think any universal thing will work here.
Pagination normally goes together with line sorting.
And to define which column to use in ORDER BY you need to change the procedure.
So,...
March 22, 2010 at 3:50 pm
I suppose you have some auto-generator for unique 16-char codes.
Let's say it's encapsulated in function dbo.GenerateUnique16key.
Then you should have something like this:
Create TABLE dbo.AccountIdentifiers (
TwentyTwo...
March 17, 2010 at 10:31 pm
Viewing 15 posts - 2,371 through 2,385 (of 6,036 total)