MS DataShape and Stored Procedures

View: New views
2 Messages — Rating Filter:   Alert me  

MS DataShape and Stored Procedures

by Daniele Barzotti :: Rate this Message:

Reply to Author | View Threaded | Show Only this Message

Hi,

I don't know if this is a mistake with the ODBC Driver, but I try...
I'm working with FB v2.0.3 and ODBC v2.00.00.144 and ADO with VB6.

I have to open a hierarchical recordset with MSDATASHAPE provider:

PERSON
   |- RADIO
        |- RADIO DETAILS

The query is:

SHAPE {{ CALL SP_PERSONALE( ?) }} AS PERSONALE
APPEND ({SELECT * FROM "VIEW_RTX_DETAILS"}
RELATE PERS_IDRADIO TO IDRADIO) AS RADIO_PERS

where "VIEW_RTX_DETAILS" is a VIEW and SP_PERSONALE is a stored
procedure that returns a people list if I pass 0 to it.

When I execute this command, I receive:

Err.Number      = -2147217904
Err.Description = No values specified for some parameters needed.
Err.Source = Microsoft OLE DB Provider for ODBC Drivers

Can anyone give me some suggestions?
Thanks in advance!

Regards,
Daniele.

-------------------------------------------------------------------------
This SF.net email is sponsored by: Microsoft
Defy all challenges. Microsoft(R) Visual Studio 2008.
http://clk.atdmt.com/MRT/go/vse0120000070mrt/direct/01/
_______________________________________________
Firebird-odbc-devel mailing list
Firebird-odbc-devel@...
https://lists.sourceforge.net/lists/listinfo/firebird-odbc-devel

Re: MS DataShape and Stored Procedures

by Paul Reeves-2 :: Rate this Message:

Reply to Author | View Threaded | Show Only this Message

On Monday 25 February 2008, Daniele Barzotti wrote:

>
> The query is:
>
> SHAPE {{ CALL SP_PERSONALE( ?) }} AS PERSONALE
> APPEND ({SELECT * FROM "VIEW_RTX_DETAILS"}
> RELATE PERS_IDRADIO TO IDRADIO) AS RADIO_PERS
>
> where "VIEW_RTX_DETAILS" is a VIEW and SP_PERSONALE is a stored
> procedure that returns a people list if I pass 0 to it.
>
> When I execute this command, I receive:
>
> Err.Number      = -2147217904
> Err.Description = No values specified for some parameters needed.
> Err.Source = Microsoft OLE DB Provider for ODBC Drivers
>
> Can anyone give me some suggestions?

I am not familiar with MSDATASHAPE but it looks like you are either doing a
union on two data sets and restricting the result set to those rows from each
set that share matching RADIO_PERS values, or you are just doing a standard
inner join of the two data sets on the RADIO_PERS  values.

Either way, this is not a valid Firebird SQL statement, so if it is to work it
would require a lot of massage from the MSDATASHAPE provider (which, I guess,
is part of its job description.)

I would recommend you try to re-write the SQL to be valid for Firebird.

If you have time on your hands you could try tracing through the provider into
the driver to see where the error is being thrown. If it is a driver error it
is fixable (in theory, at least.)


Paul
--
Paul Reeves
http://www.ibphoenix.com
Supporting users of Firebird and InterBase

-------------------------------------------------------------------------
This SF.net email is sponsored by: Microsoft
Defy all challenges. Microsoft(R) Visual Studio 2008.
http://clk.atdmt.com/MRT/go/vse0120000070mrt/direct/01/
_______________________________________________
Firebird-odbc-devel mailing list
Firebird-odbc-devel@...
https://lists.sourceforge.net/lists/listinfo/firebird-odbc-devel
LightInTheBox - Buy quality products at wholesale price!