>Thanks Larry!
>
> It Works !!!
>
> Another question SQL 7.0.
>
> I Need to scan label serial numbers and Return the next Values
> 1 - label exists and is not scanned (ReceivedDate is Null)
> 2 - label exists but is already scanned (ReceivedDate is not Null)
> 3 - Label does not exists
>
>
>Thanks in advance,
>
>I promise to study a lot
>
Martin,
You can use a CASE statement in your SQL statement and the ISNULL() function. Ex.
select isnull(case when ReceivedDate is null then 1
when ReceivedDate is not null then 2 else null end,3) as 'ScanStatus'
from MyTable
I don't know how you are determining if a label exists or not. That will be up to you.
HTH.
Larry Miller
MCSD
LWMiller3@verizon.netAccumulate learning by study, understand what you learn by questioning. -- Mingjiao