Viewing 15 posts - 301 through 315 (of 321 total)
you* could write one in half a day or an even better one in a full day
* from your post you sound experienced so the T-SQL should be a breeze
January 15, 2008 at 6:47 am
ok, the Jet OLEDB connection is breaking the text file up in to object compenents which are then returned to your query, the order of the columns is never important...
January 15, 2008 at 6:41 am
this works for integer values up to ~700
isnull(ceiling(log(nullif(floor(exp( @value )), 0))), 0)
as I said previously though, I would avoid like the plague
January 15, 2008 at 6:12 am
Hi Adam,
I've seen and made similar work arounds but they look so hacky I can't bring myself to use them in real life applications.
For some complex queries, like this one...
January 15, 2008 at 4:39 am
test it out the second query a little and see what happens 😉
January 13, 2008 at 11:54 pm
No problem 🙂
remember I said how if i found a more elegant solution I'd post it.
Well with my mathematical head on this morning a slightly neater approach dawned on me:
take...
January 10, 2008 at 8:41 am
Change NCHAR to VARCHAR
works for me 🙂
Edit: Beaten to it!!
January 9, 2008 at 9:22 am
It was correct, its your specifications that were wrong 😛
select top 1
date, session
from #rr
where convert(varchar, date, 103) + '-'+ cast(session...
January 9, 2008 at 7:34 am
select top 1
date, session
from #rr
where session not in (select session from #rr where message = 'error')
order by date desc
January 9, 2008 at 7:09 am
here's a good article on how to post:
http://www.sqlservercentral.com/articles/Best+Practices/61537/
as you're new to SQL, have a look at my first reply if any confuses you then you need to...
January 9, 2008 at 6:57 am
Nice bit of your code in your post, certainly speeds things up! 🙂
select top 1
date, session
from #rr
where message <> 'error'
order...
January 9, 2008 at 6:52 am
Well this has been fun and brightened up a quiet morning 😀
Heres a shift calculating function you can use:
alter function dbo.calc_shift (@Time_start as datetime, @Time_end as datetime, @shift_start as int,...
January 9, 2008 at 6:41 am
use a distinct on the select from table A:
Select Distinct col1, col2, col3
from tableA
add a clause if you want to exclude everytihng from tableB
Select Distinct a.col1, a.col2, a.col3
...
January 9, 2008 at 5:21 am
Here's a more complete solution:
select
-- zero column, between 3pm and 11pm
-- first 2 cases, work...
January 9, 2008 at 4:32 am
Viewing 15 posts - 301 through 315 (of 321 total)