Home » SQL & PL/SQL » SQL & PL/SQL » Limit at the names of Tables?
icon6.gif  Limit at the names of Tables? [message #208595] Mon, 11 December 2006 08:32 Go to next message
Buzzer
Messages: 28
Registered: May 2006
Junior Member
Hello NG!

Does a limit exist at the length of the tablenames? Question is for Oracle 9i and 10g. Would it be possible to name a table:
this_is_my_really_long_table_name

Best Regards
Re: Limit at the names of Tables? [message #208597 is a reply to message #208595] Mon, 11 December 2006 08:38 Go to previous messageGo to next message
Cthulhu
Messages: 381
Registered: September 2006
Location: UK
Senior Member
Issue the following command in SQL*Plus:

describe user_tables

Look at the datatype of the table_name column and it will give you your answer.
Re: Limit at the names of Tables? [message #208599 is a reply to message #208595] Mon, 11 December 2006 08:48 Go to previous messageGo to next message
Mohammad Taj
Messages: 2412
Registered: September 2006
Location: Dubai, UAE
Senior Member

hi,

you can create table 30 character. long.
like

SQL> create table a_12345678901234567890123456$# ( no number);

Table created.

SQL> create table a_123456789012345678901234567$# ( no number);
create table a_123456789012345678901234567$# ( no number)
             *
ERROR at line 1:
ORA-00972: identifier is too long



regards
Taj
Re: Limit at the names of Tables? [message #208600 is a reply to message #208595] Mon, 11 December 2006 08:53 Go to previous messageGo to next message
Buzzer
Messages: 28
Registered: May 2006
Junior Member
Hello,

I don't mean the length of text I can put into a field of a column. I mean the maximum length that a name of a column can have. I've heard from a limit of 16 chars.
Any ideas?

Best Regards
Re: Limit at the names of Tables? [message #208601 is a reply to message #208599] Mon, 11 December 2006 08:54 Go to previous messageGo to next message
Buzzer
Messages: 28
Registered: May 2006
Junior Member
Hello,

thank you, that's what I was searching. Is the maximum length of columnnames the same in Oracle 9i and 10g?

Best Regards
Re: Limit at the names of Tables? [message #208602 is a reply to message #208595] Mon, 11 December 2006 08:56 Go to previous messageGo to next message
Cthulhu
Messages: 381
Registered: September 2006
Location: UK
Senior Member
Neither I nor user52 referred to the text that can go into a column. We both specified maximum size of the table name, which is what you aksed for. This command should tell you the maximum column size:

describe user_tab_columns
Re: Limit at the names of Tables? [message #208603 is a reply to message #208600] Mon, 11 December 2006 09:00 Go to previous message
Mohammad Taj
Messages: 2412
Registered: September 2006
Location: Dubai, UAE
Senior Member

hi,
Some role apply in Column Name

SQL> create table a ( a_12345678901234567890123456$# number);

Table created.

SQL> create table a ( a_123456789012345678901234567$# number);
create table a ( a_123456789012345678901234567$# number)
                 *
ERROR at line 1:
ORA-00972: identifier is too long



regards
Taj
Previous Topic: How to sum up values into a 419(!!) columns wide Table
Next Topic: BULK COLLECT
Goto Forum:
  


Current Time: Mon Dec 05 06:47:03 CST 2016

Total time taken to generate the page: 0.08890 seconds