SQL Server Forums
Profile | Register | Active Topics | Members | Search | Forum FAQ
 
Register Now and get your question answered!
Username:
Password:
Save Password
Forgot your Password?

 All Forums
 General SQL Server Forums
 New to SQL Server Programming
 How to push data from MSSql server 2012
 New Topic  Reply to Topic
 Printer Friendly
Author Previous Topic Topic Next Topic  

grandhi
Starting Member

31 Posts

Posted - 06/17/2013 :  04:31:11  Show Profile  Reply with Quote
Hi All,

I have 2 databases name are responceDB,requestDB and 1 Web App,I placed this web App in Apache Tomcat.

Actually we have requestDB in USA and responceDB in INDIA.just for my testing purpose I created 2 databases in my local system.

Actually what I want,if database(requestDB) is modify at anytime,it sends HTTP-request to the web-App,inside App some computation will be happen based on modification on requestDB and finally that compute data will be stored in responceDB.

End-users should not interact with web-App,it's just for internal computation.

If you do like this, I don't need to monitor requestDB at every time.

I hope,you understood what my problem.

I searched in Google for this,I didn't get anything.

If you know any materials for this concept,mention the links.

Which concept is better to solve this.

Thanks

visakh16
Very Important crosS Applying yaK Herder

India
52317 Posts

Posted - 06/17/2013 :  04:38:01  Show Profile  Reply with Quote
what you could do is to trigger a sql agent job periodically for this http request. There should be a queue tale (control table) which logs the changes to requestDB through a trigger. The sql agent job checks for records in the table with status open and processes it one by one
you can check below thread for http request from sql
http://www.sqlteam.com/forums/topic.asp?TOPIC_ID=18425

At the end of processing make status as Completed in queue table so it wont be picked again next time job runs. The job schedule can be set to a frequency as you desire like 15mts, 3mts, 1 hr etc

------------------------------------------------------------------------------------------------------
SQL Server MVP
http://visakhm.blogspot.com/
https://www.facebook.com/VmBlogs
Go to Top of Page

grandhi
Starting Member

31 Posts

Posted - 06/17/2013 :  06:04:33  Show Profile  Reply with Quote
@visakh Thanks for your reply.

as per my understanding using Stored procedure,we can send HTTP request from sql server 2012 to my App.

Is it right ?

Even I don't know, how to create stored procedure.I will check it Google.
Go to Top of Page

visakh16
Very Important crosS Applying yaK Herder

India
52317 Posts

Posted - 06/17/2013 :  06:08:16  Show Profile  Reply with Quote
quote:
Originally posted by grandhi

@visakh Thanks for your reply.

as per my understanding using Stored procedure,we can send HTTP request from sql server 2012 to my App.

Is it right ?

Even I don't know, how to create stored procedure.I will check it Google.


yep...you may wrap it inside a procedure or you may even call it via adhoc sql. the logic would be something like that in the posted link.
You can call the stored procedure or sql from the sql agent job.

------------------------------------------------------------------------------------------------------
SQL Server MVP
http://visakhm.blogspot.com/
https://www.facebook.com/VmBlogs
Go to Top of Page
  Previous Topic Topic Next Topic  
 New Topic  Reply to Topic
 Printer Friendly
Jump To:
SQL Server Forums © 2000-2009 SQLTeam Publishing, LLC Go To Top Of Page
This page was generated in 0.16 seconds. Powered By: Snitz Forums 2000