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

  • Home
  • SEARCH
  • 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 6218251
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 24, 20262026-05-24T07:34:26+00:00 2026-05-24T07:34:26+00:00

I have a table in oracle that looks like this: name | type |

  • 0

I have a table in oracle that looks like this:

name              |     type    | nullable  
------------------------------------------
person_name       | varchar(20) | yes  
weight_coeficient | number      | yes
...

How can I figure out how many digits a value of weight_coeficient has ? For example:

3.0123456789 has 11 digits (precision = 11) and 10 digits after the decimal (scale = 10)

Is there any sql command/function that does that, something like GetPrecision( select.. ) that returns 11 ?

Note also that the definition of the table does not specify scale and precision. So as far as I know the maximum precision is applied for all the numbers. So I’m not interested in finding out the precision (= 48) of the definition, but the precision of a specific value in the table. Is that possible just using oracle commands ?

Thank you in advance,
JP

  • 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-24T07:34:27+00:00Added an answer on May 24, 2026 at 7:34 am

    How about….

    SELECT LENGTH(TRANSLATE(TO_CHAR(3.0123456789),'1234567890.-','1234567890')) 
    FROM dual
    

    The translate simply removes the non numeric characters .-

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

Sidebar

Related Questions

I have a table like this (Oracle, 10) Account Bookdate Amount 1 20080101 100
for SQL Server 2008 R2 I have a resultset that looks like this (note
I have an entity that maps to an external oracle table which is one
Say I have an Oracle PL/SQL block that inserts a record into a table
I have this table in an Oracle DB which has a primary key defined
I'm designing an application that will use Oracle , and we have this department
I have two tables like this create table A_DUMMY ( TRADE_ID VARCHAR2(16) TRADE_DATA VARCHAR2(500)
I have a table (in an Oracle database) just like below: department ---------- Finance
I have a lab values table that I would like to query and get
I am working on Oracle. I have this large property-indexer table ( THE_TABLE ),

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.