Skip to Main Content
  • Questions
  • Reading and generating file in outside of db server

Breadcrumb

Question and Answer

Chris Saxon

Thanks for the question, Naveen.

Asked: January 10, 2017 - 6:04 am UTC

Last updated: January 10, 2017 - 5:39 pm UTC

Version: 11g

Viewed 1000+ times

You Asked

Hi Tom,

I want to load images into DB table from host server, which is not DB directory.

Currently i am using bfile concept to load images, which are in db directory.

But, due security purpose client don't want to give access of DB server to user, So we want to put image file in Host server.
Can you pls suggest,how can i achieve..

Thanks

and Chris said...

If you want to load the files using bfile, they must be accessible from the database server.

If you're loading these onto a separate server, you could mount this location on the database server.

If you're not able to do this, you'll need to write a routine to load the images from their host location.

Rating

  (2 ratings)

Is this answer out of date? If it is, please let us know via a Comment

Comments

Naveen CHintha, January 10, 2017 - 12:02 pm UTC

Ok Thanks!!
For the update,this is first time, where i am thinking out side to DB server , i don't know how to mount to host to db location.

any way thanks once again!!
Chris Saxon
January 10, 2017 - 5:39 pm UTC

How to mount depends on your OS.

Use FTP from inside the DB to access the data?

Christian COMMARMOND, January 10, 2017 - 1:24 pm UTC

Hi,

The DB may access the data via ftp. You can find packages on the web to do so.

So you can stay in known territories, DB and PL/SQL.

Then, to load the data is as usual.
You can find a working examples here:
https://oracle-base.com/articles/misc/ftp-from-plsql

Hopes it helps,

Christian
Chris Saxon
January 10, 2017 - 5:18 pm UTC

Good point, thanks for sharing.

More to Explore

CLOB/BLOB/etc

Complete documentation on Securefiles and Large Objects here