Re: desperate for help...

2001-03-07 Thread Geoff Coffey
on 3/6/01 9:35 PM, Chris Toth at [EMAIL PROTECTED] wrote: > Ok, I've been battling this SELECT statement for the better part of the day. > > The SELECT statement is this: > > SELECT DISTINCT request.id AS requestid, request.date, request.type, > request.status, > faculty.f_name, faculty.l_name,

Re: desperate for help...

2001-03-07 Thread kentj
I do not think that this can be solved using only SQL. Your system design my require you to use one query for the display and another for edit checking in order to achieve your goal. Chris Toth wrote: > Kentj > > Ok, I understand. I thought DISTINCT only worked on the field listed > directly aft

Re: desperate for help...

2001-03-07 Thread kentj
Your query selects eight fields. Your Display shows five fields. The distinct verb works on all eight fields and apparently some of the fields not displayed are different. Limit the query for the display to the five fields displayed and the distinct verb should eliminate the duplicates from the d

Re: desperate for help...

2001-03-07 Thread Chris Toth
I rearranged the query a little: SELECT DISTINCT request.id AS requestid, request.date, request.type, request.status, faculty.f_name, faculty.l_name, action.id AS actionid, faculty.id AS facultyid FROM faculty, request, action WHERE request.id=action.request_id AND request.requested_by=facult

Re: desperate for help...

2001-03-07 Thread kentj
It looks like the addition of the distinct verb should do the job if in fact your query only showed the fields on the display. >From your Sql however you are selecting more fields than are displayed and some of those are different which distinct will still display. Chris Toth wrote: > Ok, I've b