Win a copy of Programming with Types this week in the Angular and TypeScript forum
or The Design of Web APIs in the Web Services forum!

Ishika

Greenhorn
+ Follow
since Aug 07, 2008
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 Ishika

Hello ranchers,
Can one provide me with code for uploadin multiple files in spring.

Any help will be appreciated.
Thnks,
hello All,

I m able to download a file from server using spring..I can download text file,doc files etc. But not images.
I m using this code...




Any help will be appreciated..
thnks in advance
Hello ranchers,
can any one provide me with the code for downloading a file using spring.
thnks in advance

hey,
got that working to..
just added the following code which gets the file name.



Any ways thnks for the help.
Hello ranchers,
Thanks a lot now i m able to upload file.But facing one problem.
ie.If my file is text file ,it is not getting saved as text file,it is getting saved without any extension.For opening that file i have always do a
openwith -->Notepad.
any help will be appreciated.
Thanks in advance.
thnks,but my html file is same as the one you posted..but still it is not working.
hello ranchers,


My Controller Code :



My problem is :In my controller
MultipartFile multipart = multipartRequest.getFile("file1");
returns null....
Which is it returning null....

Please help me....
Hello All,
Please gimme somr sample project for uploading a file using spring.

Thanks in advcance
thnks...but i want a small tutorial....so that i can refer it .....apply the same to my project...
hello,
Can any one provide me a example application for uploading a file using spring.
I referred this link
http://static.springframework.org/spring/docs/2.0.x/reference/mvc.html
but it not wroking.

Thanks in advance,
Hello Ranchers,
WE are using ireport for producing word documents.
My report has multiple section.Each section is put in a table.
Now,my problem is how to hide a table when no data is present in that section.
This has become a major issue...........
Thanks ,
Saloon Java Ranch User
Hi!!
Can any one help me to configure multiple database using spring and jdbc.

Problem Statement:
My application needs to have functionality of year wise login.So for that I have 3 datasources db0607, db0708, db0809 and by default it points to db0809. I thought of using AbstractRoutingDataSource.
However,I recognized a problem.I would switch to a Datasource say db0708, and then navigate around and realize that i am back at the default db0809. I can't seem to figure out how to fix this.How would i go about fixing this?

This is how my Code goes



Dao Code:


application-data.xml code :

<bean name="employeeDao" class="com.testdb.testeg.persistance.EmployeeDaoImpl">
<property name="dataSource">
<ref bean="dataSource">
</property>
</bean>

<bean id="parentDataSource"
class="org.springframework.jdbc.datasource.DriverManagerDataSource"
abstract="true">
<property name="driverClassName" value="oracle.jdbc.driver.OracleDriver"/>
<property name="url">
<value>jdbc:racle:thin:@localhost:1521:XE</value>
</property>
</bean>

<bean id="dataSource0809" parent="parentDataSource">
<property name="username" value="${db.0809.username}"></property>
<property name="password" value="${db.0809.password}"></property>

</bean>


<bean id="dataSource0708" parent="parentDataSource">
<property name="username" value="${db.0708.username}"></property>
<property name="password" value="${db.0708.password}"></property>
</bean>
<bean class="org.springframework.beans.factory.config.PropertyPlaceholderConfigurer">
<property name="location" value="WEB-INF/db.properties"/>
</bean>

<bean id="dataSource" class="com.testdb.testeg.web.LoginRoutingDataSource">
<property name="targetDataSources">
<map >
<entry key="com.testdb.testeg.web.LoginType.login0708" value-ref="dataSource0708"/>
<entry key="com.testdb.testeg.web.LoginType.login0809" value-ref="dataSource0809"/>
</map>
</property>
<property name="defaultTargetDataSource" ref="dataSource0809"/>
</bean>


Thanks in Advance,
Java Ranch User
[ August 11, 2008: Message edited by: dev Cats ]