⭐ 欢迎来到虫虫下载站! | 📦 资源下载 📁 资源专辑 ℹ️ 关于我们
⭐ 虫虫下载站

📄 cms639.sqc

📁 一整套完整的银行卡系统源代码
💻 SQC
字号:
/**********************************************************************   源码文件名称 : cms639.SQC**   所属子系统   : CMS**   当前文件版本 : 4.0.0.0**   作者         : guoyun**   版本创建日期 : 2005/06/16**   功能描述     : 清算帐户余额查询**   修改记录     :**   修改人       修改日期     修改日期*********************************************************************/#include "code.h"#include "attrdef.h"#include "sysdef.h"#include "pubcom.h"#include "cmscode.h"#include <stdio.h>#include "cmsclsacctbalreg.h"#include "pubinq.h"EXEC SQL INCLUDE SQLCA;int cms216039( PUBCOM *pstPubcom ){	EXEC SQL BEGIN DECLARE SECTION;		char	acSelStr[CONDITION_LEN + 1];		char	acWhrStr[CONDITION_LEN + 1];		char	acBegSettleDate[DATE_LEN + 1];		char	acEndSettleDate[DATE_LEN + 1];	EXEC SQL END   DECLARE SECTION;	/*定义局部变量*/	struct  cmsclsacctbalreg stCmsClsAcctBalReg;/* 清算帐户余额登记表 */	char    acTableName[PRDCODE_LEN + 1];       /* 表名称 */	char    acFileName[FILENAME_LEN + 1];       /* 文件名称 */    int     iRtn;	int 	iCount = 0;	FILE    *fp;								/* 文件指针     */	strcpy( g_acRspMsg, "子交易: 卡片种类表查询子交易开始.." );	TRCLOG4	/* 初始化 */	memset( &stCmsClsAcctBalReg,0x00,   sizeof( struct cmsclsacctbalreg ) );	memset( acSelStr,           0x00,   sizeof( acSelStr ) );	memset( acWhrStr,           0x00,   sizeof( acWhrStr ) );	memset( acTableName,        0x00,   sizeof( acTableName ) );	memset( acFileName,         0x00,   sizeof( acFileName ) );	memset( acBegSettleDate,    0x00,   sizeof( acBegSettleDate ) );	memset( acEndSettleDate,    0x00,   sizeof( acEndSettleDate ) );	/* 取数据字典值 */	getstring( "BeginDate1",           acBegSettleDate   );	getstring( "EndDate1",             acEndSettleDate   );	sprintf( g_acTrcMsg,"BeginDate1[%s], EndDate1[%s]", acBegSettleDate, acEndSettleDate );	TRCLOG3	strcpy( acTableName, "cms639" );	sprintf(acFileName, "%s%s%s", acTableName, pstPubcom->acBrc,								  pstPubcom->acTeller);			sprintf( g_acTrcMsg,"文件名[%s]", acFileName );	TRCLOG3    if(GenSqlCmd( "216039" , acSelStr ))	{		ERRLOG		goto Exit;	}    sprintf( acWhrStr, " where 1=1");    if ( strcmp ( acBegSettleDate, INITDATE ) )    {        sprintf( acWhrStr+strlen(acWhrStr), " and settledate >= '%s'", acBegSettleDate);    }    if ( strcmp ( acEndSettleDate, INITDATE ) )    {        sprintf( acWhrStr+strlen(acWhrStr), " and settledate <= '%s'", acEndSettleDate);    }    sprintf( acWhrStr+strlen(acWhrStr), " ORDER BY settledate DESC" );	fp = (FILE *)BeginFile( pstPubcom, acFileName );	if ( fp == NULL )	{		strcpy( g_acRspMsg, "DPS902" );		pubCrtRspInfo( );		ERRLOG		goto Exit;	}	/*组织查询字典*/	if (GetInqDict( fp , "216039" ))	{		ERRLOG		goto Exit;	}    /* 准备数据 */    sprintf( g_acTrcMsg, "%s%s" ,acSelStr,acWhrStr);    TRCLOG3    if ( DBSelect( "cmsclsacctbalreg", acSelStr ,acWhrStr , fp ) )    {        ERRLOG        goto Exit;    }Exit:	EndFile( fp );	if( !strcmp( g_acRspCode, RSP_OK ) )	{		SetInqFormid(pstPubcom, "216039") ;		sprintf( g_acTrcMsg,"清算帐户余额查询正常结束");		TRCLOG4		return SUCCESS;	}	else	{		sprintf( g_acTrcMsg,"清算帐户余额查询失败");		TRCLOG4		return FAILED ;	}}

⌨️ 快捷键说明

复制代码 Ctrl + C
搜索代码 Ctrl + F
全屏模式 F11
切换主题 Ctrl + Shift + D
显示快捷键 ?
增大字号 Ctrl + =
减小字号 Ctrl + -