Viewing 15 posts - 3,616 through 3,630 (of 15,381 total)
chgn01 (11/11/2014)
November 11, 2014 at 3:31 pm
chgn01 (11/11/2014)
Order BY is last, Top should before it.
No that wouldn't work. How would you know what rows to retrieve when using TOP if you had not already determined the...
November 11, 2014 at 10:56 am
Nadrek (11/11/2014)
November 11, 2014 at 9:45 am
arrjay (11/11/2014)
Or use the undocumented EXEC sp_MSforeachdb command...
There are some issues with that procedure. Check out this article. http://sqlblog.com/blogs/aaron_bertrand/archive/2010/12/29/a-more-reliable-and-more-flexible-sp-msforeachdb.aspx
November 11, 2014 at 7:33 am
Nita Reddy (11/11/2014)
SELECT db_name(), dbschemas.[name] as 'Schema',
dbtables.[name] as 'Table',
dbindexes.[name] as 'Index',
indexstats.avg_fragmentation_in_percent,
indexstats.page_count
FROM sys.dm_db_index_physical_stats (DB_ID(), NULL, NULL, NULL, NULL) AS indexstats
INNER...
November 11, 2014 at 7:23 am
The topic is certainly relevant but in a QOTD format it is absurd due to the formatting. Add to that the answers are duplicated and you end up with a...
November 11, 2014 at 7:19 am
patrickmcginnis59 10839 (11/10/2014)
November 10, 2014 at 12:42 pm
SQL_Kills (11/10/2014)
Thanks Sean, but getting the following errorConversion failed when converting date and/or time from character string.
You probably have to set the dateformat first or this will fail. It works...
November 10, 2014 at 12:39 pm
Here is how you could use the existing data to do what you are trying to do.
SELECT
left(log_string,10) --This is what you are trying to convert to a date
,...
November 10, 2014 at 10:41 am
SQL_Kills (11/10/2014)
I get the following error when trying to run the below SQL any ideas on how to get round this?
The conversion of a varchar data type to a datetime...
November 10, 2014 at 10:37 am
As I said you need to use modulo here.
Something like this.
where datepart(week, dato) % 2 = 0
Please note the above is nonsargable and will force a scan on the entire...
November 10, 2014 at 7:12 am
Edvard Korsbæk (11/10/2014)
'
I have a date stored in a field dato [DATETIME]
How do i catch about this date is in an even or in an odd week ...
November 10, 2014 at 7:01 am
manie (11/10/2014)
I have a system where people can apply for registration and also a registration fee is involved. The screen where the application is captured has a couple of...
November 10, 2014 at 6:58 am
peter478 (11/10/2014)
2. concerning global temp table ##amp you are right , but when I change it to #amp I can get output, no feedback (select * from #amp)
with global...
November 10, 2014 at 6:50 am
peter478 (11/7/2014)
just this:
@group = A
@SQLString = @SQLString...
November 7, 2014 at 4:07 pm
Viewing 15 posts - 3,616 through 3,630 (of 15,381 total)