Oracle FAQ | Your Portal to the Oracle Knowledge Grid |
![]() |
![]() |
Home -> Community -> Usenet -> c.d.o.tools -> Re: stupid sql question - please help
Or try
select * from doc_prop where NVL(archive_flag,'N) = 'N'
Arie Mars
arie_at_pca-online.nl
Sybrand Bakker <postbus_at_sybrandb.demon.nl> schreef in berichtnieuws
968879782.27616.0.pluto.d4ee154e_at_news.demon.nl...
> And the others have set the archive_flag to NULL?
>
> Try
> select * from doc_prop
> where archive_flag != 'Y' or archive_flag is null;
>
> Hth,
>
> Sybrand Bakker, Oracle DBA
>
>
> "N7SF" <n7sf_at_hotmail.com> wrote in message
> news:SERv5.96$jJ5.10532_at_bos-service2.ext.raytheon.com...
> > I have a table that looks like this:
> > SQL> desc doc_prop
> > Name
> > ------------------
> > DOC_ID
> > RESTORE_FLAG
> > DATA_FLAG_NUM
> > LOE_7DAY
> > ARCHIVE_FLAG
> > MODIFY_ID
> >
> > I have a few records in the table and one of the records has the
> > archive_flag set to 'Y'
> >
> > I'm trying to select all the records that do not have the 'Y' set. Yet
> > nothing I try seems to work.
> >
> > I have tryed:
> > select * from doc_prop
> > where archive_flag != 'Y'
> >
> > this returns nothing
> > I've tryed several things all fall.. why? what is the correct way to see
all
> > the records that don't have a archive_flag set to 'Y'?
> >
> > Thanks for any help.
> >
> >
> >
>
>
Received on Thu Sep 14 2000 - 03:59:25 CDT
![]() |
![]() |