aspose file tools*
The moose likes HTML, CSS and JavaScript and the fly likes How to retrive data from database using Ajax without submit Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login
JavaRanch » Java Forums » Engineering » HTML, CSS and JavaScript
Bookmark "How to retrive data from database using Ajax without submit" Watch "How to retrive data from database using Ajax without submit" New topic
Author

How to retrive data from database using Ajax without submit

R Sugan
Ranch Hand

Joined: Mar 13, 2009
Posts: 48
Hi,

I am new to Ajax.I need how to retrive data from database using ajax.Is it possible to get the data from database .Please give me any sample code.






Regards,
Suganya.
David Newton
Author
Rancher

Joined: Sep 29, 2008
Posts: 12617

The Ajax part only handles the client side. Most client-side JS libraries you're likely to be using have Ajax support built in; how you handle DB access depends on your back-end.
R Sugan
Ranch Hand

Joined: Mar 13, 2009
Posts: 48
Hi,


Thanks David Newton.



Regards,
Suganya.
R Sugan
Ranch Hand

Joined: Mar 13, 2009
Posts: 48
Hi David,
I am using java servlet program in that i have include ajax program.Main purpose for using ajax program is to refresh servlet program automatically.If any value changes in database it should get the value and redirect to next page.whether it is possible to do without submit button.

Regards,
Suganya.
Bear Bibeault
Author and ninkuma
Marshal

Joined: Jan 10, 2002
Posts: 61206
    
  66

You can trigger an Ajax call on any event that occurs on the client. What you cannot do is to cause something to happen from the server when a value in the database changes. The activity needs to be initiated on the client.

Rather than positing a solution, why don't you explain what you are actually trying to accomplish?


[Asking smart questions] [Bear's FrontMan] [About Bear] [Books by Bear]
 
I agree. Here's the link: http://aspose.com/file-tools
 
subject: How to retrive data from database using Ajax without submit