Free Newsletters:
DatabaseDaily  
Database Journal
Search Database Journal:
 
MS SQL Oracle DB2 Access MySQL PostgreSQL Sybase PHP SQL Etc SQL Scripts & Samples Links Database Forum DBA Videos
internet.com

» Database Journal Home
» DBA Videos
» Database Articles
» Database Tutorials
MS SQL
Oracle
MS Access
MySQL
DB2
» RESOURCES
Database Tools
SQL Scripts & Samples
Links
» Database Forum
» DBA Jobs
» Sitemap

News Via RSS Feed



follow us on Twitter

Marketplace Partners
Be a Marketplace Partner

internet.commerce
Be a Commerce Partner


















Mariposa Bot Shipped With Vodafone Smartphone

IT Job Market Heating Up: Report

Bing Makes Strides But Momentum Stalls

internet.com
IT
Developer
Internet News
Small Business
Personal Technology

Search internet.com
Advertise
Corporate Info
Newsletters
Tech Jobs
E-mail Offers


Database Journal | DBA Support | SQLCourse | SQLCourse2







Related Articles
DB2 9.5 and IBM Data Studio - Part 10: Building Stored Procedures
DB2 9.5 and IBM Data Studio: Part 7: The SQL Builder’s Development Accelerators

Database Administrator - SQL Server (PA)
Next Step Systems
US-PA-King of Prussia

Justtechjobs.com Post A Job | Post A Resume

Featured Database Articles

DB2

November 17, 2008

Transforming Business Logic into Web Services Using DB2 9.5 and IBM Data Studio

By Paul Zikopoulos

What about wrapping my stored procedures as Web services?

Earlier in this article, I mentioned that you could wrap Web services around stored procedures or SQL statements. In “DB2 9.5 and IBM Data Studio Part 10: Building Stored Procedures” I showed you how to create and deploy a stored procedure using the FEMALEPERSONNEL SQL statement built earlier in this series. The method by which you build and deploy a Web service that wraps a stored procedure is the same as shown earlier in this article for an SQL statement; the obvious difference is that you drag a stored procedure instead of an SQL statement.

If you completed all the steps in Part 10, when you expand the SAMPLE database in the Database Explorer view, the Stored Procedures folder should include the SP_FEMALEPERSONNEL stored procedure:

when you expand the SAMPLE database in the Database Explorer view, the Stored Procedures folder should include the SP_FEMALEPERSONNEL stored procedure

If you want to expose the SP_FEMALEPERSONNEL stored procedure through a Web service, just drag the stored procedure to the same folder you used for the SQL statement in Step 3 of this article. In this case, since you are working with a routine that has been deployed to a data server, expand that data server’s connection object and locate the stored procedure in the Stored Procedures folder within the Data Project Explorer view:

expand that data server's connection object and locate the stored procedure in the Stored Procedures folder within the Data Project Explorer view

To add this stored procedure to your Web service, you would simply drag the stored procedure to the SOA_FEMALEPERSONNEL folder, and then build and deploy the Web service in the same manner (and using the same options) as you did in Step 7.

Upon the successful redeployment of the Web service, you can now see that both the SQL statement and the stored procedure (which return the same result) are now part of the Web service and part of the Web Services Explorer:

you can now see that both the SQL statement and the stored procedure (which return the same result) are now part of the Web service and part of the Web Services Explorer

You can see that the Navigator pane in the Web Services Explorer now includes the SP_FEMALEPERSONNEL stored procedure. If you wanted to test the Web service invocation of the stored procedure, you would simply follow the instructions in Step 8.

Wrapping it all up

In this article, I showed you how to take the FEMALEPERSONNEL SQL statement that you built earlier in this series and turn it into a Web service using mere clicks of a button. Did you notice that you didn’t have to write a single line of code? In my opinion, IBM Data Web Services is truly unique in its capability and ease of use when trying to pursue a service-oriented architecture development paradigm.

I only showed you the most basic way to test a single (SOAP) invocation of your newly created Web service. In the next parts of this series, I’m going to take you through the different test clients provided by IBM Data Studio for you to test your Web services, and explain how to test a RESTful invocation of your Web service directly using a Web browser.

» See All Articles by Columnist Paul C. Zikopoulos

Trademarks

IBM, DataPower, DB2, DB2 Universal Database, i5/OS, Informix, WebSphere, and z/OS are trademarks or registered trademarks of International Business Machines Corporation in the United States, other countries, or both.

Java and all Java-based trademarks are trademarks of Sun Microsystems, Inc. in the United States, other countries, or both.

Linux is a registered trademark of Linus Torvalds in the United States, other countries, or both.

Microsoft is a trademark of Microsoft Corporation in the United States, other countries, or both.

UNIX is a registered trademark of The Open Group in the United States and other countries.

Other company, product, or service names may be trademarks or service marks of others.

Copyright International Business Machines Corporation, 2008.

Disclaimers

The opinions, solutions, and advice in this article are from the author’s experiences and are not intended to represent official communication from IBM or an endorsement of any products listed within. Neither the author nor IBM is liable for any of the contents in this article. The accuracy of the information in this article is based on the author’s knowledge at the time of writing.



Go to page: Prev  1  2  3  4  

Tools:
Add databasejournal.com to your favorites
Add databasejournal.com to your browser search box
IE 7 | Firefox 2.0 | Firefox 1.5.x
Receive news via our XML/RSS feed

DB2 Archives








Latest Forum Threads
DB2 Forum
Topic By Replies Updated
Not Use Access File In another Computer Engr. Clement 0 March 19th, 05:29 AM
Hotel Room Reservation System Donno_db2 2 February 24th, 03:03 PM
slow udf call jerzy.burzek 0 February 23rd, 08:05 AM
permissions blazer789 0 January 15th, 09:53 AM









The Network for Technology Professionals

Search:

About Internet.com

Legal Notices, Licensing, Permissions, Privacy Policy.
Advertise | Newsletters | E-mail Offers