Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations SkipVought on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Question About "Reconverting" Data Types

Status
Not open for further replies.

mrDrive

MIS
Aug 29, 2002
94
0
0
US
Hi,

I'm linking to a SQL Server view to generate a report in Access. In my view, I'm selecting a bit field that has some null values. When I select the bit field, I convert it to CHAR() so that any null values show as empty strings in Access:

Code:
select ISNULL(CONVERT(char(20),bit_field1),'') AS converted_bit_field
from MyTable

In my report, I want this value to display as a Yes/No value not a 1 or 0.

My question is whether or not there's a way convert converted_bit_field back to the Yes/No data type?

Thanks for any help!
 
mrDrive,

Please have a look at the iif function.

This should do the trick..

[thumbsup2]

 
Cool thanx! Never used that function before.
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top