Connetion or SQL sentence error: DA0005
Hi All,
My customer is using xi-r2 sp2.
when opening a deki report getting the error Connetion or SQL sentence error: DA0005
Please help how to narrow down this issue,.
Thanks,
Shiva
Hello Gokul,
If using Citrix:
Database Connectivity will have impact on the reports.
Need to activate the database connection on the Citrix server.
If using Stored Procedures:
Workaround 1:
Just put SET NOCOUNT ON parameter before the select statement and put SET NOCOUNT OFF parameter in the end of the stored procedure. After that run the stored procedure in the Desktop Intelligence report.
Workaround 2:
-You have to add the given parameter in ".sbo "file -> save the file and run the stored Procedure.
This file should be located under <drive>\Business Objects\BusinessObjects Enterprise 6\dataAccess\RDBMS\connectionServer\odbc\odbc.sbo
<Defaults>
<Parameter Name="Force SQLExecute">Always</Parameter>
Another possibility:
When doing the custom installation, make sure that the Samples section is selected for installation.
This downloads the appropriate database and configures the driver under Control Panel > Administrative Tools > ODBC Data Source Administrator > System DSN.
Alternatively, the sample database can be manually copied to the client and the driver manually configured.
The Universe might not be on the server.
Another possiblity:
Perform the following steps:
Check the Oracle client installation version (for example, 9i).
Locate the Oracle client installation path (for example, c:\oracle\ora90).
Open the DOS command prompt by clicking Start > Run and typing "cmd".
Test the following command:
TNSPING <Database Name>
Check the System Path for Oracle client (for example C:\oracle\ora90\bin).
Check the TNSNAMES.ora and SQLNET.ora files. In this case, the SQLNET.ora file did not exist so it was copies to C:\oracle\ora90\network\admin.
Restart the machine.
Hope this has been helpful,
Scott
Similar Messages
-
BO Error - Connection or SQL sentence error (DA0005)
Hi All,
I am facing an issue while connecting to BO -
Connection or SQL sentence error (DA0005)
Exception: DBD, ORA-12170: TNS:Connect timeout occuredState: N/A
Funny thing is, this error occurs on some machines, whereas on some it does not. There, BO works pretty smooth. We tried exchanging the TNS files between machines, tried matching the firewall rules, but nothing works.
Any ideas on why this is happening? Thanks a lot in advance!
Cheers,
AkshayOur issue seems very similar to yours. The errors we have are:
Connection or SQL sentence error (DA0005). Unable to create connection.
or
A connection required to refresh this document is unavailable (DA0004)
or
Cannot open file due to unknown error (FRM0007)
I've tried lots of posts on google but couldn't find proper solution.
Desperately looking for help as the users are just not able to work with this kind of errors
and there's still time for us to commence the upgrade.
Wondering what's your environment. Ours as below:
BOXI R2 sp6
Database: Oracle 11g -
Getting Connection or SQL sentence error (DA0005) error
We have installed BOE XI 3.1 SP3 client tools (Deski, Webi Rich client, CR) on the citrix server, we are able to connect to the Business Objects server. When trying to create new Deski report it throughs error,
"Exception: DBD, [Microsoft][ODBC Driver Manager] Data source name not found and no default driver specifiedState: IM002"
When I tried to verify the SQL, it gave "The server is not responding" error. I am able to create the Deski report from my local machine using the same universe.
We have also installed Teradata DB drivers on the citrix server.
Any suggestions please.You should have ODBC connetion in the client machine.
Try to create the same ODBC connetion (System DSN) which you have create in the universe connetion.
Get the Database detail from DBA and create the System DSN.
This will solve your problem. -
(Error: BOMGR 0060) IDispatch error # 109 Connection or SQL sentence error
Hi all members
BO version: BO 6.5
My client is facing following error in Infoview all of sudden for last 2 weeks while viewing the published reports in an Infoview.
BusinessObjects server process raised an automation exception. (Error: BOMGR 0060) IDispatch error # 109 Connection or SQL sentence error.
(DA0005): [Exception: DBD, ORA-12154:
TNS:could not resolve the connect identifier specified State: N/A] The following data providers have not been successfully refreshed:
SQL 1 with XYZ. (DMA0007): (BSSBUWSIT0001.xxxxxx.com)
(returned by function Refreshing Document
Following is the wording of my client
"it comes to all reports, only few run smoothly, and if we restart the server it goes immediately otherwise it takes some time to get disappearu2026"
Kindly any member guide me for the resolution of this problem.
Thanks in advance
Regards,
Izhar
Edited by: izhar ahmed on Sep 29, 2008 12:03 PMHi Izhar,
Could you please review the following information it might help you to resolve the issue.
You need to check the following things.
Things to check:
1. ORACLE PATH in client SYSTEM VARIABLES:
On the Windows 2000 CLIENT user machine:
- Right-click on "My Computer" and select "Properties". The "System Properties" window appears.
- Go to the "Advanced" tab and 'Environment Variables' and under 'System Variables' window the 'path' variable.
- Click on 'Edit' and copy and paste the info into this case notes. Check if there is more than one Oracle home defined in the "Path" system variable.
- If there is more than one Oracle home defined, then edit your "Path" variable so that only one Oracle home is defined.
2. TNSNAMES.ORA:
- Check to see if any multiple copies of the "tnsnames.ora" file and the "sqlnet.ora" file are identical to each other.
There may be a problem with certain lines contained within the tnsnames.ora in C:\ORANT\NET80\ADMIN folder.
eg: [(COMMUNITY = TCP.world), (GLOBAL_NAME = LIVEServer.world)]
3. OCIW32.dll Search for these on client machine
You may have a copy of the "OCIW32.dll" file in both the Oracle client/bin and the other <Oracle application>/bin directories.
Rename or remove the "OCIW32.dll" file located in the other Oracle application /bin directory.
Note:
Please make sure that you have installed only one version of Oracle middleware, which must be the same version as the query database (ie NOT SQL Net 2.3 if you are connecting to a Oracl 8.1.6 query database)
4. CHECK THE REGISTRY ORACLE_HOME:
Check if one version of middleware on that machine, by the registry contacts. BO will look for the middleware in:
HKEY_LOCAL_MACHINE/Software/Oracle : ORACLE_HOME
Other Business Objects tests to carry out:
1. import the universe via Supervisor and go into properties -> Test connection. Any errors?
2. Check the connection - 'Edit' --> Database Engine - which Oracle driver version is being used for this universe?
3. Check the universe domain by clicking Tools -> Repository -> Click on Universe domain and Test. Also click 'Modify' to select the correct Oracle driver version.
*********MORE*****
In order to find in it all information for the connection to the database BO always checks the path of the middleware (Control Panel -> System -> Environment -> Path (eg C: ORANT) and uses the first occurrence of ociw32.dll found within the %path%. Business Objects also reads the Oracle registry and the value ORACLE_HOME to find the list of TNS but it cannot deal with two different versions of Oracle.
Consequently, both need to be synchronized to avoid a problem.
Regards,
Sarbhjeet Kaur -
I am trying to execute this sentence :
SELECT PERNR
BEGDA
ZZCPRENDA
ZZDPRENDA
ZZTPRENDA
ZZPROV from ZPREN_EMP_FUNC into (wa_entr-n_pers,
wa_entr-frecog,
wa_entr-cod_prenda,
wa_entr-descrip,
wa_entr-tall_r,
wa_entr-origen)
where subty = '0003' and begda >= ran_f-low and begda <= ran_f-high
and pernr in num_per.
But It gives me and SQL error 'Error in module RSQL of the database interface'.
It is all because of the num_per table. It contains 3001 regs.
How can I solve it ? Should I modify the maximum size of the SQL statement ? or even the space??
Thanks in advance.Hi,
check this OSS note 13607. It describes how SAP rewrites OpenSQL statement with ranges into SQL query for DB server and why there is technical limitation of number of items in range. You can try to use FOR ALL ENTRIES or split you select into more select where you will split your range into smaller chunks.
Cheers -
Error DA0005 when trying to access report
Hi everyone,
We are getting the following error when trying to access a report:
Connection or SQL syntax error (DA0005)
Exception CS, Bad Value for field: Log on failed because the required parts are not correctly initialized. Contact system administrator.
I have tried to translate the error message from dutch.
Does anyone know how to solve this?Hi,
Could you please try the following test:
This error message appears because the Connection Server is down or disabled. To start or enable the server perform the following steps:
1. Go to Start > Programs > BusinessObjects XI > BusinessObjects Enterprise > Central Configuration Manager.
2. Verify the Connection Server is started with a status of running.
3. Highlight the Connection Server and click the 'Start' button if the server is stopped.
4. Click the 'Enable/Disable Servers' button, log on, and verify there is a green up arrow next to the Connection Server.
5. Click the check box for the Connection Server and 'OK' if there is no green up arrow to enable the server.
Regards,
Deepti Bajpai -
Area or view of sql sentences with error??
Hi Gurus!
I wanna know if is there any view or something like that, where I can look for a sql sentence with error?
The views V$SQL, V$SQLAREA, V$SQLTEXT doesn't work for that because they have de last rigth sql sentences and I need the last with error.
Thanks in advance.SQL Developer maintains a history of the SQL statements that it has issued over time. That is a purely client-side function, though, it just tells you what SQL has been issued by the local client. It doesn't tell you anything about what SQL has been sent to the server by other client applications on the client machine or from other client machines.
Justin -
Hi
I 'm using SQL sentences in a customer program, for example:
EXEC SQL.
INSERT INTO ORAGNI.V_SALDOS_FATPO@INT
VALUES (:TI_SALIDA-PERNR,
:TI_SALIDA-NAME1,
TO_DATE(:C_FECHA, 'dd.mm.yyyy'),
:TI_SALIDA-DISPO,
:TI_SALIDA-SALDOP,
:TI_SALIDA-SALDOAU,
:TI_SALIDA-SALDOAO,
:TI_SALIDA-SALDOAPO,
:TI_SALIDA-SALDOAE,
:TI_SALIDA-SALDOAD,
:TI_SALIDA-DARMC,
:TI_SALIDA-SALDOT,
* :TI_SALIDA-SYSID,
:V_FONDO,
:TI_SALIDA-ULTIMO_DIV)
ENDEXEC.
EXEC SQL.
COMMIT WORK.
ENDEXEC.
But i have a dump when I run this program, this is part of the dump:
Errores tiempo ejecucióDBIF_DSQL2_SQL_ERROR
ocurrido el 07.10.2008 a 14:59:31
SQL error 1722 occurred when executing EXEC SQL.
-----------------¿Qué ha sucedido?
The error occurred in the current database connection "DEFAULT".
Other Dump:
Errores tiempo ejecucióDBIF_DSQL2_SQL_ERROR
ocurrido el 07.10.2008 a 14:59:31
SQL error 1722 occurred when executing EXEC SQL.
-----------------¿Qué ha sucedido?
The error occurred in the current database connection "DEFAULT".
How can i do to catch this mistake ?? maybe i can to use catch ... endcatch ¿how can i use it?
Regards
GregoryHi,
01722, 00000, "invalid number"
// *Cause:
// *Action:
You must be writing invalid number into a numeric field, Please check the values in the individual fields using trace and compare with the Field definition to find the error.
Thanks and Best Regards,
Sunil. -
XDK for PL/SQL install errors
Is this a problem ?
resolver :
Error while turning off verifier
ORA-29532: Java call terminated by uncaught Java exception:
java.security.AccessControlException: the Permis
sion (oracle.aurora.security.JServerPermission Verifier ) has
not been granted by dbms_java.grant_permission to
SchemaProtectionDomain(SYSTEM|PolicyTableProxy(SYSTEM))
I also get some of these ...
errors : oracle/xml/sql/dml/OracleXMLSave
ORA-29534: referenced object
SYSTEM.oracle/xml/sql/core/OracleXMLConvert could not be resolved
skipping : oracle/xml/sql/core/OracleXMLTime is already resolved
resolving: oracle/xml/sql/core/OracleXMLConvert
errors : oracle/xml/sql/core/OracleXMLConvert
ORA-29521: referenced name oracle/gss/util/XmlValidate could
not be found
resolving: oracle/xml/sql/OracleXMLSQLNoRowsException
errors : oracle/xml/sql/OracleXMLSQLNoRowsException
ORA-29534: referenced object
SYSTEM.oracle/xml/sql/OracleXMLSQLException could not be resolved
resolving: oracle/xml/sql/core/OracleXMLUtil
errors : oracle/xml/sql/core/OracleXMLUtil
ORA-29534: referenced object
SYSTEM.oracle/xml/sql/core/OracleXMLConvert could not be resolved
At the end, the final test shows ...
SQL> Rem Use these to test the results..
SQL> select dbms_xmlquery.getxml('select * from dual', 2) from
dual;
select dbms_xmlquery.getxml('select * from dual', 2) from dual
ERROR at line 1:
ORA-29541: class
SYSTEM.oracle/xml/sql/query/OracleXMLStaticQuery could not be
resolved
ORA-06512: at "SYSTEM.DBMS_XMLQUERY", line 20
ORA-06512: at "SYSTEM.DBMS_XMLQUERY", line 271
ORA-06512: at line 1
Can anyone please help. My load command was ...
./xdkload -u "system/manager" -s -noverify -dbver "817"
I'm trying to load version 9.0.2.0.0C into an 8.1.7 instance on
HP-UX 11. Before running the script, I had to set environment
variables INSTALL_ROOT, and LD_LIBRARY_PATH (we use
SHLIB_PATH). I haven't actually found any installation
instructions, so I've only got this far by poking around. Any
help is much appreciated.
SteveSounds like the same problem described in a number of posts
recently.
Re: Startup/Shutdown 9iAS on windows
http://forums.oracle.com/forums/message.jsp?id=550104
The problem is caused by unresolved classes in the XSU package
from the latest Beta, I hope someone from Oracle can take a look
at this.
Good luck!
Ola -
Java.sql.SQLException: Error while trying to retrieve text for error ORA-24
Hi All,
Am having serious problem with ORA-24327 and the behavior is very very unpredictable. I have couple of environment where the same error comes in different context. The recent one was surprising. I have describe bellow the environment configuration and the stack trace. The error which surprised me was when I use type � 3 driver while starting weblogic I get ORA �24327 but when I use Type �4 it starts properly. If you could kindly provide solution it would be great help. I would also appreciate if u can provide information which driver to use where performance is the major concern. I would also appreciate if u could provide feed-back from the industry about booth the driver. Apart from that I have couple have environment where it occurs when 10/12 user access simultaneously. All the open connection is closed in program properly still am getting the error.
Thanks in anticipation.
Cheers,
Tapas
Environment
OS - SunOS 5.8 Generic_108528-07 sun4u sparc SUNW,Ultra-Enterprise
JDK - Solaris VM (build Solaris_JDK_1.2.2_07, native threads, sunwjit)
Weblogic - 5.1.0 Service Pack 9 04/05/2001 14:59:53 #105983
Oracle � 8.1.6
Delaying 10 seconds before making a beuatpool pool connection.
Pool 1 (Type �3 )
weblogic.jdbc.connectionPool.beuatpool=\
url=jdbc:weblogic:oracle,\
driver=weblogic.jdbc.oci.Driver,\
loginDelaySecs=10,\
initialCapacity=10,\
maxCapacity=20,\
capacityIncrement=2,\
allowShrinking=true,\
shrinkPeriodMins=10,\
refreshMinutes=10,\
testTable=dual,\
props=user=xxx;password=xxx;server=xxxx
Pool 2(Type �4)
weblogic.jdbc.connectionPool.thinPool=\
url=jdbc:oracle:thin:@xxx:1521:xxx,\
driver=oracle.jdbc.driver.OracleDriver,\
loginDelaySecs=1,\
initialCapacity=1,\
maxCapacity=10,\
capacityIncrement=1,\
allowShrinking=true,\
shrinkPeriodMins=15,\
refreshMinutes=15,\
testTable=dual,\
props=user=xxx;password=xxx;server=xxx:1521:xxx
allow=everyone
---------- LOGIN ERROR CODE: 24327
java.sql.SQLException: Error while trying to retrieve text for error ORA-24327 �
at java.lang.Throwable.fillInStackTrace(Native Method)
at java.lang.Throwable.fillInStackTrace(Compiled Code)
at java.lang.Throwable.<init>(Compiled Code)
at java.lang.Exception.<init>(Compiled Code)
at java.sql.SQLException.<init>(SQLException.java:43)
at weblogic.db.oci.OciConnection.getLDAException(OciConnection.java:143)
at weblogic.jdbcbase.oci.Driver.connect(Driver.java:157)
at weblogic.jdbc.common.internal.ConnectionEnvFactory.makeConnection(Con
nectionEnvFactory.java:149)
at weblogic.jdbc.common.internal.ConnectionEnvFactory.createResource(Con
nectionEnvFactory.java:109)
at weblogic.common.internal.ResourceAllocator.makeResources(Compiled Cod
e)
at weblogic.common.internal.ResourceAllocator.<init>(Compiled Code)
at weblogic.jdbc.common.internal.ConnectionPool.startup(ConnectionPool.j
ava:330)
at weblogic.jdbc.common.internal.JdbcInfo.initPools(Compiled Code)
at weblogic.jdbc.common.internal.JdbcInfo.startup(JdbcInfo.java:200)
at weblogic.jdbc.common.internal.JdbcStartup.main(JdbcStartup.java:11)
at java.lang.reflect.Method.invoke(Native Method)
at weblogic.t3.srvr.StartupThread.runMain(StartupThread.java:219)
at weblogic.t3.srvr.StartupThread.doWork(Compiled Code)
at weblogic.t3.srvr.PropertyExecuteThread.run(PropertyExecuteThread.java
:62)
---------- LOGIN ERROR CODE: 24327
---------- LOGIN ERROR CODE: 24327
Fri Aug 31 00:57:22 GMT-05:00 2001:<I> <JDBC Pool> Sleeping in createResource()
Fri Aug 31 00:57:23 GMT-05:00 2001:<E> <JDBC Pool> Failed to create connection p
ool "beuatpool"
weblogic.common.ResourceException: weblogic.common.ResourceException:
Could not create pool connection. The DBMS driver exception was:
java.sql.SQLException: Error while trying to retrieve text for error ORA-24327 -
at java.lang.Throwable.fillInStackTrace(Native Method)
at java.lang.Throwable.fillInStackTrace(Compiled Code)
at java.lang.Throwable.<init>(Compiled Code)
at java.lang.Exception.<init>(Compiled Code)
at java.sql.SQLException.<init>(SQLException.java:43)
at weblogic.db.oci.OciConnection.getLDAException(OciConnection.java:143)
at weblogic.jdbcbase.oci.Driver.connect(Driver.java:157)
at java.sql.DriverManager.getConnection(Compiled Code)
at java.sql.DriverManager.getConnection(DriverManager.java:137)
at weblogic.jdbc.common.internal.ConnectionEnvFactory.makeConnection(Con
nectionEnvFactory.java:172)
at weblogic.jdbc.common.internal.ConnectionEnvFactory.createResource(Con
nectionEnvFactory.java:109)
at weblogic.common.internal.ResourceAllocator.makeResources(Compiled Cod
e)
at weblogic.common.internal.ResourceAllocator.<init>(Compiled Code)
at weblogic.jdbc.common.internal.ConnectionPool.startup(ConnectionPool.j
ava:330)
at weblogic.jdbc.common.internal.JdbcInfo.initPools(Compiled Code)
at weblogic.jdbc.common.internal.JdbcInfo.startup(JdbcInfo.java:200)
at weblogic.jdbc.common.internal.JdbcStartup.main(JdbcStartup.java:11)
at java.lang.reflect.Method.invoke(Native Method)
at weblogic.t3.srvr.StartupThread.runMain(StartupThread.java:219)
at weblogic.t3.srvr.StartupThread.doWork(Compiled Code)
at weblogic.t3.srvr.PropertyExecuteThread.run(PropertyExecuteThread.java
:62)
at java.lang.Throwable.fillInStackTrace(Native Method)
at java.lang.Throwable.fillInStackTrace(Compiled Code)
at java.lang.Throwable.<init>(Compiled Code)
at java.lang.Exception.<init>(Compiled Code)
at weblogic.common.ResourceException.<init>(ResourceException.java:18)
at weblogic.jdbc.common.internal.ConnectionEnvFactory.makeConnection(Con
nectionEnvFactory.java:182)
at weblogic.jdbc.common.internal.ConnectionEnvFactory.createResource(Con
nectionEnvFactory.java:109)
at weblogic.common.internal.ResourceAllocator.makeResources(Compiled Cod
e)
at weblogic.common.internal.ResourceAllocator.<init>(Compiled Code)
at weblogic.jdbc.common.internal.ConnectionPool.startup(ConnectionPool.j
ava:330)
at weblogic.jdbc.common.internal.JdbcInfo.initPools(Compiled Code)
at weblogic.jdbc.common.internal.JdbcInfo.startup(JdbcInfo.java:200)
at weblogic.jdbc.common.internal.JdbcStartup.main(JdbcStartup.java:11)
at java.lang.reflect.Method.invoke(Native Method)
at weblogic.t3.srvr.StartupThread.runMain(StartupThread.java:219)
at weblogic.t3.srvr.StartupThread.doWork(Compiled Code)
at weblogic.t3.srvr.PropertyExecuteThread.run(PropertyExecuteThread.java
:62)
at java.lang.Throwable.fillInStackTrace(Native Method)
at java.lang.Throwable.fillInStackTrace(Compiled Code)
at java.lang.Throwable.<init>(Compiled Code)
at java.lang.Exception.<init>(Compiled Code)
at weblogic.common.ResourceException.<init>(ResourceException.java:18)
at weblogic.jdbc.common.internal.ConnectionEnvFactory.createResource(Con
nectionEnvFactory.java:125)
at weblogic.common.internal.ResourceAllocator.makeResources(Compiled Cod
e)
at weblogic.common.internal.ResourceAllocator.<init>(Compiled Code)
at weblogic.jdbc.common.internal.ConnectionPool.startup(ConnectionPool.j
ava:330)
at weblogic.jdbc.common.internal.JdbcInfo.initPools(Compiled Code)
at weblogic.jdbc.common.internal.JdbcInfo.startup(JdbcInfo.java:200)
at weblogic.jdbc.common.internal.JdbcStartup.main(JdbcStartup.java:11)
at java.lang.reflect.Method.invoke(Native Method)
at weblogic.t3.srvr.StartupThread.runMain(StartupThread.java:219)
at weblogic.t3.srvr.StartupThread.doWork(Compiled Code)
at weblogic.t3.srvr.PropertyExecuteThread.run(PropertyExecuteThread.java
:62)Hi,
I guess you can try some of these:
- Make sure you're not missing an entry inside your tnsnames.ora file. Thin driver does not require the information inside that file, as opposed to Weblogic's OCI driver. If you are able to connect to the DB using a thin driver, then the problem is most probably (WL)driver-related.
- Make sure you've properly configured the DB user / password inside your weblogic.properties (config.xml if WL6+).
- Make sure you're able to access all drivers and classes required (PATH, CLASSPATH, etc...)
- Make sure the OCI driver version you are using is fully compatible with the Oracle (server) version you are pointing to.
- Try to access the DB user through some other client (for instance, SQLPlus*).
Hope this is of some help,
Freddy. -
I'm deploying an EJB Module with a CMP in SJAS from SJSE.
I get the following exception "java.sql.SQLException: Error in allocating a connection. Cause: No PasswordCredential found" the first time a CMP tries to connect to the MS SQL Server database.
I can connect through the Admin console (PING works fine) but this error hapens in runtime.
The datasource classname i'm using is "com.sun.sql.jdbcx.sqlserver.SQLServerDataSource" which is suggested by the SJSE.
Any help will be welcome...
Nelson MarquesIf you are using Netbeans, then this link might help:
http://forum.java.sun.com/thread.jspa?forumID=136&threadID=598423
Otherwise, have you try this ?
Verify your sun-ejb-jar.xml does not use default-resource-princinpal element:
<res-ref-name>jdbc/pdisasdb</res-ref-name>
<jndi-name>jdbc/pdisasdb</jndi-name>
<default-resource-principal>
<name>myname</name>
<password>geheim</password>
</default-resource-principal>
</resource-ref> -
SQL Insert Error Error in allocating a connection. Cause: No PasswordCreden
Friends,
While testing my connection in the Sun java Application Server , I get the following error .
"SQL Insert Error Error in allocating a connection. Cause: No PasswordCredential found "
Can somebody please guide ?
regards
DhirajIf you are using Netbeans, then this link might help:
http://forum.java.sun.com/thread.jspa?forumID=136&threadID=598423
Otherwise, have you try this ?
Verify your sun-ejb-jar.xml does not use default-resource-princinpal element:
<res-ref-name>jdbc/pdisasdb</res-ref-name>
<jndi-name>jdbc/pdisasdb</jndi-name>
<default-resource-principal>
<name>myname</name>
<password>geheim</password>
</default-resource-principal>
</resource-ref> -
Java.sql.SQLException: Error in allocating a connection
hi,
I have developed enterprise application using net beans IDE 5.5.I created one enity bean using sql server database.When i tried deploy this project i am getting following error...
Internal Exception: java.sql.SQLException: Error in allocating a connection.
Cause: Class name is wrong or classpath is not set for : com.microsoft.jdbc.sqlserver.SQLServerDataSourceError
can anybody please help me.....where i went wrong...i am new to netbeans IDE
regrds
patelu need to download the three jar files.
download the following jar files and add in ur classpath.
msutil-2000.sp2-lib.jar
msbase-2000.sp2-lib.jar
mssqlserver-2000.sp2-lib.jar
This is sample program...
u can test in standalone first and do in netbeans....
import java.sql.*;
public class querybean {
public String getdata(String sql) {
try {
System.out.println("testing connection ");
Class.forName("com.microsoft.jdbc.sqlserver.SQLServerDriver");
Connection connection = DriverManager.getConnection("jdbc:microsoft:sqlserver://localhost:1433;databaseName=master;user=sa;password=userpass;");
Statement statement = connection.createStatement();
ResultSet rs = statement.executeQuery(sql);
System.out.println("testing connection pooling");
while(rs.next()) {
System.out.println(rs.getString(1));
} catch(Exception e1) {
System.out.println("exception caught" + e1);
return "";
public static void main (String args[]) throws Exception {
querybean qb = new querybean();
qb.getdata("select * from sampletable");
I belive it will work now -
I am getting "ORA-00900: invalid SQL statement" error.?
I did installed oracle 11gR2. and used "DBMS_METADATA_DIFF.COMPARE_ALTER('TABLE','TBL_A','TBL_A','USER1','USER2')" to see the result like below, but I am getting "ORA-00900: invalid SQL statement" error. Any idea?
I am using:
Oracle Database 11g Enterprise Edition Release 11.2.0.1.0 - Production
PL/SQL Release 11.2.0.1.0 - Production
CORE 11.2.0.1.0 Production
TNS for 32-bit Windows: Version 11.2.0.1.0 - Production
NLSRTL Version 11.2.0.1.0 - Production
SQL> desc user1.tbl_a
Name Null? Type
FIELD_A1 NOT NULL NUMBER
FIELD_A2 VARCHAR2(20)
FIELD_A4 NOT NULL NUMBER(5,2)
FIELD_A5 VARCHAR2(10)
FIELD_A6 NOT NULL NUMBER(2)
SQL> desc user2.tbl_a
Name Null? Type
FIELD_A1 NOT NULL NUMBER
FIELD_A2 VARCHAR2(50)
FIELD_A3 DATE
FIELD_A4 NUMBER(5,2)
FIELD_A5 NOT NULL VARCHAR2(10)
SQL> select dbms_metadata_diff.compare_alter('TABLE','TBL_A','TBL_A','USER1','USER2') from dual
expected result:
DBMS_METADATA_DIFF.COMPARE_ALTER('TABLE','TBL_A','TBL_A','U1','U2')
ALTER TABLE "U1"."TBL_A" ADD ("FIELD_A3" DATE)
ALTER TABLE "U1"."TBL_A" DROP ("FIELD_A6")
ALTER TABLE "U1"."TBL_A" MODIFY ("FIELD_A2" VARCHAR2(50))
ALTER TABLE "U1"."TBL_A" MODIFY ("FIELD_A4" NUMBER(5,2) DEFAULT 0)
ALTER TABLE "U1"."TBL_A" MODIFY ("FIELD_A4" NULL)
ALTER TABLE "U1"."TBL_A" MODIFY ("FIELD_A5" NOT NULL ENABLE)Thanks for reply rp,
I got result using "select dbms_metadata_diff.compare_alter('TABLE','TBL_A','TBL_A','USER1','USER2') from dual" -
Java.sql.SQLException: Error while trying to retrieve text for error ORA-12545
Hi,
I am getting the following error when i tried to connect to Oracle database from
a servlet. This exception is coming at the time of getting connection. And the
same code is working when i used in the standalone java program.
Oracle 8i database and WLS 6.0 are on the same UNIX machine.
---------attempting to connect ------
java.sql.SQLException: Error while trying to retrieve text for error ORA-12545
at oracle.jdbc.dbaccess.DBError.throwSqlException(DBError.java, Compiled
Code)
at oracle.jdbc.oci8.OCIDBAccess.check_error(OCIDBAccess.java, Compiled C
ode)
at oracle.jdbc.oci8.OCIDBAccess.logon(OCIDBAccess.java, Compiled Code)
at oracle.jdbc.driver.OracleConnection.<init>(OracleConnection.java, Com
piled Code)
at oracle.jdbc.driver.OracleDriver.getConnectionInstance(OracleDriver.ja
va, Compiled Code)
at oracle.jdbc.driver.OracleDriver.connect(OracleDriver.java, Compiled C
ode)
at java.sql.DriverManager.getConnection(DriverManager.java, Compiled Cod
e)
at java.sql.DriverManager.getConnection(DriverManager.java, Compiled Cod
e)
at ConnectionPoolServlet.doGet(ConnectionPoolServlet.java, Compiled Code
at javax.servlet.http.HttpServlet.service(HttpServlet.java, Compiled Cod
e)
at javax.servlet.http.HttpServlet.service(HttpServlet.java, Compiled Cod
e)
at weblogic.servlet.internal.ServletStubImpl.invokeServlet(ServletStubIm
pl.java, Compiled Code)
at weblogic.servlet.internal.WebAppServletContext.invokeServlet(WebAppSe
rvletContext.java, Compiled Code)
at weblogic.servlet.internal.ServletRequestImpl.execute(ServletRequestIm
pl.java, Compiled Code)
at weblogic.kernel.ExecuteThread.execute(ExecuteThread.java, Compiled Co
de)
at weblogic.kernel.ExecuteThread.run(ExecuteThread.java, Compiled Code)
Can any one help me out.
DurgaThe problem is solved after exprting the parameter ORACLE_SID=<database_name>
in Weblogic startup script.
thank u for the suggestions.
Durga
Joseph Weinstein <[email protected]> wrote:
>
>
Durga wrote:
Hi Joe,
I have checked the ORACLE_HOME parameter. There was a differnce. Ichanged to
/oracle/app/product/8.1.7
Now i am getting different exception. But still the standalone codeis working.
any clues why I am getting this exception. I will send the code andthe weblogic
properties file for reference if u need.Good. No, I don't need it. Now make sure the library path that the OS
uses to find
Oracle libraries, and our driver libraries etc., is in the same order
for the
server as for the shell that is successful on it's own. Make sure your
Oracle
client stuff is ahead of any weblogic libraries.
Joe
java.sql.SQLException: ORA-12547: TNS:lost contact
at oracle.jdbc.dbaccess.DBError.throwSqlException(DBError.java,Compiled
Code)
at oracle.jdbc.oci8.OCIDBAccess.check_error(OCIDBAccess.java,Compiled
C
ode)
at oracle.jdbc.oci8.OCIDBAccess.logon(OCIDBAccess.java, CompiledCode)
at oracle.jdbc.driver.OracleConnection.<init>(OracleConnection.java,Com
piled Code)
at oracle.jdbc.driver.OracleDriver.connect(OracleDriver.java,Compiled
C
ode)
at oracle.jdbc.driver.OracleDriver.connect(OracleDriver.java,Compiled
C
ode)
at java.sql.DriverManager.getConnection(DriverManager.java,Compiled Cod
e)
at java.sql.DriverManager.getConnection(DriverManager.java:177)
at ConnectionPoolServlet.doGet(ConnectionPoolServlet.java,Compiled Code
at javax.servlet.http.HttpServlet.service(HttpServlet.java:740)
at javax.servlet.http.HttpServlet.service(HttpServlet.java:853)
at weblogic.servlet.internal.ServletStubImpl.getRuntimeName(ServletStubI
mpl.java, Compiled Code)
at weblogic.servlet.internal.WebAppServletContext.invokeServlet(WebAppSe
rvletContext.java, Compiled Code)
at weblogic.servlet.internal.ServletRequestImpl.execute(ServletRequestIm
pl.java:1631)
at weblogic.kernel.ExecuteThread.execute(ExecuteThread.java,Compiled
Co
de)
at weblogic.kernel.ExecuteThread.run(ExecuteThread.java, CompiledCode)
Joseph Weinstein <[email protected]> wrote:
The environment for the server probably doesn't have the same ORACLE_HOME
setting as your shell when you succeed in a standalone.
Also, you should be using our connection pools, and you should avoid
making DriverManager calls in any multithreaded app such as WebLogic.
Joe
Durga wrote:
Hi,
I am getting the following error when i tried to connect to Oracledatabase from
a servlet. This exception is coming at the time of getting connection.And the
same code is working when i used in the standalone java program.
Oracle 8i database and WLS 6.0 are on the same UNIX machine.
---------attempting to connect ------
java.sql.SQLException: Error while trying to retrieve text for errorORA-12545
at oracle.jdbc.dbaccess.DBError.throwSqlException(DBError.java,
Compiled
Code)
at oracle.jdbc.oci8.OCIDBAccess.check_error(OCIDBAccess.java, CompiledC
ode)
at oracle.jdbc.oci8.OCIDBAccess.logon(OCIDBAccess.java, Compiled
Code)
at oracle.jdbc.driver.OracleConnection.<init>(OracleConnection.java,Com
piled Code)
at oracle.jdbc.driver.OracleDriver.getConnectionInstance(OracleDriver.ja
va, Compiled Code)
at oracle.jdbc.driver.OracleDriver.connect(OracleDriver.java, CompiledC
ode)
at java.sql.DriverManager.getConnection(DriverManager.java, CompiledCod
e)
at java.sql.DriverManager.getConnection(DriverManager.java, CompiledCod
e)
at ConnectionPoolServlet.doGet(ConnectionPoolServlet.java, CompiledCode
at javax.servlet.http.HttpServlet.service(HttpServlet.java, CompiledCod
e)
at javax.servlet.http.HttpServlet.service(HttpServlet.java, CompiledCod
e)
at weblogic.servlet.internal.ServletStubImpl.invokeServlet(ServletStubIm
pl.java, Compiled Code)
at weblogic.servlet.internal.WebAppServletContext.invokeServlet(WebAppSe
rvletContext.java, Compiled Code)
at weblogic.servlet.internal.ServletRequestImpl.execute(ServletRequestIm
pl.java, Compiled Code)
at weblogic.kernel.ExecuteThread.execute(ExecuteThread.java, CompiledCo
de)
at weblogic.kernel.ExecuteThread.run(ExecuteThread.java, Compiled
Code)
Can any one help me out.
Durga
Maybe you are looking for
-
Having problems with Home Sharing with the WiFi. Can not seem to get the Apple TV to connect to my iTunes. Must be something running in the background of the router or laptop. Need help.
-
Recovery of photos after reformatting
Hi, I had to reformat and reinstall Snow Leopard OS X 10.6.8 after a hard drive problem. Unfortunately I have not backed up my photos and videos as I was using the mac rarely so I thought nothing can go wrong. Now I know better! I would like to know
-
Best Practices to separate voice and Data vlans
Hello All . I am coming to the community to get some advices on a specific subject . One of my customer is actually using vlan access-list to isolate it is data from it is voice vlan traffic . As most of us knows VLAN ACLs are very difficult to depl
-
Starting many instances of a sub workflow
Hi, I'm trying to create a scenario using WLPI studio wherein from a parent workflow task I want to start a number of instances of a sub workflow. I want that completion of all the sub workflow instances should lead to completion of the parent workfl
-
My fourth gen is frozen on the software update page
Hi, yesterday i went to update my ipod touch 4g (8gigs) to the new 4.3.4 from 4.3.3 and everthing was going normal until it went to go and install the new software, the usb-itunes picture thing poped up on my itouch's screen then it went to just the