[INTERFACES]- SELECT statement - Mailing list pgsql-interfaces

From Margarita Barvinok
Subject [INTERFACES]- SELECT statement
Date
Msg-id Pine.SOL.3.96-4hack.990224134002.12574D-100000@sewerurchin.math.lsa.umich.edu
Whole thread Raw
Responses Re: [INTERFACES]- SELECT statement
List pgsql-interfaces
Hi,

I have two questions.
1)
 How can I realize this query in C-Embedded SQL?

SELECT MAX (score)
  FROM report
  WHERE uname = 'xxxxxxx'
  AND exam_id IN
      ( SELECT exam_id
        FROM exam
        WHERE name = 'yyyy'
      )

I used DECLARE CURSOR and FETCH for second SELECT statement.
But I don't know how to use WHERE ... IN clause.

2)

I need to create weekly report. I would like to ask users to enter just
one date (for example, Monday of the week).
How can I select information from database for a whole week?

Thank you

-Margarita





pgsql-interfaces by date:

Previous
From: markh@clockworkweb.com (Mark Himsley)
Date:
Subject: Re: [INTERFACES] What's that query limit again?
Next
From: Tom Lane
Date:
Subject: Re: [INTERFACES] What's that query limit again?