This is from a PlugIn that has access to the ActionServlet, modify accordingly:

DataSource ds = (DataSource) servlet.getServletContext().getAttribute(Globals.DATA_SOURCE_KEY);



David



From: Jim Bruno Goldberg <[EMAIL PROTECTED]>
Reply-To: "Struts Users Mailing List" <[EMAIL PROTECTED]>
To: Struts Users Mailing List <[EMAIL PROTECTED]>
Subject: Re: DataSource
Date: Wed, 27 Nov 2002 17:35:54 -0200


I try this code, but I dont work because I don known where is
dataSource. Can someone a .java complete (with imports)? Thanks a lot.

Gemes Tibor wrote:
>
> 2002. november 27. 12:49 d�tummal Jim Bruno Goldberg ezt �rtad:
> > Hi, people!
> >
> > Someone can send me a example class with DataSource access
> > defined on
> > struts-config? How can I do this? I don find any examples on struts
> > files...... Thanks again.
>
> Reading the docs?
>
> http://jakarta.apache.org/struts/userGuide/building_model.html#databases
>
> Tib
>
> --
> To unsubscribe, e-mail: <mailto:[EMAIL PROTECTED]>
> For additional commands, e-mail: <mailto:[EMAIL PROTECTED]>

--
CUL8R,[]s
Jim Bruno Goldberg
http://www.prosites.com.br

--
To unsubscribe, e-mail: <mailto:[EMAIL PROTECTED]>
For additional commands, e-mail: <mailto:[EMAIL PROTECTED]>

_________________________________________________________________
Tired of spam? Get advanced junk mail protection with MSN 8. http://join.msn.com/?page=features/junkmail


--
To unsubscribe, e-mail: <mailto:[EMAIL PROTECTED]>
For additional commands, e-mail: <mailto:[EMAIL PROTECTED]>

Reply via email to