struts-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Jack R." <radienssm...@hotmail.com>
Subject Change Struts Example to use an actual database
Date Thu, 05 Dec 2002 15:59:50 GMT
Hi,

I am learning how Struts works with an database, so I am trying to change
Struts Example (struts-example.war) to use an actual database for user data.

Can you please tell me what I need to do to achieve that? I notice it has
the following data source configuration in struts-config.xml, do I just need
to change that to point to my database? How should I create a table in my
database first? And where in the code is the user data being writtin to the
database? I can only find code for MemoryDatabase.

Thanks for any help.



<!--

<data-sources>

<data-source>

<set-property property="autoCommit"

value="false"/>

<set-property property="description"

value="Example Data Source Configuration"/>

<set-property property="driverClass"

value="org.postgresql.Driver"/>

<set-property property="maxCount"

value="4"/>

<set-property property="minCount"

value="2"/>

<set-property property="password"

value="mypassword"/>

<set-property property="url"

value="jdbc:postgresql://localhost/mydatabase"/>

<set-property property="user"

value="myusername"/>

</data-source>

</data-sources>

-->

--
To unsubscribe, e-mail:   <mailto:struts-user-unsubscribe@jakarta.apache.org>
For additional commands, e-mail: <mailto:struts-user-help@jakarta.apache.org>


Mime
View raw message