Oracle FAQ Your Portal to the Oracle Knowledge Grid
HOME | ASK QUESTION | ADD INFO | SEARCH | E-MAIL US
 

Home -> Community -> Usenet -> c.d.o.misc -> Re: please help with query

Re: please help with query

From: Mike Dodd <doddme_at_mindspring.com>
Date: Wed, 09 Dec 1998 23:16:43 GMT
Message-ID: <367204a5.3212349@news.mindspring.com>


Sounds like homework

On Tue, 8 Dec 1998 20:42:50 -0800, Pornpira Vachareeyanukul <pornpira_at_beta.tricity.wsu.edu> wrote:

>Hi
>I need some help with the query statement;
>
>table user
>ssn varchar2(9),
>first_name varchar2(20),
>last_name varchar2(20)
>
>table room
>room_no varchar2(10),
>teacher_ssn varchar2(9),
>teacher_assistant_ssn varchar2(9)
>
>I'm trying to select all classrooms from room table and get the teacher
>and teacher assistant first and last name. I'm having the problem writing
>query so that just in case of there's teacher_ssn in the room table but no
>ssn in the user table and I can get that room eventhough there's no record
>of that teacher in the user table.
>
>Here's what I'm trying to do
>Select r.room_no, u1.first_name, u1.last_name,
> u2.first_name, u2.last_name
> from room r, user u1, user u2
> where r.teacher_ssn = u1.ssn
> and r.teacher_assistant_ssn = u2.ssn
> group by r.room_no
>;
>
>
>And I have another question about how to compare 2 counts;
>I have 2 tables
>k_follow which contain msg_id and the follows_id
>msg_id,
>follows_id
>
>and k_group
>msg_id
>news_id - newsgroup that msg is posted to
>
>Message is posted to various newsgroup and I have to compare if the
>follow-up message is posted to more newsgroup than the original message.
>I've been working on it and I've always got error message saying parser
>error.
>Please help me.
>
>Thank you in advance.
>Mimi
Received on Wed Dec 09 1998 - 17:16:43 CST

Original text of this message

HOME | ASK QUESTION | ADD INFO | SEARCH | E-MAIL US