Oracle FAQ Your Portal to the Oracle Knowledge Grid
HOME | ASK QUESTION | ADD INFO | SEARCH | E-MAIL US
 

Home -> Community -> Mailing Lists -> Oracle-L -> RE: [RE: COPY vs. INSERTS

RE: [RE: COPY vs. INSERTS

From: Alex Hillman <alex_hillman_at_physia.com>
Date: Wed, 31 May 2000 10:12:35 -0400
Message-Id: <10514.107293@fatcity.com>


This message is in MIME format. Since your mail reader does not understand this format, some or all of this message may not be legible.

------_=_NextPart_001_01BFCB0A.45258250
Content-Type: text/plain;

        charset="iso-8859-1"

No. I did it in the same database. You think there will be some difference?

Alex

-----Original Message-----
From: George.Brennan_at_warnermusic.com
[mailto:George.Brennan_at_warnermusic.com]
Sent: Wednesday, May 31, 2000 5:18 AM
To: Multiple recipients of list ORACLE-L Subject: RE: [RE: COPY vs. INSERTS

Alex,

Have you tried, create table as select across a dblink?

George

> -----Original Message-----
> From: "Alex Hillman" <alex_hillman_at_physia.com>
> [mailto:alex_hillman_at_physia.com]
> Sent: Tuesday, May 30, 2000 6:46 PM
> To: smtp_at_inl001@servers["Multiple recipients of list ORACLE-L"
> <ORACLE-L_at_fatcity.com>]
> Subject: RE: [RE: COPY vs. INSERTS
>
>
> George, you are right with NUMBER versus NUMBER(38). Didn't
> think it thru.
> Returning to the original message - I did some experimenting with copy
> command. If you have original table AA with column NUMBER and
> you do COPY
> .... create AANEW using select * from AA(original table)- yes
> it will create
> DECIMAL(38) but if you precreate empty table where you want
> to copy and use
> command COPY ... INSERT AANEW using select * from AA - it
> will create exact
> copy of original table. We need to use COPY if there is a
> LONG datatype in
> the table, so the conclusion is - for tables which have columns NUMBER
> without precision if we want to use COPY we need to precreate
> empty result
> table.
>
> Alex Hillman
>
> -----Original Message-----
> [mailto:George.Brennan_at_warnermusic.com]
> Sent: Tuesday, May 30, 2000 6:18 AM
> To: Multiple recipients of list ORACLE-L
>
>
> There is a BIG difference.
>
> NUMBER can store a floating point number
> NUMBER(38) will only store interger numbers.
>
> i.e. it will truncate the decimals.
>
> George.
>
> > -----Original Message-----
> > From: "Alex Hillman" <alex_hillman_at_physia.com>
> > [mailto:alex_hillman_at_physia.com]
> > Sent: Friday, May 26, 2000 10:40 PM
> > To: smtp_at_inl001@servers["Multiple recipients of list ORACLE-L"
> > <ORACLE-L_at_fatcity.com>]
> > Subject: RE: [RE: COPY vs. INSERTS
> >
> >
> > What do you think is the difference between Oracle types NUMBER and
> > DECIMAL(38) - answer is NONE.
> >
> > Alex Hillman
> >
> > -----Original Message-----
> > Sent: Friday, May 26, 2000 3:08 PM
> > To: Multiple recipients of list ORACLE-L
> >
> >
> > One important note regarding SQLPLUS COPY utility that can
> > make this less
> > utilitarian is as follows from SQL*Plus 3.1 User Guide and
> Reference:
> > "Note: To enable the copying of data between ORACLE and non-ORACLE
> > databases,
> > NUMBER columns are changed to DECIMAL columns in the
> > destination table.
> > Hence, if you are copying between ORACLE databases, a NUMBER
> > column with no
> > precision will be changed to a DECIMAL(38) column. When
> > copying between
> > ORACLE databases, you should use SQL commands (CREATE TABLE
> > AS and INSERT)
> > or
> > you should ensure that your columns have a precision specified."
> >
> > Milan Rahman
> > Senior Oracle DBA
> > Oracle Applications DBA
> > SageLogix, Inc.
> > Greenwood Village, Colorado
> >
> > http://www.sagelogix.com
> >
> > --
> > Author: Milan Rahman
> > INET: milan_rahman_at_MailAndNews.com
> >
> > Fat City Network Services -- (858) 538-5051 FAX: (858) 538-5051
> > San Diego, California -- Public Internet access /
> Mailing Lists
> > --------------------------------------------------------------------
> > To REMOVE yourself from this mailing list, send an E-Mail message
> > to: ListGuru_at_fatcity.com (note EXACT spelling of 'ListGuru') and in
> > the message BODY, include a line containing: UNSUB ORACLE-L
> > (or the name of mailing list you want to be removed from). You may
> > also send the HELP command for other information (like subscribing).
> >
> >
>
>
> --
> Author:
> INET: George.Brennan_at_warnermusic.com
>
> Fat City Network Services -- (858) 538-5051 FAX: (858) 538-5051
> San Diego, California -- Public Internet access / Mailing Lists
> --------------------------------------------------------------------
> To REMOVE yourself from this mailing list, send an E-Mail message
> to: ListGuru_at_fatcity.com (note EXACT spelling of 'ListGuru') and in
> the message BODY, include a line containing: UNSUB ORACLE-L
> (or the name of mailing list you want to be removed from). You may
> also send the HELP command for other information (like subscribing).
>
>

-- 
Author: 
  INET: George.Brennan_at_warnermusic.com

Fat City Network Services    -- (858) 538-5051  FAX: (858) 538-5051
San Diego, California        -- Public Internet access / Mailing Lists
--------------------------------------------------------------------
To REMOVE yourself from this mailing list, send an E-Mail message
to: ListGuru_at_fatcity.com (note EXACT spelling of 'ListGuru') and in
the message BODY, include a line containing: UNSUB ORACLE-L
(or the name of mailing list you want to be removed from).  You may
also send the HELP command for other information (like subscribing).

------_=_NextPart_001_01BFCB0A.45258250
Content-Type: text/html;
	charset="iso-8859-1"

<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 3.2//EN">
<HTML>
<HEAD>
<META HTTP-EQUIV="Content-Type" CONTENT="text/html; charset=iso-8859-1">
<META NAME="Generator" CONTENT="MS Exchange Server version 5.5.2448.0">
<TITLE>RE: [RE: COPY vs. INSERTS</TITLE>
</HEAD>
<BODY>

<P><FONT SIZE=2>No. I did it in the same database. You think there will be some difference?</FONT>
</P>

<P><FONT SIZE=2>Alex</FONT>
</P>

<P><FONT SIZE=2>-----Original Message-----</FONT>
<BR><FONT SIZE=2>From: George.Brennan_at_warnermusic.com</FONT>
<BR><FONT SIZE=2>[<A HREF="mailto:George.Brennan_at_warnermusic.com">mailto:George.Brennan_at_warnermusic.com</A>]</FONT>
<BR><FONT SIZE=2>Sent: Wednesday, May 31, 2000 5:18 AM</FONT>
<BR><FONT SIZE=2>To: Multiple recipients of list ORACLE-L</FONT>
<BR><FONT SIZE=2>Subject: RE: [RE: COPY vs. INSERTS</FONT>
</P>
<BR>

<P><FONT SIZE=2>Alex,</FONT>
</P>

<P><FONT SIZE=2>Have you tried, create table as select across a dblink?</FONT>
</P>

<P><FONT SIZE=2>George</FONT>
</P>

<P><FONT SIZE=2>&gt; -----Original Message-----</FONT>
<BR><FONT SIZE=2>&gt; From: &quot;Alex Hillman&quot; &lt;alex_hillman_at_physia.com&gt;</FONT>
<BR><FONT SIZE=2>&gt; [<A HREF="mailto:alex_hillman_at_physia.com">mailto:alex_hillman_at_physia.com</A>]</FONT>
<BR><FONT SIZE=2>&gt; Sent: Tuesday, May 30, 2000 6:46 PM</FONT>
<BR><FONT SIZE=2>&gt; To: smtp_at_inl001@servers[&quot;Multiple recipients of list ORACLE-L&quot;</FONT>
<BR><FONT SIZE=2>&gt; &lt;ORACLE-L_at_fatcity.com&gt;]</FONT>
<BR><FONT SIZE=2>&gt; Subject: RE: [RE: COPY vs. INSERTS</FONT>
<BR><FONT SIZE=2>&gt; </FONT>
<BR><FONT SIZE=2>&gt; </FONT>
<BR><FONT SIZE=2>&gt; George, you are right with NUMBER versus NUMBER(38). Didn't </FONT>
<BR><FONT SIZE=2>&gt; think it thru.</FONT>
<BR><FONT SIZE=2>&gt; Returning to the original message - I did some experimenting with copy</FONT>
<BR><FONT SIZE=2>&gt; command. If you have original table AA with column NUMBER and </FONT>
<BR><FONT SIZE=2>&gt; you do COPY</FONT>
<BR><FONT SIZE=2>&gt; .... create AANEW using select * from AA(original table)- yes </FONT>
<BR><FONT SIZE=2>&gt; it will create</FONT>
<BR><FONT SIZE=2>&gt; DECIMAL(38) but if you precreate empty table where you want </FONT>
<BR><FONT SIZE=2>&gt; to copy and use</FONT>
<BR><FONT SIZE=2>&gt; command COPY ... INSERT AANEW using select * from AA - it </FONT>
<BR><FONT SIZE=2>&gt; will create exact</FONT>
<BR><FONT SIZE=2>&gt; copy of original table. We need to use COPY if there is a </FONT>
<BR><FONT SIZE=2>&gt; LONG datatype in</FONT>
<BR><FONT SIZE=2>&gt; the table, so the conclusion is - for tables which have columns NUMBER</FONT>
<BR><FONT SIZE=2>&gt; without precision if we want to use COPY we need to precreate </FONT>
<BR><FONT SIZE=2>&gt; empty result</FONT>
<BR><FONT SIZE=2>&gt; table.</FONT>
<BR><FONT SIZE=2>&gt; </FONT>
<BR><FONT SIZE=2>&gt; Alex Hillman</FONT>
<BR><FONT SIZE=2>&gt; </FONT>
<BR><FONT SIZE=2>&gt; -----Original Message-----</FONT>
<BR><FONT SIZE=2>&gt; [<A HREF="mailto:George.Brennan_at_warnermusic.com">mailto:George.Brennan_at_warnermusic.com</A>]</FONT>
<BR><FONT SIZE=2>&gt; Sent: Tuesday, May 30, 2000 6:18 AM</FONT>
<BR><FONT SIZE=2>&gt; To: Multiple recipients of list ORACLE-L</FONT>
<BR><FONT SIZE=2>&gt; </FONT>
<BR><FONT SIZE=2>&gt; </FONT>
<BR><FONT SIZE=2>&gt; There is a BIG difference.</FONT>
<BR><FONT SIZE=2>&gt; </FONT>
<BR><FONT SIZE=2>&gt; NUMBER can store a floating point number </FONT>
<BR><FONT SIZE=2>&gt; NUMBER(38) will only store interger numbers.</FONT>
<BR><FONT SIZE=2>&gt; </FONT>
<BR><FONT SIZE=2>&gt; i.e. it will truncate the decimals.</FONT>
<BR><FONT SIZE=2>&gt; </FONT>
<BR><FONT SIZE=2>&gt; George.</FONT>
<BR><FONT SIZE=2>&gt; </FONT>
<BR><FONT SIZE=2>&gt; &gt; -----Original Message-----</FONT>
<BR><FONT SIZE=2>&gt; &gt; From: &quot;Alex Hillman&quot; &lt;alex_hillman_at_physia.com&gt;</FONT>
<BR><FONT SIZE=2>&gt; &gt; [<A HREF="mailto:alex_hillman_at_physia.com">mailto:alex_hillman_at_physia.com</A>]</FONT>
<BR><FONT SIZE=2>&gt; &gt; Sent: Friday, May 26, 2000 10:40 PM</FONT>
<BR><FONT SIZE=2>&gt; &gt; To: smtp_at_inl001@servers[&quot;Multiple recipients of list ORACLE-L&quot;</FONT>
<BR><FONT SIZE=2>&gt; &gt; &lt;ORACLE-L_at_fatcity.com&gt;]</FONT>
<BR><FONT SIZE=2>&gt; &gt; Subject: RE: [RE: COPY vs. INSERTS</FONT>
<BR><FONT SIZE=2>&gt; &gt; </FONT>
<BR><FONT SIZE=2>&gt; &gt; </FONT>
<BR><FONT SIZE=2>&gt; &gt; What do you think is the difference between Oracle types NUMBER and</FONT>
<BR><FONT SIZE=2>&gt; &gt; DECIMAL(38) - answer is NONE.</FONT>
<BR><FONT SIZE=2>&gt; &gt; </FONT>
<BR><FONT SIZE=2>&gt; &gt; Alex Hillman</FONT>
<BR><FONT SIZE=2>&gt; &gt; </FONT>
<BR><FONT SIZE=2>&gt; &gt; -----Original Message-----</FONT>
<BR><FONT SIZE=2>&gt; &gt; Sent: Friday, May 26, 2000 3:08 PM</FONT>
<BR><FONT SIZE=2>&gt; &gt; To: Multiple recipients of list ORACLE-L</FONT>
<BR><FONT SIZE=2>&gt; &gt; </FONT>
<BR><FONT SIZE=2>&gt; &gt; </FONT>
<BR><FONT SIZE=2>&gt; &gt; One important note regarding SQLPLUS COPY utility that can </FONT>
<BR><FONT SIZE=2>&gt; &gt; make this less </FONT>
<BR><FONT SIZE=2>&gt; &gt; utilitarian is as follows from SQL*Plus 3.1 User Guide and </FONT>
<BR><FONT SIZE=2>&gt; Reference:</FONT>
<BR><FONT SIZE=2>&gt; &gt; &quot;Note: To enable the copying of data between ORACLE and non-ORACLE</FONT>
<BR><FONT SIZE=2>&gt; &gt; databases, </FONT>
<BR><FONT SIZE=2>&gt; &gt; NUMBER columns are changed to DECIMAL columns in the </FONT>
<BR><FONT SIZE=2>&gt; &gt; destination table.&nbsp; </FONT>
<BR><FONT SIZE=2>&gt; &gt; Hence, if you are copying between ORACLE databases, a NUMBER </FONT>
<BR><FONT SIZE=2>&gt; &gt; column with no </FONT>
<BR><FONT SIZE=2>&gt; &gt; precision will be changed to a DECIMAL(38) column.&nbsp; When </FONT>
<BR><FONT SIZE=2>&gt; &gt; copying between </FONT>
<BR><FONT SIZE=2>&gt; &gt; ORACLE databases, you should use SQL commands (CREATE TABLE </FONT>
<BR><FONT SIZE=2>&gt; &gt; AS and INSERT)</FONT>
<BR><FONT SIZE=2>&gt; &gt; or </FONT>
<BR><FONT SIZE=2>&gt; &gt; you should ensure that your columns have a precision specified.&quot;</FONT>
<BR><FONT SIZE=2>&gt; &gt; </FONT>
<BR><FONT SIZE=2>&gt; &gt; Milan Rahman</FONT>
<BR><FONT SIZE=2>&gt; &gt; Senior Oracle DBA</FONT>
<BR><FONT SIZE=2>&gt; &gt; Oracle Applications DBA</FONT>
<BR><FONT SIZE=2>&gt; &gt; SageLogix, Inc.</FONT>
<BR><FONT SIZE=2>&gt; &gt; Greenwood Village, Colorado</FONT>
<BR><FONT SIZE=2>&gt; &gt; </FONT>
<BR><FONT SIZE=2>&gt; &gt; http://www.sagelogix.com</FONT>
<BR><FONT SIZE=2>&gt; &gt; </FONT>
<BR><FONT SIZE=2>&gt; &gt; -- </FONT>
<BR><FONT SIZE=2>&gt; &gt; Author: Milan Rahman</FONT>
<BR><FONT SIZE=2>&gt; &gt;&nbsp;&nbsp; INET: milan_rahman_at_MailAndNews.com</FONT>
<BR><FONT SIZE=2>&gt; &gt; </FONT>
<BR><FONT SIZE=2>&gt; &gt; Fat City Network Services&nbsp;&nbsp;&nbsp; -- (858) 538-5051&nbsp; FAX: (858) 538-5051</FONT>
<BR><FONT SIZE=2>&gt; &gt; San Diego, California&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; -- Public Internet access / </FONT>
<BR><FONT SIZE=2>&gt; Mailing Lists</FONT>
<BR><FONT SIZE=2>&gt; &gt; --------------------------------------------------------------------</FONT>
<BR><FONT SIZE=2>&gt; &gt; To REMOVE yourself from this mailing list, send an E-Mail message</FONT>
<BR><FONT SIZE=2>&gt; &gt; to: ListGuru_at_fatcity.com (note EXACT spelling of 'ListGuru') and in</FONT>
<BR><FONT SIZE=2>&gt; &gt; the message BODY, include a line containing: UNSUB ORACLE-L</FONT>
<BR><FONT SIZE=2>&gt; &gt; (or the name of mailing list you want to be removed from).&nbsp; You may</FONT>
<BR><FONT SIZE=2>&gt; &gt; also send the HELP command for other information (like subscribing).</FONT>
<BR><FONT SIZE=2>&gt; &gt; </FONT>
<BR><FONT SIZE=2>&gt; &gt; </FONT>
<BR><FONT SIZE=2>&gt; </FONT>
<BR><FONT SIZE=2>&gt; </FONT>
<BR><FONT SIZE=2>&gt; -- </FONT>
<BR><FONT SIZE=2>&gt; Author: </FONT>
<BR><FONT SIZE=2>&gt;&nbsp;&nbsp; INET: George.Brennan_at_warnermusic.com</FONT>
<BR><FONT SIZE=2>&gt; </FONT>
<BR><FONT SIZE=2>&gt; Fat City Network Services&nbsp;&nbsp;&nbsp; -- (858) 538-5051&nbsp; FAX: (858) 538-5051</FONT>
<BR><FONT SIZE=2>&gt; San Diego, California&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; -- Public Internet access / Mailing Lists</FONT>
<BR><FONT SIZE=2>&gt; --------------------------------------------------------------------</FONT>
<BR><FONT SIZE=2>&gt; To REMOVE yourself from this mailing list, send an E-Mail message</FONT>
<BR><FONT SIZE=2>&gt; to: ListGuru_at_fatcity.com (note EXACT spelling of 'ListGuru') and in</FONT>
<BR><FONT SIZE=2>&gt; the message BODY, include a line containing: UNSUB ORACLE-L</FONT>
<BR><FONT SIZE=2>&gt; (or the name of mailing list you want to be removed from).&nbsp; You may</FONT>
<BR><FONT SIZE=2>&gt; also send the HELP command for other information (like subscribing).</FONT>
<BR><FONT SIZE=2>&gt; </FONT>
<BR><FONT SIZE=2>&gt; </FONT>
</P>
<BR>

<P><FONT SIZE=2>-- </FONT>
<BR><FONT SIZE=2>Author: </FONT>
<BR><FONT SIZE=2>&nbsp; INET: George.Brennan_at_warnermusic.com</FONT>
</P>

<P><FONT SIZE=2>Fat City Network Services&nbsp;&nbsp;&nbsp; -- (858) 538-5051&nbsp; FAX: (858) 538-5051</FONT>
<BR><FONT SIZE=2>San Diego, California&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; -- Public Internet access / Mailing Lists</FONT>
<BR><FONT SIZE=2>--------------------------------------------------------------------</FONT>
<BR><FONT SIZE=2>To REMOVE yourself from this mailing list, send an E-Mail message</FONT>
<BR><FONT SIZE=2>to: ListGuru_at_fatcity.com (note EXACT spelling of 'ListGuru') and in</FONT>
<BR><FONT SIZE=2>the message BODY, include a line containing: UNSUB ORACLE-L</FONT>
Received on Wed May 31 2000 - 09:12:35 CDT

Original text of this message

HOME | ASK QUESTION | ADD INFO | SEARCH | E-MAIL US