0

I have a requirement where I need to change the column data type to BIT. As of now its in NUMBER. I know that Oracle does not support BIT data types, just curious to know if there is any alternatives to achieve this.

Thanks ! Kishanu.

3
  • And why do you need a "bit" data type? If you are looking for a "boolean" type - Oracle does not have that either. So you need to stay with number Commented Sep 14, 2016 at 6:47
  • Actually we have an application called Guidewire which is using Oracle 12c as a backend. We are performing an upgrade task from Oracle 11g to 12c. So, the client requested to modify one of the columns to BIT which was previously NUMBER. We thought of changing it to CHAR(1) to make it equivalent to BIT. But i guess it won't work Commented Sep 14, 2016 at 6:54
  • 1
    Surely the answer when someone asks you to do something impossible (you can't convert a column to bit since Oracle does not have a bit type) is to ask the client some followup questions. A char(1) or a raw(1) might be kind of sort of like a bit in SQL Server but neither is really equivalent. I'd ask the client what problem they are trying to solve and why they think a non-existent data type would solve that problem. Commented Sep 14, 2016 at 7:34

1 Answer 1

1

Thanks for your suggestions and advises. As I mentioned I tried with CHAR(1) and the application accepted the change for the particular column. I don't know how it worked but now the server is getting started.

Sign up to request clarification or add additional context in comments.

Comments

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.