Home » RDBMS Server » Server Administration » Table created under which datafile
Table created under which datafile [message #130449] Sat, 30 July 2005 11:12 Go to next message
dnvs_praveen
Messages: 47
Registered: July 2005
Location: bangalore
Member

Hi

i created a table EMP under a tablespace TS1 . But this tablespace has three datafiles called TS11.dbf,TS12.dbf,TS13.dbf. Now if i want to find in which datafile of TS1 tablespace my EMP table exist? how to find?

If i give this query
select a.table_name||' '||a.tablespace_name||' '||file_name from all_all_tables a,dba_data_files b where (a
.owner='U2' and a.table_name='EMP') and (a.tablespace_name=b.tablespace_name);
its not giving exactly table created under which datafie.

How to find my table created under which datafile?

Regards,
Praveen

[Updated on: Sat, 30 July 2005 11:14]

Report message to a moderator

Re: Table created under which datafile [message #130459 is a reply to message #130449] Sat, 30 July 2005 20:26 Go to previous messageGo to next message
BlackSwan
Messages: 26766
Registered: January 2009
Location: SoCal
Senior Member
>How to find my table created under which datafile?
It does NOT matter at all in which datafile the table was created.
For "large" tables it could/will have extents in all datafiles.

SQL> desc dba_extents
Re: Table created under which datafile [message #130463 is a reply to message #130459] Sun, 31 July 2005 00:45 Go to previous message
Achchan
Messages: 86
Registered: June 2005
Member
You can explicitly specify the TABLESPACE that you want to create your table there.Refer to create table syntax.
Table is a logical unit so you can specify its place in a logical unit called tablespace not a physical one datafile.
Each datafile is associated to one specific tablespace so it will be saved in associated datafile/s.
-Good luck!

Previous Topic: Oracle 9i Installation
Next Topic: Problem with open cursors.
Goto Forum:
  


Current Time: Thu Sep 26 22:46:01 CDT 2024