MySQL Forums
Forum List  »  Oracle

pls, anyone help me with this problem....
Posted by: mad bu
Date: September 01, 2006 07:11PM

Hi all,

I have a table called temp which has a data full of text which is delimited by ';' and whitespace. Data fields are splitted by ';' and last field is split by whitespace, Data is differentiated by the first field.and should be stored into multiple tables using pl/sql.

1) CREATE TABLE temp ( temp_data varchar2(4000) );

table created.

2) SELECT temp_data FROM temp;TEMP_DATA
------------------------------------------------------
SERVER;psysadm-epm05b;EMM Herndon Servers;
epmfnmaro;epmfnmarw;1691;UNIX;

ROUTER;1hca-r01-l0;3900;cisco7507_12.0(18)_ROUTER_CORP;vistaTest;private;NETWORK

....
etc...
OUTPUT
======
SERVERS TABLE
============
SERVER TYPE VARCHAR2(64) NOT NULL, ----SERVER
SERVER NAME VARCHAR2(64) PRIMARY KEY,----psysadm-epm05b
GROUP VARCHAR2(64) ,------EMM Herndon Servers
SNMPRO PWD VARCHAR2(64),-----epmfnmaro
SNMPRW PWD VARCHAR2(64), -----epmfnmarw
SNMP PORTNO NUMBER(6), -----1691
PLATFORM VARCHAR2(16), -----UNIX
CUSTOMER VARCHAR2(64) ----WHITESPACE

ROUTER TABLE
--------------
ROUTER TYPE
ROUTER NAME
GROUP
DESCRIPTION
SNMPRO PWD
SNMPRW PWD
PLATFORM



My Intention is to store the above data concurrently into table called servers table,routers table...etc... I tried in sqlldr , but I couldnt store primary key , foreign key data..

Only servers data has a blank field at the end of each line with a delimiter ' ' .
so, can anyone help me to solve this Problem.

Options: ReplyQuote


Subject
Views
Written By
Posted
pls, anyone help me with this problem....
3014
September 01, 2006 07:11PM


Sorry, you can't reply to this topic. It has been closed.

Content reproduced on this site is the property of the respective copyright holders. It is not reviewed in advance by Oracle and does not necessarily represent the opinion of Oracle or any other party.