Re: multiple parameter sets
"Beauchemin, Bob" <[email protected]> Tue, 1 Apr 2003 00:20:05 -0800
| Newsgroups | gmane.comp.windows.devel.oledb.devel |
|---|---|
| Message-ID | <94FD4438D783D74EA86DC692E776C12702D0AA46@la-infoserver.develop.com> |
This is a multi-part message in MIME format.
------_=_NextPart_001_01C2F827.804D505D
Content-Type: text/plain;
charset="us-ascii"
Content-Transfer-Encoding: quoted-printable
Hi Maxime,
=20
Multiple parameter sets are useful to minimize database round trips for
providers that make one DBMS round trip with all of the parameters. For
example, last time I tried this, the SQL Server provider supported
multiple parameter sets but made one database roundtrip per set (no
benefit), some providers (OraOLEDB.Oracle, I believe, was one) used a
single roundtrip regardless of the number of sets benfiting from
multiple parameter sets. There's an example of an ATL class to
encapsulate multiple parameter sets at http://staff.develop.com/bobb
(called Multiparm IIRC). This should clarify how to code them in OLE DB
(by reading the ATL code), if you want a more detailed explanation,
write back.
=20
Cheers,
Bob Beauchemin
http://staff.develop.com/bobb
=20
-----Original Message-----
From: Maxime LABELLE [mailto:[email protected]]=20
Sent: Thursday, March 27, 2003 12:39 AM
To: [email protected]
Subject: [OLEDB_DEV] multiple parameter sets
=09
=09
Hi all,=20
I would like clarifications about how to handle multiple
parameter sets,=20
and why they're useful.=20
ICommand::Execute() accepts multiple parameter sets and a
corresponding accessor=20
ICommand::SetParameterInfo(), seems to only accept one set of
parameters=20
What is the relationship with these two calls?=20
Cheers.=20
Maxime.=20
You can read messages from the OLEDB_DEV archive, unsubscribe
from OLEDB_DEV, or subscribe to other DevelopMentor lists at
http://discuss.develop.com.
You can read messages from the OLEDB_DEV archive, unsubscribe from OLEDB_DEV,
or subscribe to other DevelopMentor lists at http://discuss.develop.com.
------_=_NextPart_001_01C2F827.804D505D
Content-Type: text/html;
charset="us-ascii"
Content-Transfer-Encoding: quoted-printable
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN">
<HTML><HEAD><TITLE>Message</TITLE>
<META http-equiv=3DContent-Type content=3D"text/html; =
charset=3Dus-ascii">
<META content=3D"MSHTML 6.00.2800.1141" name=3DGENERATOR></HEAD>
<BODY>
<DIV><SPAN class=3D710321008-01042003><FONT face=3DArial color=3D#0000ff =
size=3D2>Hi=20
Maxime,</FONT></SPAN></DIV>
<DIV><SPAN class=3D710321008-01042003><FONT face=3DArial color=3D#0000ff =
size=3D2></FONT></SPAN> </DIV>
<DIV><SPAN class=3D710321008-01042003><FONT face=3DArial color=3D#0000ff =
size=3D2>Multiple parameter sets are useful to minimize database round =
trips for=20
providers that make one DBMS round trip with all of the parameters. For =
example,=20
last time I tried this, the SQL Server provider supported multiple =
parameter=20
sets but made one database roundtrip per set (no benefit), some =
providers=20
(OraOLEDB.Oracle, I believe, was one) used a single roundtrip regardless =
of the=20
number of sets benfiting from multiple parameter sets. There's an =
example of an=20
ATL class to encapsulate multiple parameter sets at <A=20
href=3D"http://staff.develop.com/bobb">http://staff.develop.com/bobb</A> =
(called=20
Multiparm IIRC). This should clarify how to code them in OLE DB (by =
reading the=20
ATL code), if you want a more detailed explanation, write=20
back.</FONT></SPAN></DIV>
<DIV><SPAN class=3D710321008-01042003><FONT face=3DArial color=3D#0000ff =
size=3D2></FONT></SPAN> </DIV>
<DIV><SPAN class=3D710321008-01042003><FONT face=3DArial color=3D#0000ff =
size=3D2>Cheers,</FONT></SPAN></DIV>
<DIV><SPAN class=3D710321008-01042003><FONT face=3DArial color=3D#0000ff =
size=3D2>Bob=20
Beauchemin</FONT></SPAN></DIV>
<DIV><SPAN class=3D710321008-01042003><FONT face=3DArial color=3D#0000ff =
size=3D2><A=20
href=3D"http://staff.develop.com/bobb">http://staff.develop.com/bobb</A><=
/FONT></SPAN></DIV>
<DIV><SPAN class=3D710321008-01042003><FONT face=3DArial color=3D#0000ff =
size=3D2></FONT></SPAN> </DIV>
<BLOCKQUOTE style=3D"MARGIN-RIGHT: 0px">
<DIV></DIV>
<DIV class=3DOutlookMessageHeader lang=3Den-us dir=3Dltr =
align=3Dleft><FONT=20
face=3DTahoma size=3D2>-----Original Message-----<BR><B>From:</B> =
Maxime LABELLE=20
[mailto:[email protected]] <BR><B>Sent:</B> Thursday, March 27, 2003 =
12:39=20
AM<BR><B>To:</B> [email protected]<BR><B>Subject:</B> =
[OLEDB_DEV]=20
multiple parameter sets<BR><BR></FONT></DIV>
<P><FONT face=3DArial size=3D2>Hi all,</FONT> </P>
<P><FONT face=3DArial size=3D2>I would like clarifications about how =
to handle=20
multiple parameter sets,</FONT> <BR><FONT face=3DArial size=3D2>and =
why they're=20
useful.</FONT> </P>
<P><FONT face=3DArial size=3D2>ICommand::Execute() accepts multiple =
parameter sets=20
and a corresponding accessor</FONT> <BR><FONT face=3DArial=20
size=3D2>ICommand::SetParameterInfo(), seems to only accept one set of =
parameters</FONT> </P>
<P><FONT face=3DArial size=3D2>What is the relationship with these two =
calls?</FONT> <BR><FONT face=3DArial size=3D2>Cheers.</FONT> <BR><FONT =
face=3DArial=20
size=3D2>Maxime.</FONT> </P>You can read messages from the OLEDB_DEV =
archive,=20
unsubscribe from OLEDB_DEV, or subscribe to other DevelopMentor lists =
at=20
http://discuss.develop.com.</BLOCKQUOTE></BODY></HTML>
=00
You can read messages from the OLEDB_DEV archive, unsubscribe from OLEDB_DEV,
or subscribe to other DevelopMentor lists at http://discuss.develop.com.
------_=_NextPart_001_01C2F827.804D505D--