How to create DB2 user function easily by DB Query Analyzer 6.03

How to create DB2user function easily by DB Query Analyzer 6.03

Ma Genfeng

(Guangdong Unitoll Servicesincorporated, Guangzhou510300)

Abstract  The latest version of DB QueryAnalyzer is 6.03 In DB Query Analyzer 6.03, without changing any Windows OS settings or configurations, it can run on any Microsoft Windows OS directly such as Windows10, Windows 8, Windows 7, Windows Vista, Windows 2003, Windows XP, Windows2000, Windows NT, Windows ME, Windows 9X.

This essay gives a demonstration of creating DB2 user function easily by DB Query Analyzer. And also the creating process of stored procedure has no difference with that of function. What’s more, the process of creating user function is also applicable to other DBMS, in which comma is the default separator character between SQL statements.

Key words   DBQuery Analyzer

1   Brief introductionof DB Query Analzyer 

DB Query Analyzer is presented by Master Genfeng, Ma from Chinese Mainland. It has English version named ‘DBQuery Analyzer’ and Simplified Chinese version named   .

DB Query Analyzer is one of the few excellent Client Tools in the world for its’ powerful function,friendly interface, easy operation and applicability to every production of RDBMS.

It lets you query ODBC data sources, author SQL scripts and queries, return query results to a grid or free-form text or a file, retrieve ODBC driver information, execute multiple SQL scripts or stored procedures simultaneously,save the result to files with high efficiency which is as quick as tools provided by database system. What is more, from 6.01, DB Query Analyzer provides SQL Execute Schedule function to execute SQL scripts in certain time.If you select the option ‘SQL Schedule Reconnect’ in window configurations, the Schedule SQL scripts will be executed as long as the Database Server is in use,even though the Database Server had been down.

In DB Query Analyzer 6.03, without changing any Windows OS settings or configurations, it can run on any Microsoft Windows OS directly such as Windows10, Windows 8, Windows 7, Windows Vista, Windows 2003, Windows XP, Windows2000, Windows NT, Windows ME, Windows 9X.

 

Achievementof DB Query Analyzer

In the New products& Tools reviews of programmer second issue of 2007, DB Query Analyzer hadbeen strongly recommended.

Now the Simplified Chinese version of DB Query Analyzer is the top 50 database application software in the famous software website http://xiazai.zol.com.cn/download_order/sub_550.html. In most case it lies the top 10 and it has been download morethan 110,000 times.

77 technical articles about DB Query Analyzer have been published or been publishing in computerjournal, BAIDU Library, the CSDN resource or my four blog-website.

2   Preface

In this essay I will demonstrate how to create DB2 user functioneasily by DB Query Analyzer 6.03, and also the creating process of storedprocedure has no difference with that of function. What’s more, the process ofcreating user function is also applicable to other DBMS, in which comma is the separatorcharacter between SQL statements.

OS :  Windows 8.1

Database system :DB2

Client tool : DBQuery Analyzer 6.03.

3   How to downloadthe installation packages of DB Query Analyzer from ZOL

Recently,Zhongguancun Online distributed the ZOL Downer for users to download theresources from ZOL. In this case, users can just download the ZOL downer withthe code of resources, not the installation packages.

But if someonewant to install the PC which is isolated from the INTERNET, he or she will nolonger do that.

So how do theusers download the installation packages? Please see the eassy bellow

How to downloadthe installation package by ZOL Downer

http://blog.csdn.net/magenfeng/article/details/38750901

4   Log in DB2database

Figure 1   Log in ODBC DSN UNIT2_1

5 Create DB2 user function

Figure 2   Input SQL statment tocreate DB2 user function

Figure 3  Execute SQL statments above,errors occur

 
 

Figure 4   Alter the seperatorcharacter from comma to $$

 
 

Only in the newwindow can the setting take effect, so create a new window firstly, then youcan see the separator character is set to $$ in the right bottom of status barin Figure 5.

Figure 5   Open a new window to create userfunction

 

Figure 6   Paste SQL statement from window Untitled-1

Figure 7 Execute SQL statement

Figure 8   Execute function created using sample data for testing

Figure 9  This SQL statement is a sample I used in areal complex work

Figure 10   Result return from DB2 DBMS

 

6     77 technical articles about DB Query Analyzerhave been published or been publishing in computer journal,  Baidu Library, the CSDN resource or my fourblog-website.

The following 6 articles have been publishedin computer journal.

DBQuery Analyzer to cancel a running SQL statement in Computer Era 12th issue of 2011 in Hangzhou.

DBQuery Analyzer Returns Information in More Detail While Batch SQL Statement Endof Execution in Computer Programming Skill & Maintenance 24th issue of 2011 in Beijing

TheApplication of the Transactions Control in DB2 with DB Query Analyzer in ComputerProgramming Skill & Maintenance 22nd issue of 2011 in Beijing.

Howdoes DB Query Analyzer cancel the SQL statement committed to DBMS in ComputerEngineering & Software 6th issue of 2011 in Tianjin.

TheApplication of the Transactions Control in Oracle with DB Query Analyzer inMicrocomputer Applications11th issue of 2011 in Shanghai.

    DB Query Analyzer had been stronglyrecommended In the New products & Tools reviews of programmer 2nd issue of2007.

The following 71 articles have been publishedor been publishing in Baidu Library, the CSDN resource or my four blog-website.

TheDBMS that DB Query Analyzer Users often use cover all kinds of DBMS have beenpublished.

Howto configure ODBC DSN in Client to access remote DB2 for Windows

Howto configure ODBC DSN to access local DB2 for Windows

WhichSQL statement is the trump card to the senior software developer

Exepacker prevent DB Query Analyzer from beging debugged have been published.

16articles from The 1st tip of DB Query Analyze to The 16th skills of DB QueryAnalyzer have been published.

Thetable name must be enclosed in double quotation marks or sqare bracket whileaccessing EXCEL by DB Query Analyzer

Howto download the installation package by ZOL Downer

DBQuery Analyzer, the most excellent Universal database Access tools on anyMicrosoft Windows OS

Demonstrationof DB Query Analyzer 6.03 Installation and Running on Microsoft Windows 8

Howto easily create DB2 user function by DB Query Analyzer 6.03

DBQuery Analyzer 6.03 download URL:

http://xiazai.zol.com.cn/detail/43/420901.shtml

http://www.unitedpowersoft.com/UpFile/DBQueryAnalyzer_English_603.rar

DB Query Analyzer Simplified Chinese version 6.03  downloadURL:

http://xiazai.zol.com.cn/detail/27/264455.shtml

Remarks :

Pleaseuninstall the former version first, then install the latest version.

My blog are  http://blog.csdn.net/magenfeng

http://blog.sina.com.cn/magenfeng

http://user.qzone.qq.com/630414817

Interview with CSDN: http://www.csdn.net/article/2014-08-09/2821124

时间: 2024-10-12 20:26:17

How to create DB2 user function easily by DB Query Analyzer 6.03的相关文章

DB2创建function(二)

DB2创建function(一),介绍将function内容作为字段值,或做为一个where条件的情况. DB2创建function(二),介绍建立返回的内容为表集合.调用示例如下 ? 1 select * from table(GET_EFFECTIVE_USER_ID(21))--GET_EFFECTIVE_USER_ID为建立的function函数. 建立的function示例如下: ? 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20

CREATE OR REPLACE FUNCTION

CREATE OR REPLACE FUNCTION SF_Taishou_Ksai_Date(v_receiptNum IN CHAR,                                                v_his        IN CHAR)  RETURN VARCHAR2 DETERMINISTIC IS  RESULT              VARCHAR2(50);  v_result_t          VARCHAR2(50);  v_tmp_

MySQL 5.7 create VIEW or FUNCTION or PROCEDURE

1.视图 a. CREATE ALGORITHM = UNDEFINED DEFINER = `root`@`localhost` SQL SECURITY INVOKER VIEW `sakila`.`actor_info` AS SELECT `a`.`actor_id` AS `actor_id`, `a`.`first_name` AS `first_name`, `a`.`last_name` AS `last_name`, GROUP_CONCAT(DISTINCT CONCAT(`

DB2创建function(一)

? 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 CREATE FUNCTION "FAS"."GET_ALL_NAME" ( "A_ID" BIGINT )   RETURNS VARCHAR(9000)   SPECIFIC "SQL131107190046233"--SPECIFIC名称不能与其他FUNCTION的重复

Create Data Block Based On From Clause Query In Oracle Forms

Example is given below to create a data block based on From Clause query in Oracle Forms. The following are the steps: Create a data block manually and set the following properties: You can specify different query as per your need. Then create the it

An universal algorithm design of fixed length substring locating

     An universal algorithm design of fixed length substring locating Stringlocating is a very common operation not only in the SQL design but also in theclient development tools, in which functions are also supplied to realize thelocating operation,

DB 查询分析器 方便地创建DB2自定义函数

DB 查询分析器 方便地创建DB2自定义函数                           马根峰            (广东联合电子服务股份有限公司, 广州 510300) 摘要          本文详细地介绍了"万能数据库查询分析器",中文版本<DB 查询分析器>.英文版本<DB Query Analyzer>6.03 来方便地创建DB2函数.创建DB2存贮过程与此相同,大家可以参照以下步骤.另外,本示例还适用于SQL语句要以逗号来分隔的数据库系统

十三年磨一剑,万能数据库查询分析器7.023版本 发布

中国本土程序员马根峰(CSDN专访马根峰:海量数据处理与分析大师的中国本土程序员)推出的个人作品----万能数据库查询分析器,中文版本<DB 查询分析器>.英文版本<DB Query Analyzer>.它具有强大的功能.友好的操作界面.良好的操作性.跨越各种数据库平台乃至于EXCEL和文本文件. DB 查询分析器在中关村在线 下载量超过12万 次,位居整个数据库类排行榜中前10位. 在<程序员>2007第2期的"新产品&工具点评"部分,编辑

如何使用《DB 查询分析器》高效地生成旬报货运量数据

如何使用<DB 查询分析器>高效地生成旬报货运量数据 马根峰                    (广东联合电子服务股份有限公司, 广州 510300) 1      引言   中国本土程序员马根峰(CSDN专访马根峰:海量数据处理与分析大师的中国本土程序员)推出的个人作品----万能数据库查询分析器,中文版本<DB 查询分析器>.英文版本<DB Query Analyzer>.它具有强大的功能.友好的操作界面.良好的操作性.跨越各种数据库平台乃至于EXCEL和文本文