Call now: 252-767-6166  
Oracle Training Oracle Support Development Oracle Apps

 E-mail Us
 Oracle Articles
New Oracle Articles

 Oracle Training
 Oracle Tips

 Oracle Forum
 Class Catalog

 Remote DBA
 Oracle Tuning
 Emergency 911
 RAC Support
 Apps Support
 Oracle Support

 SQL Tuning

 Oracle UNIX
 Oracle Linux
 Remote s
 Remote plans
 Application Server

 Oracle Forms
 Oracle Portal
 App Upgrades
 SQL Server
 Oracle Concepts
 Software Support

 Remote S


 Consulting Staff
 Consulting Prices
 Help Wanted!


 Oracle Posters
 Oracle Books

 Oracle Scripts

Don Burleson Blog 







Oracle Text: Map Linux to Windows path

Oracle Database Tips by Donald BurlesonApril 16,  2015

Problem:  I'm facing a tricky problem within my Oracle Text application, running 10g on a Linux server.  Sadly, we have a document repository located on a windows server and I cannot change the OS.  Here we see references to the Windows directories:

select * from my_docs;

doc_id / doc_tittle / doc_path
1 / first.doc / E:\Prodmac\felix\tm\6\214986\060\first.doc
2 / second.doc / E:\Prodmac\felix\tm\2\224345\020\second.doc
3 / third.doc / E:\Prodmac\felix\tm\4\436432\070\third.doc

The windows path has the same prefix E:\Prodmac\felix\tm for all documents but a dynamic 3 depth folder part (created by the application) at the end of the path.
From here we are trying to implement oracle text feature over these external documents.

Since the database is on a Linux machine and the doc_path points to an external windows folder, how do I manage to create a CONTEXT INDEX over the doc_path field without getting the error:

DRG-11513: unable to open or write to file

The problem is to map from Linux the exact windows path that is stored in the table.
Since the path is dynamic generated I cannot even use the the 'path' file_datastore attribute to define common folders.

create index
   my_idx on my_docs(doc_path)
indextype is
   ('datastore ctxsys.file_datastore') ;

Solution:  The solution is to define a user_datastore (instead of file_datastore) on my  CTXSYS.CONTEXT index:

create index
   my_idx on my_docs(doc_path)
indextype is
   ('datastore ctxsys.user_datastore') ;

Inside the user_datastore procedure, I can now transform the path and access the external file on Windows from Linux.



Oracle Training at Sea
oracle dba poster

Follow us on Twitter 
Oracle performance tuning software 
Oracle Linux poster


Burleson is the American Team

Note: This Oracle documentation was created as a support and Oracle training reference for use by our DBA performance tuning consulting professionals.  Feel free to ask questions on our Oracle forum.

Verify experience! Anyone considering using the services of an Oracle support expert should independently investigate their credentials and experience, and not rely on advertisements and self-proclaimed expertise. All legitimate Oracle experts publish their Oracle qualifications.

Errata?  Oracle technology is changing and we strive to update our BC Oracle support information.  If you find an error or have a suggestion for improving our content, we would appreciate your feedback.  Just  e-mail:  

and include the URL for the page.


Burleson Consulting

The Oracle of Database Support

Oracle Performance Tuning

Remote DBA Services


Copyright © 1996 -  2020

All rights reserved by Burleson

Oracle ® is the registered trademark of Oracle Corporation.