Viewing 15 posts - 6,871 through 6,885 (of 49,552 total)
Replace AccountMock with AccountChk in both subqueries. I got the table names mixed up.
Gail Shaw
Microsoft Certified Master: SQL Server, MVP, M.Sc (Comp Sci)
SQL In The Wild: Discussions on DB performance with occasional diversions into recoverability
January 6, 2015 at 5:25 am
Don't use that, it'll be horribly slow. Look for the delimited8kSplit function on this site.
Gail Shaw
Microsoft Certified Master: SQL Server, MVP, M.Sc (Comp Sci)
SQL In The Wild: Discussions on DB performance with occasional diversions into recoverability
January 6, 2015 at 4:56 am
Open up Books Online. Look at the syntax for a SELECT. Look at the examples on the page. Look at your selects and see what's different.
Edit: And buy yourself a...
Gail Shaw
Microsoft Certified Master: SQL Server, MVP, M.Sc (Comp Sci)
SQL In The Wild: Discussions on DB performance with occasional diversions into recoverability
January 6, 2015 at 4:54 am
Tell your manager that a trigger is not the appropriate solution to this. This should be checked in the front end or at the latest in the procedure which does...
Gail Shaw
Microsoft Certified Master: SQL Server, MVP, M.Sc (Comp Sci)
SQL In The Wild: Discussions on DB performance with occasional diversions into recoverability
January 6, 2015 at 4:35 am
Um.......
Replace <column list> with the list of columns. It's a place holder.
And open up Books Online (F1 from in Management Studio) and read over basic SQL syntax for selects...
Gail Shaw
Microsoft Certified Master: SQL Server, MVP, M.Sc (Comp Sci)
SQL In The Wild: Discussions on DB performance with occasional diversions into recoverability
January 6, 2015 at 4:31 am
If you don't want a tested solution, fine (I'm not spending extra time trying to work out data types and write up insert statements)
Something like
INSERT INTO AccountMocktable <column list>
SELECT <column...
Gail Shaw
Microsoft Certified Master: SQL Server, MVP, M.Sc (Comp Sci)
SQL In The Wild: Discussions on DB performance with occasional diversions into recoverability
January 6, 2015 at 3:42 am
No, it won't (won't even compile)
Table definitions (CREATE TABLE ...), sample data (INSERT INTO ...) and expected output please
Gail Shaw
Microsoft Certified Master: SQL Server, MVP, M.Sc (Comp Sci)
SQL In The Wild: Discussions on DB performance with occasional diversions into recoverability
January 6, 2015 at 2:18 am
Yes, that will get the job running (although whether that's the only piece of code withe problem is another matter), you still should go back and take all the stuff...
Gail Shaw
Microsoft Certified Master: SQL Server, MVP, M.Sc (Comp Sci)
SQL In The Wild: Discussions on DB performance with occasional diversions into recoverability
January 6, 2015 at 2:16 am
More readable:
SELECT DISTINCT
C1.containerCode,
C1.containerName,
(SELECT C1.containerCode AS containerCode,
...
Gail Shaw
Microsoft Certified Master: SQL Server, MVP, M.Sc (Comp Sci)
SQL In The Wild: Discussions on DB performance with occasional diversions into recoverability
January 6, 2015 at 1:53 am
VARCHAR declared without a length is VARCHAR(1), so any values assigned to that get truncated silently to 1 character.
p.s. @FromDate and @ToDate should be DATETIME, not strings.
Gail Shaw
Microsoft Certified Master: SQL Server, MVP, M.Sc (Comp Sci)
SQL In The Wild: Discussions on DB performance with occasional diversions into recoverability
January 6, 2015 at 1:40 am
Table definitions (CREATE TABLE ...), sample data (INSERT INTO ...) and expected output please.
Gail Shaw
Microsoft Certified Master: SQL Server, MVP, M.Sc (Comp Sci)
SQL In The Wild: Discussions on DB performance with occasional diversions into recoverability
January 6, 2015 at 1:38 am
Jeff Moden (1/5/2015)
For "only" 500GB, Federal Express works wonders. I did that for a different site several years ago.
Last time I set up mirroring, 75GB database, 25km away, we...
Gail Shaw
Microsoft Certified Master: SQL Server, MVP, M.Sc (Comp Sci)
SQL In The Wild: Discussions on DB performance with occasional diversions into recoverability
January 5, 2015 at 8:52 am
Is google broken today?
https://www.google.com/?q=drop+statistics+sql+server#q=drop+statistics+sql+server
Gail Shaw
Microsoft Certified Master: SQL Server, MVP, M.Sc (Comp Sci)
SQL In The Wild: Discussions on DB performance with occasional diversions into recoverability
January 5, 2015 at 4:19 am
zi (1/5/2015)
any help please
Patience. I'm posting during lunch break, my job takes priority.
To be honest, I'd recommend dropping every single thing that DTA created. You should NEVER blindly implement recommendations,...
Gail Shaw
Microsoft Certified Master: SQL Server, MVP, M.Sc (Comp Sci)
SQL In The Wild: Discussions on DB performance with occasional diversions into recoverability
January 5, 2015 at 4:06 am
DROP VIEW <Name of the View>
Gail Shaw
Microsoft Certified Master: SQL Server, MVP, M.Sc (Comp Sci)
SQL In The Wild: Discussions on DB performance with occasional diversions into recoverability
January 5, 2015 at 3:36 am
Viewing 15 posts - 6,871 through 6,885 (of 49,552 total)