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: Need to check and remove details

Re: Need to check and remove details

From: Jimbo <threepio23_at_yahoo.com>
Date: Thu, 2 Jan 2003 21:34:47 +0000 (UTC)
Message-ID: <av2b9n$rtn$1@knossos.btinternet.com>


Sorry for being a bit vague, I haven't posted a great deal in here.

I am using SQL Plus in Oracle 9i.

The columns I have in my supplier table are as follows: SUPNO
SUPNAME
SUPADD
SUPPCODE
PAYTERMS I also have a table called PURORDERUNPRI where I can find out what suppliers have supplied to the company within the last year because it has the supplier number and the date of the order of each part. Here are the columns for this table:
PARTNO
PURORDERDATE (e.g. 21-jun-02)
UNPRI
SUPNO I want to prompt the user to enter a supplier number (e.g. 3332), and then check whether that supplier has supplied within the last twelve months, if it hasn't, it will remove it's details. If it has, it will leave it as it was.
"DA Morgan" <damorgan_at_exesolutions.com> wrote in message news:3E149E98.7346EB00_at_exesolutions.com...
> Jimbo wrote:
>
> > In my database I want to produce some SQL code that checks my supplier
> > records on an annual basis to find out if it HASN'T supplied anything to
the
> > company. If it hasn't, I want it to remove the details of the supplier
from
> > the company. I am wondering if anyone could tell me what type of code I
> > would need to do this, or even better, some example of the code that
could
> > do this type of thing.
> >
> > Thanks
>
> A simple SQL statement will easily work.
>
> To write it for you ... or even to guess at what to write ... would
require
> knowing the structure of the table(s) involved.
>
> And the version of Oracle, etc. wouldn't hurt either.
>
> Daniel Morgan
>
Received on Thu Jan 02 2003 - 15:34:47 CST

Original text of this message

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