Overview
Features
Download
Documentation
Community
Add-Ons & Services

Poco Data library stored procedure and output parameter

A general discussion forum.

Poco Data library stored procedure and output parameter

Postby rishp » 25 Jul 2012, 15:16

Hello,
I think POCO is excellent library for C++, and I am just experimenting so that I can use for our project.
I am using source code from latest trunk as I want output parameters from stored procedures.
we are using Mysql.
My requirement is to get out(string) from session, i.e. stored procedure give output in varchar and I want to retrieve.
As this is the errormsg from stored procedure it is very important.

Really thankful to POCO library.
rishp
 
Posts: 2
Joined: 25 Jul 2012, 07:44

Re: Poco Data library stored procedure and output parameter

Postby Royce » 25 Jul 2012, 17:44

I don't think even the latest code handles varchar just yet. There is a work-around however. In SQL concatenate your varchar result with an empty string and the result will be your varchar converted into a string that Poco can handle.

e.g. instead of SELECT some_varchar_field FROM ...
do
SELECT CONCAT(some_varchar_field, '') FROM ...
Royce
 
Posts: 19
Joined: 23 Feb 2012, 18:13

Re: Poco Data library stored procedure and output parameter

Postby rishp » 01 Aug 2012, 08:32

Thanks for reply.
Actually I am interested in getting output from stored procedure and not from select query.

for e.g.
sp_Affected_Rows`(IN pi_RowCount TINYINT UNSIGNED,
INOUT po_ErrMessage VARCHAR(200));
I would like to get po_ErrMessage in out(string) function. Is it possible?
rishp
 
Posts: 2
Joined: 25 Jul 2012, 07:44

Re: Poco Data library stored procedure and output parameter

Postby alex » 01 Aug 2012, 14:16

rishp wrote:I would like to get po_ErrMessage in out(string) function. Is it possible?

Possible. Last time I worked on it, there were blocking MySQL bugs. See comments in ODBCMySQLTest.cpp
alex
 
Posts: 1101
Joined: 11 Jul 2006, 16:27
Location: United_States


Return to General Discussion

Who is online

Users browsing this forum: No registered users and 1 guest

cron