on 08-24-2005 11:28 AM
Hi all,
I try to get data from a sapdb database but I get the following error in my webdynpro, No suitable driver.
I have added the sapdbc.jar file in the Lib folder of the webdynpro application. I have used the sapdbc.jar from the installed SAPDB database.
I use was 6.40 on SAPDB
Can someone tell me what the problem is and how do I solve this problem.
Regards,
Richard
Hi,
This is the source code I use in my webdynpro
String url = "jdbc:sapdb//ipoint/J2E";
String text;
IPrivateIndustryTypeView.IIndustryListElement newIndustryListElement;
try
{
Class.forName("com.sap.dbtech.jdbc.DriverSapDB");
Connection connect = DriverManager.getConnection(url,"SAPJ2EDB","portals");
text = "connection:" + connect;
wdContext.currentContextElement().setText(text);
Statement stmt = connect.createStatement();
ResultSet result = stmt.executeQuery("Select * from be_industry");
while(result.next())
{
newIndustryListElement = wdContext.createIndustryListElement();
newIndustryListElement.setIndustry_id(result.getInt("industry_id"));
newIndustryListElement.setIndustry_text(result.getString("industr_text"));
wdContext.nodeIndustryList().addElement(newIndustryListElement);
}
result.close();
}
catch(Exception e)
{
wdContext.currentContextElement().setText(e.toString());
}
I put in the sapdbc.jar in the lib folder of the webdynpro and in the project properties I put the sapdbc.jar file in the java build path.
Regards,
Richard
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hi Armin,
Thank for your help. The problem is solved.
Regards,
Richard
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hi Armin,
thanks for your source. I have changed and this is the result.
An error has occurred:
"Failed to process the request."
Please contact your system administrator.
-
Hide details
Web Dynpro client:
HTML Client
Web Dynpro client capabilities:
User agent: Mozilla/4.0 (compatible; MSIE 6.0; Windows NT 5.2; SV1; .NET CLR 1.1.4322), version: null, DOM version: null, client type: msie6, client type profile: ie6, ActiveX: enabled, Cookies: enabled, Frames: enabled, Java applets: enabled, JavaScript: enabled, Tables: enabled, VB Script: enabled
Web Dynpro runtime:
Vendor: SAP, Build ID: 6.4009.00.0000.20041104173322.0000 (release=630_REL, buildtime=2004-11-18:22:17:10[UTC], changelist=298578, host=PWDFM027)
Web Dynpro code generators of DC local/maintain_industry_type:
SapDictionaryGenerationCore: 6.4009.00.0000.20041026131628.0000 (release=630_REL, buildtime=2004-11-02:22:13:11[UTC], changelist=295793, host=PWDFM027.wdf.sap.corp)
SapMetamodelWebDynpro: 6.4009.00.0000.20041026132448.0000 (release=630_REL, buildtime=2004-11-02:22:17:25[UTC], changelist=295810, host=PWDFM027.wdf.sap.corp)
SapMetamodelCore: 6.4009.00.0000.20040909194107.0000 (release=630_REL, buildtime=2004-11-02:22:06:29[UTC], changelist=280398, host=PWDFM027.wdf.sap.corp)
SapWebDynproGenerationTemplates: 6.4009.00.0000.20041102105304.0000 (release=630_REL, buildtime=2004-11-02:22:38:06[UTC], changelist=297524, host=PWDFM027)
SapWebDynproGenerationCTemplates: 6.4009.00.0000.20041102105304.0000 (release=630_REL, buildtime=2004-11-02:22:38:06[UTC], changelist=297524, host=PWDFM027)
SapGenerationFrameworkCore: 6.4009.00.0000.20041026132141.0000 (release=630_REL, buildtime=2004-11-02:22:05:28[UTC], changelist=295805, host=PWDFM027.wdf.sap.corp)
SapIdeWebDynproCheckLayer: 6.4009.00.0000.20041026133106.0000 (release=630_REL, buildtime=2004-11-02:22:21:59[UTC], changelist=295820, host=PWDFM027.wdf.sap.corp)
SapMetamodelDictionary: 6.4009.00.0000.20040805191532.0000 (release=630_REL, buildtime=2004-11-02:22:10:20[UTC], changelist=270520, host=PWDFM027.wdf.sap.corp)
SapMetamodelCommon: 6.4009.00.0000.20040909194107.0000 (release=630_REL, buildtime=2004-11-02:22:06:42[UTC], changelist=280398, host=PWDFM027.wdf.sap.corp)
SapWebDynproGenerationCore: 6.4009.00.0000.20041026133106.0000 (release=630_REL, buildtime=2004-11-02:22:22:31[UTC], changelist=295820, host=PWDFM027.wdf.sap.corp)
SapDictionaryGenerationTemplates: (unknown)
Web Dynpro code generators of DC sap.com/tcwddispwda:
No information available
Web Dynpro code generators of DC sap.com/tcwdcorecomp:
No information available
J2EE Engine:
No information available
Java VM:
Java HotSpot(TM) Server VM, version: 1.4.2_07-b05, vendor: Sun Microsystems Inc.
Operating system:
Windows 2003, version: 5.2, architecture: x86
-
Error stacktrace:
com.sap.tc.webdynpro.services.exceptions.WDRuntimeException: No suitable driver
at com.bearingpoint.becontact.industry.IndustryTypeView.wdDoInit(IndustryTypeView.java:130)
at com.bearingpoint.becontact.industry.wdp.InternalIndustryTypeView.wdDoInit(InternalIndustryTypeView.java:117)
at com.sap.tc.webdynpro.progmodel.generation.DelegatingView.doInit(DelegatingView.java:61)
at com.sap.tc.webdynpro.progmodel.controller.Controller.initController(Controller.java:215)
at com.sap.tc.webdynpro.progmodel.view.View.initController(View.java:274)
at com.sap.tc.webdynpro.progmodel.controller.Controller.init(Controller.java:200)
at com.sap.tc.webdynpro.progmodel.view.ViewManager.getView(ViewManager.java:540)
at com.sap.tc.webdynpro.progmodel.view.ViewManager.bindRoot(ViewManager.java:422)
at com.sap.tc.webdynpro.progmodel.view.ViewManager.init(ViewManager.java:130)
at com.sap.tc.webdynpro.progmodel.view.InterfaceView.initController(InterfaceView.java:41)
at com.sap.tc.webdynpro.progmodel.controller.Controller.init(Controller.java:200)
at com.sap.tc.webdynpro.clientserver.cal.ClientComponent.displayToplevelComponent(ClientComponent.java:134)
at com.sap.tc.webdynpro.clientserver.cal.ClientApplication.init(ClientApplication.java:374)
at com.sap.tc.webdynpro.clientserver.task.WebDynproMainTask.execute(WebDynproMainTask.java:593)
at com.sap.tc.webdynpro.clientserver.cal.AbstractClient.executeTasks(AbstractClient.java:59)
at com.sap.tc.webdynpro.clientserver.cal.ClientManager.doProcessing(ClientManager.java:249)
at com.sap.tc.webdynpro.serverimpl.defaultimpl.DispatcherServlet.doWebDynproProcessing(DispatcherServlet.java:154)
at com.sap.tc.webdynpro.serverimpl.defaultimpl.DispatcherServlet.doContent(DispatcherServlet.java:116)
at com.sap.tc.webdynpro.serverimpl.defaultimpl.DispatcherServlet.doGet(DispatcherServlet.java:48)
at javax.servlet.http.HttpServlet.service(HttpServlet.java:740)
at javax.servlet.http.HttpServlet.service(HttpServlet.java:853)
at com.sap.engine.services.servlets_jsp.server.HttpHandlerImpl.runServlet(HttpHandlerImpl.java:385)
at com.sap.engine.services.servlets_jsp.server.HttpHandlerImpl.handleRequest(HttpHandlerImpl.java:263)
at com.sap.engine.services.httpserver.server.RequestAnalizer.startServlet(RequestAnalizer.java:340)
at com.sap.engine.services.httpserver.server.RequestAnalizer.startServlet(RequestAnalizer.java:318)
at com.sap.engine.services.httpserver.server.RequestAnalizer.invokeWebContainer(RequestAnalizer.java:821)
at com.sap.engine.services.httpserver.server.RequestAnalizer.handle(RequestAnalizer.java:239)
at com.sap.engine.services.httpserver.server.Client.handle(Client.java:92)
at com.sap.engine.services.httpserver.server.Processor.request(Processor.java:147)
at com.sap.engine.core.service630.context.cluster.session.ApplicationSessionMessageListener.process(ApplicationSessionMessageListener.java:37)
at com.sap.engine.core.cluster.impl6.session.UnorderedChannel$MessageRunner.run(UnorderedChannel.java:71)
at com.sap.engine.core.thread.impl3.ActionObject.run(ActionObject.java:37)
at java.security.AccessController.doPrivileged(Native Method)
at com.sap.engine.core.thread.impl3.SingleThread.execute(SingleThread.java:94)
at com.sap.engine.core.thread.impl3.SingleThread.run(SingleThread.java:162)
Caused by: java.sql.SQLException: No suitable driver
at java.sql.DriverManager.getConnection(DriverManager.java:532)
at java.sql.DriverManager.getConnection(DriverManager.java:171)
at com.bearingpoint.becontact.industry.IndustryTypeView.wdDoInit(IndustryTypeView.java:111)
... 34 more
Richard
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hi Armin,
Do you have a example for me, I new at this stuf.
regards,
Richard
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hi,
How you are creating the connection btw webdynpro and SAPDB ?
1.Create JDBC connection is visualAdministrator.
2.Use the driver in the webdynpro to establish the connection.
Regards, Anilkumar
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
User | Count |
---|---|
93 | |
10 | |
10 | |
9 | |
9 | |
7 | |
6 | |
5 | |
5 | |
4 |
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.