This content has been marked as final. Show 10 replies
OMD wrote:what datatype are _Position columns?
I have two tables:
Positions_tbl (Start_Position, End_Position)
X_Positions (X_Name, X_Position)
I need to find how many X_Position lies between each Start_Position, End_Position
please post complete CREATE TABLE statements for both tables.
Status Level: Newbie
Registered: Aug 14, 2006
Total Posts: 254
Total Questions: 9 (8 unresolved)
Now I understand why.
If you don't want to answer my question then keep your judgment for yourself, No need to post my info and and then as smart person say "Now I understand why". You definitely don't know why. I don't know who you are and you don't know me. So, just be respectful to the others.
Your forum history is public information that any registered user can see.
As a forum user you are expected to mark your questions ANSWERED when they have been. When you don't do that it wastes the time of people that start reading the thread to try to help.
When someone sees an unanswered thread and thinks they can help it is very frustrating to read the entire thread only to find out that it appears to have already been answered by one of the previous responders. The problem is that since you didn't mark the thread ANSWERED there is no way to tell if you are just being lazy or it really hasn't been answered and you need more help.
Then when you cop an attitude like you just did in this response it only reinforces that maybe you are just being lazy and selfish; asking for help from others but not willing to acknowledge the help when you get it. That will cause some people to just not want to try to help you at all. So in addition to potentially wasting the time of others you are also really hurting yourself.
So, if you really are a good steward of the forums and want to get help in the future I suggest that you revisit those previous threads and mark then ANSWERED if they have been.
Solomon Yakobson wrote:Shouldn't that be count(x.x_position) rather than count(*)? Count(*) will show 1 when it should be 0.
Use outer join:
select p.start_position, p.end_position, count(*) from positions_tbl p left join x_positions x on x.x_postion between p.start_position and p.end_position group by p.start_position, p.end_position order by p.start_position, p.end_position /