Sure, sorry about that. After one builds his application and creates his .jsp file per Apple's docs, one of the products in the Servlet Resources->WEB-INF folder will be a doc called web.xml. In it you will find the following:

  <resource-ref>
<description>The data source to be used by EOF. If there are multiple data sources, then the definition below must be used to configure which JDBC URL (Model) should use which data source. If EOF should use a JDBC driver directly, this section must be commented out</description>
    <res-ref-name>jdbc/DefaultDataSource</res-ref-name>
    <res-type>javax.sql.DataSource</res-type>
    <res-auth>Container</res-auth>
  </resource-ref>

Since I used XCode to create my EOModel and I specified the connection in it when i set it up, I just commented this section out as it says to do in the description. And Viola! my app works beautifully.

Sidebar, I've seen some posts (including my own) about how to use WebObjects with OpenLaszlo. While I am sure there are several different ways (SOAP, XML-RPC, etc) I am using JSP as a go between. So far I got it to populate a window of info from a WebObjects component. Next step (no pun intended) will be to invoke direct actions (e.g. add, edit, delete). Should have that test done tonight.

If there's an easier way, I could find no tutorial or combination of tutorials to show me the way.

On Aug 1, 2007, at 3:47 PM, Chuck Hill wrote:

Can you post what was wrong so that others can benefit from it in the future?

Thanks
Chuck


On Aug 1, 2007, at 1:34 PM, Daniel Brajkovic wrote:

Figured it out. Had to comment out a section in the web.xml file. It works now. Thanks.


On Aug 1, 2007, at 1:42 PM, Chuck Hill wrote:

It is probably a classpath problem: lack of JDBC driver or lack of EOF plugin. Try adding the attached class and see if it tells you anything useful.

Chuck

<EOFJDBCConnectionAnalyzer.java>


On Aug 1, 2007, at 11:28 AM, Daniel Brajkovic wrote:

This is killing me and it's holding up my entire project.

I have written a simple WO app and it works fine when i build and run it. But I want it to wo works with JavaServer Pages and so I am deploying it in a servlet. A simple Hello World app works fine. But as soon as I try to access a db app I get this:

Error: java.lang.IllegalStateException: _obtainOpenChannel -- com.webobjects.eoaccess.EODatabaseContext [EMAIL PROTECTED]: failed to open database channel. Check your connection dictionary, and ensure your database is correctly configured.

Does anyone know how to fix this?

Dan
_______________________________________________
Do not post admin requests to the list. They will be ignored.
Webobjects-dev mailing list      (Webobjects-dev@lists.apple.com)
Help/Unsubscribe/Update your Subscription:
http://lists.apple.com/mailman/options/webobjects-dev/chill% 40global-village.net

This email sent to [EMAIL PROTECTED]


--

Practical WebObjects - for developers who want to increase their overall knowledge of WebObjects or who are trying to solve specific problems.
http://www.global-village.net/products/practical_webobjects








--

Practical WebObjects - for developers who want to increase their overall knowledge of WebObjects or who are trying to solve specific problems.
http://www.global-village.net/products/practical_webobjects







_______________________________________________
Do not post admin requests to the list. They will be ignored.
Webobjects-dev mailing list      (Webobjects-dev@lists.apple.com)
Help/Unsubscribe/Update your Subscription:
http://lists.apple.com/mailman/options/webobjects-dev/archive%40mail-archive.com

This email sent to [EMAIL PROTECTED]

Reply via email to