📄 sqlbase.html
字号:
<STRONG>SQLBase</STRONG> server in the following way:</P>
<P> <STRONG
>SA_ReadUncommitted</STRONG> = SQLILRL
('RL')<BR><STRONG> SA_ReadCommitted</STRONG> =
SQLILCS
('CS')<BR><STRONG> SA_RepeatableRead</STRONG> = SQLILRR
('RR')<BR><STRONG> SA_Serializable</STRONG> =
SQLILRO
('RO')</P>
<P>For more details see <A
href="../OnLineDoc/Connection_setIsolationLevel.html">SAConnection::setIsolationLevel</A>.</P>
<P> </P>
<H3><A
name="Working with Long or Lob(CLob, BLob) data">Working with Long or Lob(CLob,
BLob) data</A> </H3>
<P>
SQLAPI++ supports four types for working with
Long or Lob(CLob, BLob) data:</P>
<P>
<TABLE border=1 cellPadding=1 cellSpacing=1 style="WIDTH: 100%"
width=100%>
<TR bgColor=navy>
<TD><FONT color=white
style="BACKGROUND-COLOR: #000080">Name</FONT></TD>
<TD><FONT color=white
style="BACKGROUND-COLOR: #000080">C
enum constant</FONT></TD>
</TR>
<TR>
<TD>LongBinary</TD>
<TD>SA_dtLongBinary</TD>
</TR>
<TR>
<TD>LongChar</TD>
<TD>SA_dtLongChar</TD>
</TR>
<TR>
<TD>BLob (Binary Large object)</TD>
<TD>SA_dtBLob</TD>
</TR>
<TR>
<TD>CLob (Character Large object)</TD>
<TD>SA_dtCLob</TD>
</TR></TABLE></P>
<P>The table below shows how SQLAPI++ data
types correspond with servers original data types:</P>
<P><EM>SA_dtLongBinary</EM> <= > LONG VARCHAR<BR><EM>SA_dtLongChar</EM>
<=
> LONG VARCHAR<BR
><EM>SA_dtBLob</EM> = > LONG
VARCHAR<BR><EM>SA_dtCLob
</EM>=> LONG VARCHAR</EM></P>
<P>
For more details see <A href="../HowTo/blobs.html">How To - Working with Long or Lob(CLob, BLob) data</A></P>
<P> </P>
<H3><A
name="Returning output parameters">Returning output
parameters</A> </H3>
<p>If <STRONG>SQLBase</STRONG>
stored procedure returns only
one row of output parameters (the most common case), you can
get output parameters' values immediately after calling
<A href="../OnLineDoc/Command_Execute.html">SACommand::Execute</A>
using appropriate <A href="../OnLineDoc/Param.html">SAParam</A>
objects.</p>
<P>
In <STRONG>SQLBase</STRONG>
stored procedures can also return
several rows of output parameters. In this case
SQLBase
returns them as a result set and you can
fetch them row by row using <A
href="../OnLineDoc/Command_FetchNext.html">SACommand::FetchNext</A>
method after calling
<A href="../OnLineDoc/Command_Execute.html">SACommand::Execute</A>
method.</P>
<P>For more details see <A
href="../OnLineDoc/Command_Execute.html" >SACommand::Execute</A>,
<A href="../OnLineDoc/Param_Usage.html" >SAParam
object</A>, <A
href="../HowTo/return_param.html" >How To - Returning Output Parameters</A>.</P>
<P> </P>
<H3><A name="Cancelling queries">Cancelling
queries</A> </H3>
<P>Using <A href="../OnLineDoc/Command_Cancel.html" >SACommand::Cancel</A> method you
can cancel the following types of processing on a statement:</P>
<UL type=disc>
<LI>A function running asynchronously on
the statement.<BR>
<LI>A function running on the statement on
another thread. </LI></UL>
<p>SQLAPI++ calls <STRONG>sqlcan</STRONG> function to cancel a query. To get more details
see <STRONG>sqlcan</STRONG> function
description in <STRONG>SQLBase</STRONG>
documentation.</p>
<P>For more details see <A href="../OnLineDoc/Command_Cancel.html" >SACommand::Cancel</A>.</P>
<P> </P>
<H3><A
name="Connection and command options">Connection, command, parameter and field
options</A> </H3>
<P>A server specific option can relate to a
connection, command, parameter or field. We recommend you
specify each option in an appropriate object, although it is
possible to specify them in the parental object as well. In that
case the option affects all the child objects. </P>
<P>A connection related option must be specified
in a <A href="../OnLineDoc/Connection.html">SAConnection</A>
object. </P>
<P>A command related option may be specified in
either <A href="../OnLineDoc/Connection.html">SAConnection</A>
object or <A href="../OnLineDoc/Command.html">SACommand</A>
object. If it is specified
in <A href="../OnLineDoc/Connection.html">SAConnection</A>
object it affects all
the commands on that connection. </P>
<P>A parameter related option may be specified in
<A href="../OnLineDoc/Connection.html">SAConnection</A>
object, <A href="../OnLineDoc/Command.html">SACommand</A>
object or <A href="../OnLineDoc/Param.html">SAParam</A>
object. If it is specified in <A href="../OnLineDoc/Connection.html">SAConnection</A>
object it affects all
the commands and therefore all the parameters on that connection. If
it is specified in <A href="../OnLineDoc/Command.html">SACommand</A>
object it affects all the
parameters on that command. </P>
<P>A field related option may be specified in
<A href="../OnLineDoc/Connection.html">SAConnection</A>
object, <A href="../OnLineDoc/Command.html">SACommand</A>
object or <A href="../OnLineDoc/Field.html">SAField</A>
object. If it is specified in
<A href="../OnLineDoc/Connection.html">SAConnection</A>
object it affects all
the commands and therefore all the fields on that connection. If it
is specified in <A href="../OnLineDoc/Command.html">SACommand</A>
object it affects all the
fields on that command. </P>
<P>Specific options for <STRONG> SQLBase</STRONG>:</P>
<P>
<TABLE border=1 cellPadding=5 width=100%>
<TBODY>
<TR bgColor=#000094>
<TD width=17%>
<P><STRONG><FONT color=white face="">Option name / Scope</FONT>
</STRONG></P></TD>
<TD>
<P><STRONG><FONT color=white face=""> Description</FONT>
</STRONG></P></TD></TR>
<TR>
<TD>
<P align=center>
<STRONG>
SQLPPCX
</STRONG></P>
<P align=center>
Command related</P></TD>
<TD>
<P>Controls cursor-context
preservation. For more information see SQLBase documentation. <BR>
<BR><EM>Valid values</EM>:
"off" and "on".
<BR><EM>Default
value</EM>: see SQLBase documentation.</P></TD></TR>
<TR>
<TD>
<P align=center>
<STRONG>
StoredObject
</STRONG></P>
<P align=center>
Command
related </P></TD>
<TD>
<P>If you call stored command you
can set this option to "Command" value. It
allows SQLAPI++ to optimize stored command execution. <BR>
</P>
<P><EM>Valid values</EM>:
"Procedure" and "Command".
<BR>
<EM>Default value</EM>: "Procedure".</P></TD></TR>
</TBODY>
</TABLE>
</P>
<P>For more details see <A href="../OnLineDoc/Connection_setOption.html" >SAConnection::setOption</A>,
<A href="../OnLineDoc/Command_setOption.html">SACommand::setOption</A>,
<A href="../OnLineDoc/Field_setOption.html">SAField::setOption</A>,
<A href="../OnLineDoc/Param_setOption.html">SAParam::setOption</A>.
</P>
<P> </P>
<H3><A
name="Getting native SQLBase API">Getting native SQLBase
API</A> </H3>
<P>You can call client specific API functions
which are not directly supported by SQLAPI++ Library. <A
href="../OnLineDoc/Connection_NativeAPI.html">SAConnection::NativeAPI</A>
method returns a pointer to the set of native API functions
available for <STRONG>SQLBase</STRONG>
. To use the database API directly you have to downcast
this <STRONG>saAPI</STRONG> pointer to the appropriate type and use its
implementation-specific members. The following table shows what type
cast you have to make and what additional header file you have to
include to work with <STRONG>SQLBase</STRONG>
API. Note that using appropriate type casting depends
on an API version (that generally mean that you have to explicitly
check client version before casting, see <A
href="../OnLineDoc/Connection_ClientVersion.html">SAConnection::ClientVersion</A>
method). </P>
<P>
<TABLE border=1 cellPadding=5 width=100%>
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -