If this is your first visit, be sure to check out the FAQ by clicking the link above. You may have to register before you can post: click the register link above to proceed. To start viewing messages, select the forum that you want to visit from the selection below.

 
Go Back  dBforums > Database Server Software > DB2 > Call API

Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1 (permalink)  
Old 10-31-10, 21:02
deshaipet deshaipet is offline
Registered User
 
Join Date: Aug 2008
Posts: 76
Call API

Hi,

Can someone help me how to call an API. For Example I would like to run
db2CfgGet API to get the instance config params.

Thanks in advance.

Thanks,
Panditt
Reply With Quote
  #2 (permalink)  
Old 11-02-10, 05:27
sathyaram_s sathyaram_s is offline
Super Moderator
 
Join Date: Aug 2001
Location: UK
Posts: 4,534
have a look at some samples in the sqllib/samples/c directory.
You have to do a C program to use these APIs.
__________________
Visit the new-look IDUG Website , register to gain access to the excellent content.
Reply With Quote
  #3 (permalink)  
Old 11-02-10, 08:19
Marcus_A Marcus_A is online now
Registered User
 
Join Date: May 2003
Location: USA
Posts: 5,198
There is also a PDF manual called Administrative API Reference.
__________________
M. A. Feldman
IBM Certified DBA on DB2 for Linux, UNIX, and Windows
IBM Certified DBA on DB2 for z/OS and OS/390
Reply With Quote
  #4 (permalink)  
Old 11-02-10, 09:10
deshaipet deshaipet is offline
Registered User
 
Join Date: Aug 2008
Posts: 76
Thanks Sathya and Marcus.

Thanks,
Panditt
Reply With Quote
  #5 (permalink)  
Old 11-02-10, 19:49
stolze stolze is offline
Registered User
 
Join Date: Jan 2007
Location: Jena, Germany
Posts: 2,662
If you want to use the APIs from a client via SQL only, you could wrap them into a stored procedure and CALL the stored procedure.
__________________
Knut Stolze
IBM DB2 Analytics Accelerator
IBM Germany Research & Development
Reply With Quote
  #6 (permalink)  
Old 11-06-10, 13:15
deshaipet deshaipet is offline
Registered User
 
Join Date: Aug 2008
Posts: 76
Thanks Stolze. I will try it and will let you know.

Thanks,
Panditt
Reply With Quote
Reply

Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On