Viewing 15 posts - 1 through 15 (of 26 total)
I posed this question mid-way through another thread about a week ago and Paul gave me the following reply this morning.
Note that this is straight from the other thread and...
October 16, 2009 at 7:08 am
Paul-
Thanks for the input! This has been bothering me for a while now. This makes sense though, we had a sneaking suspicion that this may...
October 16, 2009 at 7:05 am
For the first question, look up ROW_NUMBER(), you should be able to apply it to a query pretty easily.
For the second, i'm not too sure what exactly you're looking for...
BUT,...
October 13, 2009 at 9:34 am
Minaz,
FETCH NEXT FROM RepliesCUR into @cat,@subcat,@topic,@sub,@body
Set @tid = (select topic_id
from phpbb_topics
where Forum_id =@subid
and topic_title =@topic)
insert into phpbb_posts(forum_id,topic_id,post_subject,post_text)
values (@subid,@tid,@sub,@body)
It looks like the select is not returning any values in your table...
October 9, 2009 at 1:08 pm
While we're on the topic of computed columns and execution plans, I have a question that has been nagging at me.
If you check out the execution plan of the last...
October 8, 2009 at 11:16 am
Wow.. that really took me by surprise, i didn't expect that!
I see what you're saying about the sorting after the math is done and not just sorting the column- but...
October 8, 2009 at 11:05 am
mtassin (10/8/2009)
It's not the Order by so much as the ABS function in the Order by I'm pretty sure.
But wouldn't it only need to ABS() the rows that meet the...
October 8, 2009 at 9:20 am
Jeff- Thanks for the follow up, good to know I wasn't too far off 🙂
I do have a question though- why would the order by cause a scan on the...
October 8, 2009 at 8:03 am
where ((avg_cost - std_cost)*in_stock >= @a
or (avg_cost - std_cost)*in_stock <= -1* @a)
will cause a scan every time, as well as the computation.
I don't know...
October 7, 2009 at 1:10 pm
Troy,
I'm a litte fuzzy on what exactly you need done here. The attached script is assuming that you're looking for an animal's ADG over every...
September 18, 2009 at 1:25 pm
I agree that this looks a lot like homework, but I'll bite and at least give you a couple functions to look into.
Note that this is taking some guesses as...
September 17, 2009 at 11:39 am
Dunster-
From what I understand you've got the following: A table that ends at say 20,000 in an "identity column" and you'd like to start from...
September 15, 2009 at 12:12 pm
EDIT: Another instance of me typing faster than I can think. Sorry.
September 15, 2009 at 11:39 am
Definitely an odd problem, as for why the 10 is showing up after the 1, it looks like since you've got it set to a char, it's sorting it in...
September 14, 2009 at 9:43 am
Viewing 15 posts - 1 through 15 (of 26 total)