Re: AW: [OLEDB_DEV] OLE DB Consumer Templates
Erik Valdes <[email protected]> Mon, 13 Jan 2003 12:11:53 -0700
| Newsgroups | gmane.comp.windows.devel.oledb.devel |
|---|---|
| Message-ID | <[email protected]> |
This message is in MIME format. Since your mail reader does not understand
this format, some or all of this message may not be legible.
------_=_NextPart_001_01C2BB37.A1FE2CE0
Content-Type: text/plain;
charset="iso-8859-1"
Content-Transfer-Encoding: quoted-printable
Hi Rudi,
=20
Could you send me an example? I've tried to do this and keep running =
into
an error with my buffer.
=20
Thanks,
Erik
=20
-----Original Message-----
From: Rudolf Wiener [mailto:[email protected]]=20
Sent: Thursday, January 09, 2003 9:31 AM
To: [email protected]
Subject: [OLEDB_DEV] AW: [OLEDB_DEV] OLE DB Consumer Templates
=20
Erik,
=20
For reading and writing blobs, which is what you're in fact using, I =
use the
technologies recommended and stream the data with a storage object. The
macro I use in the accessor is BLOB_ENTRY_LENGTH_STATUS. I'm not sure =
if
this is the best way to do it because I have the impression it slows =
things
down a bit. But I haven't had the time yet to look into faster =
alternatives.
=20
If you like I can send you excerpts from my app's code.
=20
Regards
Rudi
=20
-----Urspr=FCngliche Nachricht-----
Von: OLEDB_DEV [mailto:[email protected]]Im Auftrag von =
Erik
Valdes
Gesendet: Donnerstag, 09. J=E4nner 2003 17:22
An: [email protected]
Betreff: Re: [OLEDB_DEV] OLE DB Consumer Templates
The reason I can't allocate on the stack is that my variable can be any
length. It essentially boils down to the string representation of an =
xml
file. That file can be any size. When I pass it to my SP, the sp's
parameter is ntext (to allow for any size). What do people do when =
they
want to pass XML of unknown length to a SQL Server stored procedure?
=20
-----Original Message-----
From: Peter Moss [mailto:[email protected]]=20
Sent: Thursday, January 09, 2003 7:58 AM
To: [email protected]
Subject: Re: [OLEDB_DEV] OLE DB Consumer Templates
=20
If I remember right, you can't use the macros for heap-allocated =
variables.
If you dig into the macro definitions, I believe you will find that =
pointers
offset from the beginning of 'this' are used. Thus, a heap-allocated
variable like m_WorkRequest will not work.
=20
Why can't you just allocate a TCHAR on the stack frame of the object, =
ie,
=20
TCHAR m_WorkRequest[257]; // Or 1 + the size of your SP parameter =
size
=20
Then you can just use COLUMN_ENTRY.
=20
HTH,
Peter
-----Original Message-----
From: OLEDB_DEV [mailto:[email protected]]On Behalf Of Erik
Valdes
Sent: Wednesday, January 08, 2003 5:22 PM
To: [email protected]
Subject: [OLEDB_DEV] OLE DB Consumer Templates
I'm having trouble implementing an accessor. I'm trying to use a =
variable
(m_WorkRequest) that's dynamically allocated as the variable that's =
bound to
a parameter in my accessor (commented line below). The reason I need =
it to
be dynamic is that it is XML and can be any length. The stored proc's
parameter is of ntext type to handle the variable length. However, I =
don't
know at compile time how big to make the buffer for my parameter in my
accessor. What's the proper way to do this? I've tried COLUMN_ENTRY
(access violation), COLUMN_ENTRY_LENGTH (different variations produce
different errors, but basically I can't set the length),
COLUMN_ENTRY_TYPE_SIZE (similar problems as the previous). I'm running =
out
of ideas now. The code below is just one of many, many variations I've
tried.
=20
=20
class CAddWorkRequest
{
public:
CAddWorkRequest() STD_INIT
~CAddWorkRequest()
{=20
if (m_WorkRequest)
delete [] m_WorkRequest;
}
LONG m_RETURNVALUE;
LPTSTR m_WorkRequest;
LONG m_lLength;
=20
void SetStringParam(LPCTSTR szString,int cBytes)
{
m_WorkRequest =3D (LPTSTR) new TCHAR[cBytes];
_tcsncpy(m_WorkRequest,szString,cBytes);
m_lLength =3D _tcslen(m_WorkRequest);
})
=20
BEGIN_PARAM_MAP(CAddWorkRequest)
SET_PARAM_TYPE(DBPARAMIO_OUTPUT)
COLUMN_ENTRY(1, m_RETURNVALUE)
SET_PARAM_TYPE(DBPARAMIO_INPUT)
// COLUMN_ENTRY_TYPE_SIZE(2,DBTYPE_STR,_tcslen(m_WorkRequest),
m_WorkRequest)
=20
=20
END_PARAM_MAP()
=20
DEFINE_COMMAND(CAddWorkRequest, _T("{ ? =3D CALL dbo.AddWorkRequest;1 =
(?) }"))
=20
};
=20
class CAddWorkRequestCommand : public CBsDbCommand<CAddWorkRequest>
{
};
=20
foo (LPTSTR szWor)
{
CAddWorkRequestCommand cmd;
cmd.SetStringParam(szWor,_tcslen(szWor)+1);
cmd.Open();
}
=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.=20
You can read messages from the OLEDB_DEV archive, unsubscribe from
OLEDB_DEV, You can read messages from the OLEDB_DEV archive, =
unsubscribe
from OLEDB_DEV, or subscribe to other DevelopMentor lists at
http://discuss.develop.com. 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.
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_01C2BB37.A1FE2CE0
Content-Type: text/html;
charset="iso-8859-1"
Content-Transfer-Encoding: quoted-printable
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN">
<html>
<head>
<META HTTP-EQUIV=3D"Content-Type" CONTENT=3D"text/html; =
charset=3Diso-8859-1">
<meta name=3DGenerator content=3D"Microsoft Word 10 (filtered)">
<style>
<!--
/* Font Definitions */
@font-face
{font-family:Tahoma;
panose-1:2 11 6 4 3 5 4 4 2 4;}
/* Style Definitions */
p.MsoNormal, li.MsoNormal, div.MsoNormal
{margin:0in;
margin-bottom:.0001pt;
font-size:12.0pt;
font-family:"Times New Roman";}
a:link, span.MsoHyperlink
{color:blue;
text-decoration:underline;}
a:visited, span.MsoHyperlinkFollowed
{color:purple;
text-decoration:underline;}
span.emailstyle17
{font-family:Arial;
color:windowtext;}
span.emailstyle18
{font-family:Arial;
color:navy;}
span.EmailStyle19
{font-family:Arial;
color:navy;}
@page Section1
{size:8.5in 11.0in;
margin:1.0in 1.25in 1.0in 1.25in;}
div.Section1
{page:Section1;}
-->
</style>
</head>
<body lang=3DEN-US link=3Dblue vlink=3Dpurple>
<div class=3DSection1>
<p class=3DMsoNormal><font size=3D2 color=3Dnavy face=3DArial><span =
style=3D'font-size:
10.0pt;font-family:Arial;color:navy'>Hi Rudi,</span></font></p>
<p class=3DMsoNormal><font size=3D2 color=3Dnavy face=3DArial><span =
style=3D'font-size:
10.0pt;font-family:Arial;color:navy'> </span></font></p>
<p class=3DMsoNormal><font size=3D2 color=3Dnavy face=3DArial><span =
style=3D'font-size:
10.0pt;font-family:Arial;color:navy'>Could you send me an example?=A0 =
I've
tried to do this and keep running into an error with my =
buffer.</span></font></p>
<p class=3DMsoNormal><font size=3D2 color=3Dnavy face=3DArial><span =
style=3D'font-size:
10.0pt;font-family:Arial;color:navy'> </span></font></p>
<p class=3DMsoNormal><font size=3D2 color=3Dnavy face=3DArial><span =
style=3D'font-size:
10.0pt;font-family:Arial;color:navy'>Thanks,</span></font></p>
<p class=3DMsoNormal><font size=3D2 color=3Dnavy face=3DArial><span =
style=3D'font-size:
10.0pt;font-family:Arial;color:navy'>Erik</span></font></p>
<p class=3DMsoNormal><font size=3D2 color=3Dnavy face=3DArial><span =
style=3D'font-size:
10.0pt;font-family:Arial;color:navy'> </span></font></p>
<p class=3DMsoNormal style=3D'margin-left:.5in'><font size=3D2 =
face=3DTahoma><span
style=3D'font-size:10.0pt;font-family:Tahoma'>-----Original =
Message-----<br>
<b><span style=3D'font-weight:bold'>From:</span></b> Rudolf Wiener
[mailto:[email protected]] <br>
<b><span style=3D'font-weight:bold'>Sent:</span></b> Thursday, January =
09, 2003
9:31 AM<br>
<b><span style=3D'font-weight:bold'>To:</span></b> =
[email protected]<br>
<b><span style=3D'font-weight:bold'>Subject:</span></b> [OLEDB_DEV] AW:
[OLEDB_DEV] OLE DB Consumer Templates</span></font></p>
<p class=3DMsoNormal style=3D'margin-left:.5in'><font size=3D3 =
face=3D"Times New Roman"><span
style=3D'font-size:12.0pt'> </span></font></p>
<div>
<p class=3DMsoNormal style=3D'margin-left:.5in'><font size=3D2 =
color=3Dblue face=3DArial><span
style=3D'font-size:10.0pt;font-family:Arial;color:blue'>Erik,</span></fo=
nt></p>
</div>
<div>
<p class=3DMsoNormal style=3D'margin-left:.5in'><font size=3D3 =
face=3D"Times New Roman"><span
style=3D'font-size:12.0pt'> </span></font></p>
</div>
<div>
<p class=3DMsoNormal style=3D'margin-left:.5in'><font size=3D2 =
color=3Dblue face=3DArial><span
style=3D'font-size:10.0pt;font-family:Arial;color:blue'>For reading and =
writing
blobs, which is what you're in fact using, I use the technologies =
recommended
and stream the data with a storage object. The macro I use in the =
accessor is
BLOB_ENTRY_LENGTH_STATUS. I'm not sure if this is the best way to do it =
because
I have the impression it slows things down a bit. But I haven't had the =
time
yet to look into faster alternatives.</span></font></p>
</div>
<div>
<p class=3DMsoNormal style=3D'margin-left:.5in'><font size=3D3 =
face=3D"Times New Roman"><span
style=3D'font-size:12.0pt'> </span></font></p>
</div>
<div>
<p class=3DMsoNormal style=3D'margin-left:.5in'><font size=3D2 =
color=3Dblue face=3DArial><span
style=3D'font-size:10.0pt;font-family:Arial;color:blue'>If you like I =
can send
you excerpts from my app's code.</span></font></p>
</div>
<div>
<p class=3DMsoNormal style=3D'margin-left:.5in'><font size=3D3 =
face=3D"Times New Roman"><span
style=3D'font-size:12.0pt'> </span></font></p>
</div>
<div>
<p class=3DMsoNormal style=3D'margin-left:.5in'><font size=3D2 =
color=3Dblue face=3DArial><span
style=3D'font-size:10.0pt;font-family:Arial;color:blue'>Regards</span></=
font></p>
</div>
<div>
<p class=3DMsoNormal style=3D'margin-left:.5in'><font size=3D2 =
color=3Dblue face=3DArial><span
style=3D'font-size:10.0pt;font-family:Arial;color:blue'>Rudi</span></fon=
t></p>
</div>
<div>
<p class=3DMsoNormal style=3D'margin-left:.5in'><font size=3D3 =
face=3D"Times New Roman"><span
style=3D'font-size:12.0pt'> </span></font></p>
</div>
<blockquote style=3D'border:none;border-left:solid blue =
1.5pt;padding:0in 0in 0in 4.0pt;
margin-left:3.75pt;margin-top:5.0pt;margin-bottom:5.0pt'>
<p class=3DMsoNormal =
style=3D'margin-right:0in;margin-bottom:12.0pt;margin-left:
.5in'><font size=3D2 face=3DTahoma><span =
style=3D'font-size:10.0pt;font-family:Tahoma'>-----Urspr=FCngliche
Nachricht-----<br>
<b><span style=3D'font-weight:bold'>Von:</span></b> OLEDB_DEV
[mailto:[email protected]]<b><span =
style=3D'font-weight:bold'>Im
Auftrag von </span></b>Erik Valdes<br>
<b><span style=3D'font-weight:bold'>Gesendet:</span></b> Donnerstag, =
09. J=E4nner
2003 17:22<br>
<b><span style=3D'font-weight:bold'>An:</span></b> =
[email protected]<br>
<b><span style=3D'font-weight:bold'>Betreff:</span></b> Re: [OLEDB_DEV] =
OLE DB
Consumer Templates</span></font></p>
<p class=3DMsoNormal style=3D'margin-left:.5in'><font size=3D2 =
color=3Dnavy face=3DArial><span
style=3D'font-size:10.0pt;font-family:Arial;color:navy'>The reason I =
can't
allocate on the stack is that my variable can be any length. It
essentially boils down to the string representation of an xml file. =
That
file can be any size. When I pass it to my SP, the sp's parameter =
is
ntext (to allow for any size). What do people do when they =
want to
pass XML of unknown length to a SQL Server stored =
procedure?</span></font></p>
<p class=3DMsoNormal style=3D'margin-left:.5in'><font size=3D3 =
face=3D"Times New Roman"><span
style=3D'font-size:12.0pt'> </span></font></p>
<p class=3DMsoNormal style=3D'margin-left:1.0in'><font size=3D2 =
face=3DTahoma><span
style=3D'font-size:10.0pt;font-family:Tahoma'>-----Original =
Message-----<br>
<b><span style=3D'font-weight:bold'>From:</span></b> Peter Moss
[mailto:[email protected]] <br>
<b><span style=3D'font-weight:bold'>Sent:</span></b> Thursday, January =
09, 2003
7:58 AM<br>
<b><span style=3D'font-weight:bold'>To:</span></b> =
[email protected]<br>
<b><span style=3D'font-weight:bold'>Subject:</span></b> Re: [OLEDB_DEV] =
OLE DB
Consumer Templates</span></font></p>
<p class=3DMsoNormal style=3D'margin-left:1.0in'><font size=3D3 =
face=3D"Times New Roman"><span
style=3D'font-size:12.0pt'> </span></font></p>
<div>
<p class=3DMsoNormal style=3D'margin-left:1.0in'><font size=3D2 =
color=3Dblue
face=3DArial><span =
style=3D'font-size:10.0pt;font-family:Arial;color:blue'>If I
remember right, you can't use the macros for heap-allocated =
variables. If
you dig into the macro definitions, I believe you will find that =
pointers
offset from the beginning of 'this' are used. Thus, a =
heap-allocated
variable like m_WorkRequest will not work.</span></font></p>
</div>
<div>
<p class=3DMsoNormal style=3D'margin-left:1.0in'><font size=3D3 =
face=3D"Times New Roman"><span
style=3D'font-size:12.0pt'> </span></font></p>
</div>
<div>
<p class=3DMsoNormal style=3D'margin-left:1.0in'><font size=3D2 =
color=3Dblue
face=3DArial><span =
style=3D'font-size:10.0pt;font-family:Arial;color:blue'>Why
can't you just allocate a TCHAR on the stack frame of the object, =
ie,</span></font></p>
</div>
<div>
<p class=3DMsoNormal style=3D'margin-left:1.0in'><font size=3D3 =
face=3D"Times New Roman"><span
style=3D'font-size:12.0pt'> </span></font></p>
</div>
<div>
<p class=3DMsoNormal style=3D'margin-left:1.0in'><font size=3D2 =
color=3Dblue
face=3DArial><span =
style=3D'font-size:10.0pt;font-family:Arial;color:blue'>TCHAR
m_WorkRequest[257]; // Or 1 + the size of your =
SP
parameter size</span></font></p>
</div>
<div>
<p class=3DMsoNormal style=3D'margin-left:1.0in'><font size=3D3 =
face=3D"Times New Roman"><span
style=3D'font-size:12.0pt'> </span></font></p>
</div>
<div>
<p class=3DMsoNormal style=3D'margin-left:1.0in'><font size=3D2 =
color=3Dblue
face=3DArial><span =
style=3D'font-size:10.0pt;font-family:Arial;color:blue'>Then you
can just use COLUMN_ENTRY.</span></font></p>
</div>
<div>
<p class=3DMsoNormal style=3D'margin-left:1.0in'><font size=3D3 =
face=3D"Times New Roman"><span
style=3D'font-size:12.0pt'> </span></font></p>
</div>
<div>
<p class=3DMsoNormal style=3D'margin-left:1.0in'><font size=3D2 =
color=3Dblue
face=3DArial><span =
style=3D'font-size:10.0pt;font-family:Arial;color:blue'>HTH,</span></fon=
t></p>
</div>
<div>
<p class=3DMsoNormal style=3D'margin-left:1.0in'><font size=3D2 =
color=3Dblue
face=3DArial><span =
style=3D'font-size:10.0pt;font-family:Arial;color:blue'>Peter</span></fo=
nt></p>
</div>
<blockquote style=3D'margin-top:5.0pt;margin-bottom:5.0pt'>
<p class=3DMsoNormal =
style=3D'margin-right:0in;margin-bottom:12.0pt;margin-left:
1.0in'><font size=3D2 face=3DTahoma><span =
style=3D'font-size:10.0pt;font-family:Tahoma'>-----Original
Message-----<br>
<b><span style=3D'font-weight:bold'>From:</span></b> OLEDB_DEV
[mailto:[email protected]]<b><span =
style=3D'font-weight:bold'>On
Behalf Of </span></b>Erik Valdes<br>
<b><span style=3D'font-weight:bold'>Sent:</span></b> Wednesday, January =
08, 2003
5:22 PM<br>
<b><span style=3D'font-weight:bold'>To:</span></b> =
[email protected]<br>
<b><span style=3D'font-weight:bold'>Subject:</span></b> [OLEDB_DEV] OLE =
DB
Consumer Templates</span></font></p>
<p class=3DMsoNormal style=3D'margin-left:1.0in'><font size=3D2 =
face=3DArial><span
style=3D'font-size:10.0pt;font-family:Arial'>I'm having trouble =
implementing an
accessor. I'm trying to use a variable (m_WorkRequest) that's =
dynamically
allocated as the variable that's bound to a parameter in my accessor =
(commented
line below). The reason I need it to be dynamic is that it =
is XML
and can be any length. The stored proc's parameter is of ntext =
type to
handle the variable length. However, I don't know at compile time =
how big
to make the buffer for my parameter in my accessor. What's the =
proper way
to do this? I've tried COLUMN_ENTRY (access violation),
COLUMN_ENTRY_LENGTH (different variations produce different errors, but
basically I can't set the length), COLUMN_ENTRY_TYPE_SIZE (similar =
problems as
the previous). I'm running out of ideas now. The code below =
is just
one of many, many variations I've tried.</span></font></p>
<p class=3DMsoNormal style=3D'margin-left:1.0in'><font size=3D3 =
face=3D"Times New Roman"><span
style=3D'font-size:12.0pt'> </span></font></p>
<p class=3DMsoNormal style=3D'margin-left:1.0in'><font size=3D3 =
face=3D"Times New Roman"><span
style=3D'font-size:12.0pt'> </span></font></p>
<p class=3DMsoNormal style=3D'margin-left:1.0in'><font size=3D2 =
face=3DArial><span
style=3D'font-size:10.0pt;font-family:Arial'>class =
CAddWorkRequest</span></font></p>
<p class=3DMsoNormal style=3D'margin-left:1.0in'><font size=3D2 =
face=3DArial><span
style=3D'font-size:10.0pt;font-family:Arial'>{</span></font></p>
<p class=3DMsoNormal style=3D'margin-left:1.0in'><font size=3D2 =
face=3DArial><span
style=3D'font-size:10.0pt;font-family:Arial'>public:</span></font></p>
<p class=3DMsoNormal style=3D'margin-left:1.0in'><font size=3D2 =
face=3DArial><span
style=3D'font-size:10.0pt;font-family:Arial'> =
CAddWorkRequest()
STD_INIT</span></font></p>
<p class=3DMsoNormal style=3D'margin-left:1.0in'><font size=3D2 =
face=3DArial><span
style=3D'font-size:10.0pt;font-family:Arial'> =
~CAddWorkRequest()</span></font></p>
<p class=3DMsoNormal style=3D'margin-left:1.0in'><font size=3D2 =
face=3DArial><span
style=3D'font-size:10.0pt;font-family:Arial'> { =
</span></font></p>
<p class=3DMsoNormal style=3D'margin-left:1.0in'><font size=3D2 =
face=3DArial><span
style=3D'font-size:10.0pt;font-family:Arial'> &nb=
sp; if
(m_WorkRequest)</span></font></p>
<p class=3DMsoNormal style=3D'margin-left:1.0in'><font size=3D2 =
face=3DArial><span
style=3D'font-size:10.0pt;font-family:Arial'> &nb=
sp;
delete [] m_WorkRequest;</span></font></p>
<p class=3DMsoNormal style=3D'margin-left:1.0in'><font size=3D2 =
face=3DArial><span
style=3D'font-size:10.0pt;font-family:Arial'> =
}</span></font></p>
<p class=3DMsoNormal style=3D'margin-left:1.0in'><font size=3D2 =
face=3DArial><span
style=3D'font-size:10.0pt;font-family:Arial'> LONG =
m_RETURNVALUE;</span></font></p>
<p class=3DMsoNormal style=3D'margin-left:1.0in'><font size=3D2 =
face=3DArial><span
style=3D'font-size:10.0pt;font-family:Arial'> LPTSTR =
m_WorkRequest;</span></font></p>
<p class=3DMsoNormal style=3D'margin-left:1.0in'><font size=3D2 =
face=3DArial><span
style=3D'font-size:10.0pt;font-family:Arial'> LONG =
m_lLength;</span></font></p>
<p class=3DMsoNormal style=3D'margin-left:1.0in'><font size=3D3 =
face=3D"Times New Roman"><span
style=3D'font-size:12.0pt'> </span></font></p>
<p class=3DMsoNormal style=3D'margin-left:1.0in'><font size=3D2 =
face=3DArial><span
style=3D'font-size:10.0pt;font-family:Arial'> void
SetStringParam(LPCTSTR szString,int cBytes)</span></font></p>
<p class=3DMsoNormal style=3D'margin-left:1.0in'><font size=3D2 =
face=3DArial><span
style=3D'font-size:10.0pt;font-family:Arial'> =
{</span></font></p>
<p class=3DMsoNormal style=3D'margin-left:1.0in'><font size=3D2 =
face=3DArial><span
style=3D'font-size:10.0pt;font-family:Arial'> &nb=
sp;
m_WorkRequest =3D (LPTSTR) new TCHAR[cBytes];</span></font></p>
<p class=3DMsoNormal style=3D'margin-left:1.0in'><font size=3D2 =
face=3DArial><span
style=3D'font-size:10.0pt;font-family:Arial'> &nb=
sp;
_tcsncpy(m_WorkRequest,szString,cBytes);</span></font></p>
<p class=3DMsoNormal style=3D'margin-left:1.0in'><font size=3D2 =
face=3DArial><span
style=3D'font-size:10.0pt;font-family:Arial'> &nb=
sp;
m_lLength =3D _tcslen(m_WorkRequest);</span></font></p>
<p class=3DMsoNormal style=3D'margin-left:1.0in'><font size=3D2 =
face=3DArial><span
style=3D'font-size:10.0pt;font-family:Arial'> =
})</span></font></p>
<p class=3DMsoNormal style=3D'margin-left:1.0in'><font size=3D3 =
face=3D"Times New Roman"><span
style=3D'font-size:12.0pt'> </span></font></p>
<p class=3DMsoNormal style=3D'margin-left:1.0in'><font size=3D2 =
face=3DArial><span
style=3D'font-size:10.0pt;font-family:Arial'>BEGIN_PARAM_MAP(CAddWorkReq=
uest)</span></font></p>
<p class=3DMsoNormal style=3D'margin-left:1.0in'><font size=3D2 =
face=3DArial><span
style=3D'font-size:10.0pt;font-family:Arial'>
SET_PARAM_TYPE(DBPARAMIO_OUTPUT)</span></font></p>
<p class=3DMsoNormal style=3D'margin-left:1.0in'><font size=3D2 =
face=3DArial><span
style=3D'font-size:10.0pt;font-family:Arial'> =
COLUMN_ENTRY(1,
m_RETURNVALUE)</span></font></p>
<p class=3DMsoNormal style=3D'margin-left:1.0in'><font size=3D2 =
face=3DArial><span
style=3D'font-size:10.0pt;font-family:Arial'> =
SET_PARAM_TYPE(DBPARAMIO_INPUT)</span></font></p>
<p class=3DMsoNormal style=3D'margin-left:1.0in'><font size=3D2 =
face=3DArial><span
style=3D'font-size:10.0pt;font-family:Arial'>//
COLUMN_ENTRY_TYPE_SIZE(2,DBTYPE_STR,_tcslen(m_WorkRequest), =
m_WorkRequest)</span></font></p>
<p class=3DMsoNormal style=3D'margin-left:1.0in'><font size=3D3 =
face=3D"Times New Roman"><span
style=3D'font-size:12.0pt'> </span></font></p>
<p class=3DMsoNormal style=3D'margin-left:1.0in'><font size=3D3 =
face=3D"Times New Roman"><span
style=3D'font-size:12.0pt'> </span></font></p>
<p class=3DMsoNormal style=3D'margin-left:1.0in'><font size=3D2 =
face=3DArial><span
style=3D'font-size:10.0pt;font-family:Arial'>END_PARAM_MAP()</span></fon=
t></p>
<p class=3DMsoNormal style=3D'margin-left:1.0in'><font size=3D3 =
face=3D"Times New Roman"><span
style=3D'font-size:12.0pt'> </span></font></p>
<p class=3DMsoNormal style=3D'margin-left:1.0in'><font size=3D2 =
face=3DArial><span
style=3D'font-size:10.0pt;font-family:Arial'>DEFINE_COMMAND(CAddWorkRequ=
est,
_T("{ ? =3D CALL dbo.AddWorkRequest;1 (?) =
}"))</span></font></p>
<p class=3DMsoNormal style=3D'margin-left:1.0in'><font size=3D3 =
face=3D"Times New Roman"><span
style=3D'font-size:12.0pt'> </span></font></p>
<p class=3DMsoNormal style=3D'margin-left:1.0in'><font size=3D2 =
face=3DArial><span
style=3D'font-size:10.0pt;font-family:Arial'>};</span></font></p>
<p class=3DMsoNormal style=3D'margin-left:1.0in'><font size=3D3 =
face=3D"Times New Roman"><span
style=3D'font-size:12.0pt'> </span></font></p>
<p class=3DMsoNormal style=3D'margin-left:1.0in'><font size=3D3 =
face=3D"Times New Roman"><span
style=3D'font-size:12.0pt'>class CAddWorkRequestCommand : public =
CBsDbCommand<CAddWorkRequest></span></font></p>
<p class=3DMsoNormal style=3D'margin-left:1.0in'><font size=3D3 =
face=3D"Times New Roman"><span
style=3D'font-size:12.0pt'>{</span></font></p>
<p class=3DMsoNormal style=3D'margin-left:1.0in'><font size=3D3 =
face=3D"Times New Roman"><span
style=3D'font-size:12.0pt'>};</span></font></p>
<p class=3DMsoNormal style=3D'margin-left:1.0in'><font size=3D3 =
face=3D"Times New Roman"><span
style=3D'font-size:12.0pt'> </span></font></p>
<p class=3DMsoNormal style=3D'margin-left:1.0in'><font size=3D3 =
face=3D"Times New Roman"><span
style=3D'font-size:12.0pt'>foo (LPTSTR szWor)</span></font></p>
<p class=3DMsoNormal style=3D'margin-left:1.0in'><font size=3D3 =
face=3D"Times New Roman"><span
style=3D'font-size:12.0pt'>{</span></font></p>
<p class=3DMsoNormal style=3D'margin-left:1.0in'><font size=3D3 =
face=3D"Times New Roman"><span
style=3D'font-size:12.0pt'> &nb=
sp;
CAddWorkRequestCommand cmd;</span></font></p>
<p class=3DMsoNormal style=3D'margin-left:1.0in'><font size=3D3 =
face=3D"Times New Roman"><span
style=3D'font-size:12.0pt'> &nb=
sp;
cmd.SetStringParam(szWor,_tcslen(szWor)+1);</span></font></p>
<p class=3DMsoNormal style=3D'margin-left:1.0in;text-indent:.5in'><font =
size=3D3
face=3D"Times New Roman"><span =
style=3D'font-size:12.0pt'>cmd.Open();</span></font></p>
<p class=3DMsoNormal style=3D'margin-left:1.0in'><font size=3D3 =
face=3D"Times New Roman"><span
style=3D'font-size:12.0pt'>}</span></font></p>
<p class=3DMsoNormal style=3D'margin-left:1.0in'><font size=3D3 =
face=3D"Times New Roman"><span
style=3D'font-size:12.0pt'> </span></font></p>
<p class=3DMsoNormal style=3D'margin-left:1.0in'><font size=3D3 =
face=3D"Times New Roman"><span
style=3D'font-size:12.0pt'>You can read messages from the OLEDB_DEV =
archive,
unsubscribe from OLEDB_DEV, or subscribe to other DevelopMentor lists =
at
http://discuss.develop.com. </span></font></p>
</blockquote>
<p class=3DMsoNormal style=3D'margin-left:.5in'><font size=3D3 =
face=3D"Times New Roman"><span
style=3D'font-size:12.0pt'>You can read messages from the OLEDB_DEV =
archive,
unsubscribe from OLEDB_DEV, You can read messages from the OLEDB_DEV =
archive,
unsubscribe from OLEDB_DEV, or subscribe to other DevelopMentor lists =
at
http://discuss.develop.com. or subscribe to other DevelopMentor lists =
at
http://discuss.develop.com.</span></font></p>
</blockquote>
</div>
</body>
</html>
You can read messages from the OLEDB_DEV archive, unsubscribe from =
OLEDB_DEV,
or subscribe to other DevelopMentor lists at =
You can read messages from the OLEDB_DEV archive, unsubscribe from OLEDB_DEV,
or subscribe to other DevelopMentor lists at http://discuss.develop.com.
http://discuss.develop.com.
------_=_NextPart_001_01C2BB37.A1FE2CE0--