Subject | Re: [firebird-support] Problem with FIRST x SKIP y |
---|---|
Author | Pavel Menshchikov |
Post date | 2005-03-28T14:36:53Z |
Hello Kiril,
s> I am trying to use the FIRST x SKIP y syntax and I see some strange
s> problem:
s> The SELECT without FIRST,SKIP returns 6070 rows. Here is example of
s> the select:
s> select distinct messages.*, msg_to.to_email, msg_to.to_name,
s> msg_to.to_type from messages,msg_to where (messages.common_id =
s> msg_to.common_id) order by messages.msg_key asc, msg_to.to_type desc
Try explicit joins:
select distinct messages.*, msg_to.to_email, msg_to.to_name, msg_to.to_type
from messages
inner join msg_to on (messages.common_id = msg_to.common_id)
order by messages.msg_key asc, msg_to.to_type desc
HTH
--
Best regards,
Pavel Menshchikov
http://www.ls-software.com
s> I am trying to use the FIRST x SKIP y syntax and I see some strange
s> problem:
s> The SELECT without FIRST,SKIP returns 6070 rows. Here is example of
s> the select:
s> select distinct messages.*, msg_to.to_email, msg_to.to_name,
s> msg_to.to_type from messages,msg_to where (messages.common_id =
s> msg_to.common_id) order by messages.msg_key asc, msg_to.to_type desc
Try explicit joins:
select distinct messages.*, msg_to.to_email, msg_to.to_name, msg_to.to_type
from messages
inner join msg_to on (messages.common_id = msg_to.common_id)
order by messages.msg_key asc, msg_to.to_type desc
HTH
--
Best regards,
Pavel Menshchikov
http://www.ls-software.com