swirl
Guide to OmniMark 9   OmniMark home
docs home 
IndexConceptsTasksSyntaxLibrariesLegacy LibrariesErrors
 
  Related Topics   Other Library Functions  
function  

db.open-sedna

 
 

Library: Database access (OMDB)
Import: omdb.xmd
Return type: dbDatabase

Returns: A db.database OMX component


Declaration

define external db.database function db.open-sedna
            value string url
     dbname value string database-name

  or

  define external db.database function db.open-sedna
            value string url
     dbname value string database-name
       user value string user-name
   password value string password


Argument definitions

url
is the name of the machine and the port number that Sedna database is running on. If the port is omitted, then port number 5050 is used by default.
database-name
is the name of the Oracle database to which you want to connect.
user-name
is the user name that will be supplied to the database when the connection is made.
password
is the password that will be supplied to the database when the connection is made.


Purpose

Use db.open-sedna to create a connection to a Sedna XML native database. See http://www.modis.ispras.ru/Development/sedna.htm for more details on how to get Sedna. The function returns a db.database OMX component.

Requirements

user-name and password are optional with default values of an empty string. Check what access requirements are needed for the specified database.

Usage Notes

You must have declared an OMX db.database variable (either global or local) to use a database connection in other OMDB functions.

This function will throw external exception OMDB501 if there are any Sedna errors. The exception will include any error numbers and descriptive text generated by Sedna. Consult the Sedna documentation for further details on the error condition.

Example

Create a connection to a Sedna database named "XMLDatabaseDemo" using username "charley" and password "chaplin" on machine named "rhine". This connection can be reused in other OMDB functions.

    import "omdb.xmd" prefixed by db.
  
    process
       local db.database my-database
                    .  .  .
       set my-database to db.open-sedna "rhine" dbname "XMLDatabaseDemo" user
  "charley" password "chaplin"

    Related Topics
 
Other Library Functions
 
 

Top [ INDEX ] [ CONCEPTS ] [ TASKS ] [ SYNTAX ] [ LIBRARIES ] [ LEGACY LIBRARIES ] [ ERRORS ]

OmniMark 9.1.0 Documentation Generated: September 2, 2010 at 1:38:10 pm
If you have any comments about this section of the documentation, please use this form.

Copyright © Stilo International plc, 1988-2010.