Pradeep JD

Greenhorn
+ Follow
since Oct 09, 2008
Merit badge: grant badges
For More
Cows and Likes
Cows
Total received
0
In last 30 days
0
Total given
0
Likes
Total received
0
Received in last 30 days
0
Total given
0
Given in last 30 days
0
Forums and Threads
Scavenger Hunt
expand Ranch Hand Scavenger Hunt
expand Greenhorn Scavenger Hunt

Recent posts by Pradeep JD

Thank you for your guidance.

I achieved it as given below

<bean id="applicationConstants" class="java.util.HashMap">
<constructor-arg>
<map>
<entry>
<key>
<value>India</value>
</key>
<value>INR</value>
</entry>
<entry>
<key>
<value>Japan</value>
</key>
<value>YEN</value>
</entry>
</map>
</constructor-arg>
</bean>
I need to load a xml file containing the country names and their currency. Is it possible to load it by configuring in ApplicationContext.xml ? Please provide ma a psudo on how to load and access it in code.
Its much like loading a MAP in to the context and accessing it in code.
Thank you Bhaskar Rao
15 years ago
I am using "mask" in struts validator framework to validate the name fields for allowed characters but I also need to accept Cyrillic (Russian names) characters as input.
Please let me know whether there is any way to handle this in Regular expression ?

The expression that I am using now is ^[a-zA-Z-.,' ]*$

Please advice me.
15 years ago
Thanks a lot.

I Archived it by adding a Filter which will set the encoding type to CP1251 for every request, since passing it as JVM param alone is not solving the issue.

request.setCharacterEncoding("cp1251");
15 years ago
I ma using tomcat 6. I want to configure database connection pool, If i use the below method it works fine
<Context path="/test">
<Resourcename="jdbc/test"
auth="Container"
type="com.ibm.db2.jcc.DB2SimpleDataSource"
factory="com.ibm.db2.jcc.DB2DataSourceFactory"
user="test"
password="Password!"
serverName="172.16.2.234"
databaseName="db2"
portNumber="2668"
driverType="4"
testOnBorrow="true"
url="jdbc:db2://172.16.2.234:2668/db2"/>
</Context>

But I need to make global.

I tried by giving the same under <GlobalNamingResources> without the context but it is not working.

Please suggest me whether it is possible to create DBCP without context ?
15 years ago