瞧一瞧迷一般的SQLDA
You can use the DESCRIBE statement to obtain host variable information for any SELECT statement that has been prepared (using PREPARE), and store that information into the SQL descriptor area (SQLDA).
When the DESCRIBE statement gets executed in your application, the database manager defines your host variables in an SQLDA. Once the host variables are defined in the SQLDA, you can use the FETCH statement to assign values to the host variables, using a cursor.
- Declaring the SQLDA structure in a dynamically executed SQL program
An SQLDA contains a
variable number of occurrences of SQLVAR entries, each of which contains
a set of fields that describe one column in a row of data. There are
two types of SQLVAR entries: base SQLVAR entries and secondary SQLVAR
entries. - Preparing a dynamically executed SQL statement using the minimum SQLDA structure
Use the information provided here as an example of how
to allocate the minimum SQLDA structure for a statement. - Allocating an SQLDA structure with sufficient SQLVAR entries for dynamically executed SQL statements
After you determine
the number of columns in the result table, you must allocate storage
for a second full-size SQLDA. The first SQLDA is used for input parameters
and the second full-size SQLDA is used for output parameters. - Describing a SELECT statement in a dynamically executed SQL program
After you allocate sufficient space for the second SQLDA
(in this example, calledfulsqlda), you must code
the application to describe the SELECT statement. - Acquiring storage to hold a row
Before the application can fetch a row of the result table
using an SQLDA structure, the application must first allocate storage
for the row. - Processing the cursor in a dynamically executed SQL program
After you allocate the
SQLDA structure, you can open the cursor associated with the SELECT
statement and fetch rows. - Allocating an SQLDA structure for a dynamically executed SQL program
Allocate an SQLDA structure for your application so that
you can use it to pass data to and from your application. - Transferring data in a dynamically executed SQL program using an SQLDA structure
You have greater flexibility
when you transfer data using an SQLDA instead of using lists of host
variables. For example, you can use an SQLDA to transfer data that
has no native host language equivalent, such as DECIMAL data in the
C language. - Processing interactive SQL statements in dynamically executed SQL programs
You can write an application
using dynamic SQL to process arbitrary SQL statements. For example,
if an application accepts SQL statements from a user, the application
must be able to issue the statements without any prior knowledge of
the statements. - Determination of statement type in dynamically executed SQL programs
When an SQL statement
is prepared, you can determine information concerning the type of
statement by examining the SQLDA structure. This information is placed
in the SQLDA structure either at statement preparation time with the
INTO clause, or by issuing a DESCRIBE statement against a previously
prepared statement. - Processing variable-list SELECT statements in dynamically executed SQL programs
A varying-list SELECT
statement is one in which the number and types of columns that are
to be returned are not known at precompilation time. - Saving SQL requests from end users
If the users of your application can issue SQL requests
from the application, you might want to save these requests.
瞧一瞧迷一般的SQLDA的更多相关文章
- 瞧一瞧,看一看呐,用MVC+EF快速弄出一个CRUD,一行代码都不用写,真的一行代码都不用写!!!!
瞧一瞧,看一看呐用MVC+EF快速弄出一个CRUD,一行代码都不用写,真的一行代码都不用写!!!! 现在要写的呢就是,用MVC和EF弄出一个CRUD四个页面和一个列表页面的一个快速DEMO,当然是在不 ...
- 【转载】网易极客战记官方攻略-地牢- 迷一般的 Kithmaze
关卡连接: https://codecombat.163.com/play/level/riddling-kithmaze 如果你第一次走上歧途,改变你的循环来找到出路. 简介: 敬请期待! 默认代码 ...
- 瞧一瞧!这儿实现了MongoDB的增量备份与还原(含部署代码)
一 需求描述 我们知道数据是公司的重要资产,业务的系统化.信息化就是数字化.数据高效的存储与查询是系统完善和优化的方向,而数据库的稳定性.可靠性是实现的基础.高可用和RPO(RecoveryPoint ...
- Win10一周年纪念版,瞧一瞧Linux子系统
Bash Bash是一个命令处理器,通常运行于文本窗口中,并能执行用户直接输入的命令.Bash还能从文件中读取命令,这样的文件称为脚本.和其他Unix shell 一样,它支持文件名替换(通配符匹配) ...
- 走进 AQS 瞧一瞧看一看
并发中有一块很重要的东西就是AQS.接下来一周的目标就是它. 看复杂源码时,一眼望过去,这是什么?不要慌,像剥洋葱一样,一层层剥开(哥,喜欢"扒开"这个词). 参考资源: http ...
- 2020最新的web前端体系和路线图,想学web前端又不知道从哪开始的快来瞧一瞧呀
web前端其实是相对于服务器语言是简单的,并且对于初学者是非常友好的,因为在前期学习能够看到很好的效果.但是他的路线 也就是学习体系不成熟,所以导致很多初学者不知道怎么学?下面我就讲讲web前端的体系 ...
- 瞧一瞧React Fiber
啥是React Fiber? React Fiber,简单来说就是一个从React v16开始引入的新协调引擎,用来实现Virtual DOM的增量渲染. 说人话:就是一种能让React视图更新过程变 ...
- 手写Spring AOP,快来瞧一瞧看一看撒!
目录 AOP分析 Advice实现 定义Advice接口 定义前置.后置.环绕和异常增强接口 Pointcut实现 定义PointCut接口 定义正则表达式的实现类:RegExpressionPoin ...
- Java 反编译工具哪家强?对比分析瞧一瞧
前言 Java 反编译,一听可能觉得高深莫测,其实反编译并不是什么特别高级的操作,Java 对于 Class 字节码文件的生成有着严格的要求,如果你非常熟悉 Java 虚拟机规范,了解 Class 字 ...
随机推荐
- BZOJ3277——串
0.题意:给定你n个字符串,询问每个字符串有多少子串(不包括空串)是所有n个字符串中至少k个字符串的子串(注意包括本身). 1.分析:这个题我问了吴大爷做法 首先建立后缀自动机,然后利用离线搞出每一个 ...
- iOS 简单音乐播放器 界面搭建
如图搭建一个音乐播放器界面,具备以下几个简单功能: 1,界面协调,整洁. 2,点击播放,控制进度条. 3.三收藏歌曲,点击收藏,心形收藏标志颜色加深. 4,左右按钮,切换歌曲图片和标题. 5,点击中间 ...
- Android界面刷新之invalidate与postInvalidate的区别
Android的invalidate与postInvalidate都是用来刷新界面的. 在UI主线程中,用invalidate():本质是调用View的onDraw()绘制. 主线程之外,用postI ...
- 多版本python共存
当不同版本python之间相互不能兼容时,可以使用virtualenv创建不同版本python的虚拟环境 当没有指定python解释器时(如下-p 即为指定的python版本),将使用默认的全局pyt ...
- 9.4---集合子集(CC150)
这题非常复杂.牛客网上对应的题目对结果要求比较苛刻,所以要调整. 整体思路是:先放进去一个,然后第二个来的时候插入到已有的,并且把自己也放进去. public static ArrayList< ...
- ndk学习5: ndk中使用c++
默认情况下ndk不支持标准C++库,异常, rtti等 在ndk文档有关于C++ support的详细介绍 一. 使用C++标准库 介绍: 默认是使用最小额度的C++运行时库, 在Applic ...
- PHP常用字符串操作函数实例总结(trim、nl2br、addcslashes、uudecode、md5等)
/*常用的字符串输出函数 * * echo() 输出字符串 * print() 输出一个或多个字符串 * die() 输出一条信息,并退出当前脚本 * printf() 输出格式化字符串 * spri ...
- JQ引用
<script type="text/javascript" src="http://files.cnblogs.com/914556495wxkj/jquery- ...
- effective c++ resources
http://www.cnblogs.com/littlethank/archive/2011/12/15/2288787.html http://www.cnblogs.com/liao-xiao- ...
- Unity3d运行时动态修改材质
void Start () { const string MainTexVariableName = "_MainTex"; var renders = gameObject.Ge ...