Home | Contact Us | FAQ | Search & Site Map | Link to Us
Sign In | Join | Other 45 Sites in Network
HomeAnnouncementsWhite Papers
Discussion GroupsFirst AidDatabasesJavaBeansGUIJava 3DVirtual MachineCORBASecurityToolsGeneral
Java DirectoryOpen Source ProjectsSample Book ChaptersUser GroupsWeb Resources
Related Topics
Databases.NETMore Topics ...

Java Forum / JavaBeans / October 2006

Tip: Looking for answers? Try searching our database.

How to get the updated data from database.

Thread view: 
jacksuyu@gmail.com - 07 Oct 2006 03:36 GMT
My backing bean has some method to get data from database. Like;
public Collection getClients() {
   Collection c = accountEntityBean.getClients();
   return c;
}
In my web page, there will be a client list to show out.
The problem is after I created a new client, the new client data could
added to database. But the client list is still the old list. Only
after I redeploy my project I could see that new data.
My backing bean is a session bean. So how could I get the updated data
from database.

Thanks a lot!
simon.martinelli@gmail.com - 08 Oct 2006 16:59 GMT
Hi,

I'm not sure that I exactly understand your question.

Do you create the new client over the web application?
If so you have to do a refresh of the page and call the method
getClients() again.

Regards, Simon
jacksuyu@gmail.com - 09 Oct 2006 04:08 GMT
Hi,
Thanks for your reply.
Yes, I create a new client in the web application. After I create it, I
go to showClients page to see. There are only old data. What do you
mean to refresh the page. Click the refresh button of the browser? It's
useless. Still the old data. When I go to the databse. I refresh the
database and see my new data there.

Thanks again.
> Hi,
>
[quoted text clipped - 5 lines]
>
> Regards, Simon
simon.martinelli@gmail.com - 09 Oct 2006 08:30 GMT
A ok.
Is accountEntityBean an EntityBean and if so which version?
jacksuyu@gmail.com - 09 Oct 2006 16:03 GMT
accountEntityBean is a EntityBean. I create the entity bean using
NetBeans 5.5 Beta 2 from database table. So I think the version should
be 2.0, right?

Thanks.
> A ok.
> Is accountEntityBean an EntityBean and if so which version?


Free Magazines

Get these publications absolutely FREE for up to 12 months. There are no hidden fees and no obligation. Simply choose a title, complete the application form and submit it. Read more ...

Oracle MagazineNetwork ComputingComputer WorldBio-IT WorldeWeekInformation WeekInfosecurity
 
Sign In
Join
My Latest Posts
My Monitored Threads
My Blog
My Photo Gallery
My Profile
My Homepage

Start New Thread
Enable EMail Alerts
Rate this Thread



©2008 Advenet LLC   Privacy Policy - Terms of Use
This website includes both content owned or controlled by Advenet as well as content owned or controlled by third parties.