Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 6910573
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 27, 20262026-05-27T08:49:56+00:00 2026-05-27T08:49:56+00:00

I used a case to change boolean column values to a text string that

  • 0

I used a case to change boolean column values to a text string that actually means something. Firstly, when doing a WHERE statement on these columns do I use the boolean values or the updated text strings?

I used:

WHERE TrainingProgram.blnInCatalogue = 'Yes' 
  AND TrainingProgram.blnActive = 'Inactive'

But I get the error:

Conversion failed when converting the varchar value ‘Yes’ to data type bit.

Am I doing something wrong?

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-05-27T08:49:56+00:00Added an answer on May 27, 2026 at 8:49 am

    For true, try using:

    WHERE TrainingProgram.blnInCatalogue <> 0 
    

    For false, try using:

    WHERE TrainingProgram.blnInCatalogue = 0 
    

    The blnInCatalogue column is a bit field, and it doesn’t understand what the string ‘Yes’ means. It only knows 0 or 1.

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

The term test case used a lot, but what does it actually mean? Test
I think that it used to the be the case that in Liferay 4,
1-)For sorted array I have used Binary Search. We know that the worst case
I know the switch case statement is inherent to javascript and you can't change
I mostly use the switch case for string values. Can someone confirm if they
I want get the time used for a case so I can create an
Is SQL case sensitive? I've used MySQL and SQL Server which both seem to
The case: There is a .net application calling unmanaged C code. Used method for
I'm used to thinking of member functions as just being a special case of
I have not used many lambda expressions before and I ran into a case

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.