Home » SQL & PL/SQL » SQL & PL/SQL » Read from an Excel file
Read from an Excel file [message #7088] Tue, 20 May 2003 12:35 Go to next message
Nathan Darby
Messages: 1
Registered: May 2003
Junior Member
Hi All,

I need some help here. I know SQL pretty good, but I have never tried reading from Excel using SQL.

Here's my situation:
I have an Excel file with 2000+ Phone Numbers.
I need to write a script that will iterate through these Phone Numbers and update my DataBase accordingly. I simply don't know how to access the excel cells using SQL. Anyone have a clue? Because I don't know how to do this.

Thanks in advance for any help.

Nathan
Re: Read from an Excel file [message #7090 is a reply to message #7088] Tue, 20 May 2003 12:50 Go to previous messageGo to next message
Mike T
Messages: 32
Registered: August 2002
Member
Nor do I, but I'm sure it's possible (VBA maybe?). What I do is add and extra step to the process and Import the Excel file into Access. From there you can update your Database using SQL.
Re: Read from an Excel file [message #7097 is a reply to message #7088] Tue, 20 May 2003 23:31 Go to previous messageGo to next message
robin baby
Messages: 13
Registered: May 2003
Junior Member
in this situation you can use oracle loadder
Re: Read from an Excel file [message #7099 is a reply to message #7090] Wed, 21 May 2003 01:59 Go to previous messageGo to next message
Martin Chadderton
Messages: 35
Registered: May 2003
Member
There's no direct mechanism for accessing an excel spreadsheet (unless somebody can come up with a Java stored procedure for it? ;-)), but there are quite a few indirect mechanisms....

Probably the easiest way is (as mentioned earlier) load the data into access and use the append queries (or whatever they're called nowadays).

But, you could also

1. Export the file as a delimited text file and either use sqlldr or external tables (at 9i, very cool), or even UTL_FILE (as a last resort ;-)) to get the data in.

2. Export the excel file in SYLK format and use OWA_SYLK built-in to get the data

There are loads of options, but none (unless some java expert can come up with a way of accessing excel from a jsp) which are DIRECT access, every mechanism involves some intermediate step.

Regards
Re: Read from an Excel file [message #7107 is a reply to message #7088] Wed, 21 May 2003 07:19 Go to previous message
Kishor Bhalwankar
Messages: 33
Registered: February 2003
Member
Hi
apart from sql loader there is another utility in oracle 9i is EXTERNAL TABLE.. this will help u

Kishor
Previous Topic: Find the max value of a filed
Next Topic: SQL Query
Goto Forum:
  


Current Time: Fri Apr 26 01:31:31 CDT 2024