Link to home
Start Free TrialLog in
Avatar of Dipti01
Dipti01

asked on

How to extract data from Oracle 10g database to excel

Hi all,
I have a deployed application which was developed externally. This application does some master data management & stores data in Oracle 10g database. So now we need to extract the data from Oracle 10g & store it excel or any other format. This extracted data need to be uploaded to SAP after validation.
Regards,
Dipti
Avatar of MarkusId
MarkusId
Flag of Austria image

Hi,

You must have access with sql to the database. Then you
can spool the data delimited by semicolons to build a csv-file
which can easily be accessed by excel.


set colsep ';' -- you can set this to other delimiters as well
set lines 700 -- set this to your maimum linesize
set pages 50000 -- get a header only at the beginning
set trimspool on -- don't pad all lines to 700 characters
set feed off 
set echo off
set verify off
 
spool filename.csv
SELECT...
spool off

Open in new window

Avatar of Dipti01
Dipti01

ASKER

I don't know anything about Oracle. In the start menu->Programs-> Oracle database 10g express edition ->Run SQL Command line. When i click here. SQL> prompt comes. I hope i have to use this to execute above mentioned commands.
I junst have .db extension file for Oracle database. How would i select the database i need to extract in the SQL commnand prompt. I don't know the table name also.  

Could you please tell in detail on how to extract data from Oracle database.

Thanks
ASKER CERTIFIED SOLUTION
Avatar of MarkusId
MarkusId
Flag of Austria image

Link to home
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Start Free Trial
Avatar of Dipti01

ASKER

To extract data from Oracle database (.db file), i must know the database name, its table to extract the data. Is this understanding correct?
Yes, that's right. You must know a username & password, the
connection information (if it's not already in the tnsnames.ora in your oracle/network/amin-directory) and the table(s) where the data is stored that you want to extract.
SOLUTION
Link to home
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Start Free Trial
Avatar of Dipti01

ASKER

Thanks Markus & gatorvip for your inputs, I could retrieve the data from Oracle database.  
Regards,
Dipti
Once you get the Oracle connection and tables you want thing figured out.

If SAP can handle XML, I would look at going down the XML path over Excel.  Generating XML from oracle is becoming easier with every new release.
This question has been classified as abandoned and is closed as part of the Cleanup Program. See the recommendation for more details.