This is a pretty basic question, but I'm learning SQL from a book and it's very 
very frustrating!   

I'm writing a report listing animals from our shelter and whether they have 
been adopted.  I am selecting the animal name field and a field called 
'adopted' from a table called 'animal'.  The values in 'adopted' are either:  1 
(meaning yes, this animal was adopted) or 0 (no, this animal has not been 
adopted). 
 
So far I:
"SELECT Name, Adopted FROM animal".  This prints a column of animal names and a 
column labeled "Adopted" with row after row of 0's and 1's.  I want my output 
report to say 'Y' if 'adopted' = 1 or 'N' if adopted = 0.  

I've spent all day studying "Insert Into", "Update Where", "If... Then", 
looking at SQL manuals (so far I've studied 3 of them), and trying to find an 
example in existing code.  I get syntax errors for everything I try.  This is a 
very simple thing that's done all the time -- but I can't figure out how in 
SQL.  

Can someone help me?
Thanks,
Sue

Reply via email to