Solved

Copy table and data to new table with a LONG RAW field

Posted on 2008-10-30
6
928 Views
Last Modified: 2013-12-19
I want to copy a table containing a LONG RAW field

the following doesn't work

CREATE TABLE DATA_BACKUP
AS
SELECT * FROM DATA

any ideas ?
0
Comment
Question by:Geert Gruwez
  • 4
6 Comments
 
LVL 23

Accepted Solution

by:
paquicuba earned 350 total points
ID: 22843639
SQL*Plus Copy utility:

SQL> CREATE TABLE TEST( LONG_RAW_COL LONG RAW);

Table created.

Elapsed: 00:00:00.10
SQL> copy from <User>/<password>@<database> to <User>/<password>@<database> create new_test using select * from test;

Array fetch/bind size is 15. (arraysize is 15)
Will commit when done. (copycommit is 0)
Maximum long size is 80. (long is 80)
Table NEW_TEST created.

   0 rows selected from <User@<database>.
   0 rows inserted into NEW_TEST.
   0 rows committed into NEW_TEST at <User@<database>..

SQL>
0
 
LVL 37

Author Comment

by:Geert Gruwez
ID: 22847895
ok but how to do it from a script
with something like TOAD
0
 
LVL 27

Assisted Solution

by:sujith80
sujith80 earned 150 total points
ID: 22848743
In TOAD(I am using version 9)

You have to use - Execute As a Script

Choose the option - Execute in sqlplus , by clicking the small drop down next to the script icon.
0
PRTG Network Monitor: Intuitive Network Monitoring

Network Monitoring is essential to ensure that computer systems and network devices are running. Use PRTG to monitor LANs, servers, websites, applications and devices, bandwidth, virtual environments, remote systems, IoT, and many more. PRTG is easy to set up & use.

 
LVL 37

Author Comment

by:Geert Gruwez
ID: 22865010
nothing with oracle dbms packages ?
0
 
LVL 37

Author Comment

by:Geert Gruwez
ID: 22873726
sqlplus does the job

i created my own exe in Delphi as i had some more stuff going on
and in the end i needed a user interface instead of a script

thx for the answers
0
 
LVL 37

Author Closing Comment

by:Geert Gruwez
ID: 31511713
thx guys
0

Featured Post

Free Tool: IP Lookup

Get more info about an IP address or domain name, such as organization, abuse contacts and geolocation.

One of a set of tools we are providing to everyone as a way of saying thank you for being a part of the community.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Truncate is a DDL Command where as Delete is a DML Command. Both will delete data from table, but what is the difference between these below statements truncate table <table_name> ?? delete from <table_name> ?? The first command cannot be …
Using SQL Scripts we can save all the SQL queries as files that we use very frequently on our database later point of time. This is one of the feature present under SQL Workshop in Oracle Application Express.
This video explains at a high level about the four available data types in Oracle and how dates can be manipulated by the user to get data into and out of the database.
This video shows information on the Oracle Data Dictionary, starting with the Oracle documentation, explaining the different types of Data Dictionary views available by group and permissions as well as giving examples on how to retrieve data from th…

839 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question