Skip to Main Content

Breadcrumb

May 4th

Question and Answer

Tom Kyte

Thanks for the question, Sajid.

Asked: August 13, 2002 - 8:22 am UTC

Last updated: November 13, 2002 - 6:03 pm UTC

Version: 9.0.1

Viewed 1000+ times

You Asked

Hi Tom,

I am trying see how XSQL runs and all. For that i tried following but got back the error as it below.


</code> http://localhost/xsql/ <code>

It displays an HTML page with link to :
Hello World page
Employee page
Insurance claim page
Invalid classes page
Do you XML? Site
and many more....

Oracle XSQL Servlet Page Processor 9.0.1.1.0 (Prod)
XSQL-007: Cannot acquire a database connection to process page.
Io exception: Connection refused(DESCRIPTION=(TMP=)(VSNNUM=150999297)(ERR=12505)(ERROR_STACK=(ERROR=(CODE=12505)(EMFI=4))))

Could you please help me.

Thanks in advance.

Regards,

Sajid Anwar
London

and Tom said...

I asked Sean Dillon, our local XML technologist, to take a look at this and here's what he had to say:
---------------------

Sajid,

The XSQL servlet is trying to connect to a database to query data for the demonstrations you are trying to run. There is a file named XSQLConfig.xml which defines the database configuration for your servlet. This file (1) needs to be in your servlet engine's classpath and (2) needs to be provided with database information to connect to your database. Typically, this file is found here:

$XSQL_HOME/xdk/admin/XSQLConfig.xml

For installation/configuration instructions for the XSQL servlet on whichever servlet engine you are running, go to this URL:

</code> http://otn.oracle.com/docs/tech/xml/xdk_java/doc_library/Production9i/index.html

...and look at the "Installation" section.

You also need to create a database user to own the sample schemas & data to run those demonstrations.  To install the necessary database objects and data into this schema, look at the following file:

$XDK_HOME/xdk/demo/java/xsql/install.sql

This basically runs the installation scripts for all the XSQL demos from the page you are seeing.  (oh btw, once you define the user that owns all this data, you will have to make sure the appropriate username & password are in the XSQLConfig.xml file for the "demo" connection.

Hope that helps!

_smd_

_____________________________________________________________________
Sean Dillon - Senior Technologist, Oracle Corporation
Author "Beginning Oracle Programming" 
http://www.amazon.com/exec/obidos/ASIN/186100690X <code>



Rating

  (3 ratings)

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

Comments

Extremely helpful

Sajid Anwar, August 14, 2002 - 3:32 am UTC

Thanks a million Sean and Tom. It was really very helpfull. I would definitely try that and would let you know. Thanks once again.

Best Regards,
Sajid Anwar
London

XSQL exception

Saradha Bavanandam, November 13, 2002 - 2:13 pm UTC

Tom,
Can you please help me in resolving the following XSQL error.

oracle.xml.sql.OracleXMLSQLException: Internal Error: Unable to resolve name

After I drop and re-create an object types, which has dependents, XSQL Servlet raises exception for a query that is working fine in the Oracle Server itself (ie, in SQL*Plus) as in the following test case:

CREATE OR REPLACE TYPE o_object_inner
AS OBJECT ( char1 char(1) )
/
CREATE OR REPLACE TYPE n_nested_table
AS TABLE OF o_object_inner
/
CREATE OR REPLACE TYPE o_object_outer
AS OBJECT ( nNestedTab n_nested_table )
/

For above, the following query encounters no problems on Oracle Server or in XSQL servlet:

SELECT o_object_outer(NULL) AS "theOuterObj" FROM dual

But if I want to make a change to o_object_inner object type then I drop this object type using FORCE and re-create this with the modification.

DROP TYPE o_object_inner FORCE
/
CREATE OR REPLACE TYPE o_object_inner
AS OBJECT (char1 char(1) )
/

SELECT o_object_outer(NULL) AS "theOuterObj" FROM dual

The above query now encounters no problems in SQL*Plus but generates exception in XSQL servlet as follows:

oracle.xml.sql.OracleXMLSQLException: Internal Error: Unable to resolve name

Any insight or help would be greatly appreciated!

But If I drop all of the dependents and recreate them in the
order then It works fine.

Other info:
Oracle Server 8.1.7.4 on HP-UX
XDK 9.2.0.1 (Production) for Java on NT
JDBC/OCI8 drivers for NT (latest for 8.1.7)

Thanks
Pushparaj

Tom Kyte
November 13, 2002 - 2:21 pm UTC

can you try restarting the servlet engine, looks like it is caching some stuff and when you drop and recreate -- the cached data is "not right" anymore.

XSQL exception

Saradha Bavanandam, November 13, 2002 - 3:44 pm UTC

Tom,

Thank you for your quick response.
Actually I get this error only if I stop and restart the engine.

Let me give you the sequence.

1) Start the Servlet engine (tomcat)
2) Run the query from XSQL
SELECT o_object_outer(NULL) as "theOuterObj" FROM dual
3) No error raised.
4) Drop and re-create n_nested_table type.
5) Run the same query from XSQL
SELECT o_object_outer(NULL) as "theOuterObj" FROM dual
6) No error raised and it works fine.
7) Stop and restart the servlet engine.
8) Run the same query from XSQL
SELECT o_object_outer(NULL) as "theOuterObj" FROM dual
9) Now the error is raised as
oracle.xml.sql.OracleXMLSQLException: Internal Error: Unable to resolve name

Thanks again.

Tom Kyte
November 13, 2002 - 6:03 pm UTC

i'll have to refer you to support -- never seen this myself.