Skip to main content
Participant
August 19, 2008
Question

Binary, Displays Yes or No

  • August 19, 2008
  • 3 replies
  • 261 views
I have a binary entry in my database I am using it as 0 for No and 1 for yes. How do I get it to display Yes and No on the website instead of 0 & 1.

Thank You Again
Rab
This topic has been closed for replies.

3 replies

Inspiring
August 20, 2008
Michael Fesser wrote:
> .oO(Rabastan99)
>
>> I have a binary entry in my database I am using it as 0 for No and 1 for
>> yes. How do I get it to display Yes and No on the website instead of 0
>> & 1.
>
> Some code please. What scripting language? Or do it in SQL, but even
> then it would help to see the query.
>
> Micha

I like doing it in SQL

SELECT CASE binaryEntry WHEN 0 THEN 'No' WHEN 1 THEN 'Yes' END AS
NewBinaryEntryName

Dooza
Inspiring
August 20, 2008
.oO(Rabastan99)

>I have a binary entry in my database I am using it as 0 for No and 1 for
>yes. How do I get it to display Yes and No on the website instead of 0
>& 1.

Some code please. What scripting language? Or do it in SQL, but even
then it would help to see the query.

Micha
Inspiring
August 19, 2008
> I have a binary entry in my database I am using it as 0 for No and 1 for
> yes. How do I get it to display Yes and No on the website instead of 0 &
> 1.

pseudo code:

if yourField = 0 then
display 'no'
else
display 'yes'
end if

-Darrel