📄 tbcms043.sqc
字号:
/*** 注 意: 此文件由平台自动生成,禁止任何人以任何方式修改!** 生成日期: 2004-9-1** 版 本 号: V1.0.0** 初始作者: ShiBin Hu*/#include "sysdefine.h"#include "code.h"#include "attrdef.h"#include "revglob.h"EXEC SQL INCLUDE sqlca;EXEC SQL BEGIN DECLARE SECTION ; char cmsauthfrzmap_cardno[33]; short cmsauthfrzmap_cardno_id; char cmsauthfrzmap_authno[7]; short cmsauthfrzmap_authno_id; char cmsauthfrzmap_frzno[21]; short cmsauthfrzmap_frzno_id; char cmsauthfrzmap_authenddate[11]; short cmsauthfrzmap_authenddate_id; double cmsauthfrzmap_authamt; short cmsauthfrzmap_authamt_id;EXEC SQL END DECLARE SECTION ;#define RR_CMSAUTHFRZMAP \ :cmsauthfrzmap_cardno:cmsauthfrzmap_cardno_id, \ :cmsauthfrzmap_authno:cmsauthfrzmap_authno_id, \ :cmsauthfrzmap_frzno:cmsauthfrzmap_frzno_id, \ :cmsauthfrzmap_authenddate:cmsauthfrzmap_authenddate_id, \ :cmsauthfrzmap_authamt:cmsauthfrzmap_authamt_id#define UU_CMSAUTHFRZMAP \ cardno, \ authno, \ frzno, \ authenddate, \ authamt#define WW_CMSAUTHFRZMAP \ :cmsauthfrzmap_cardno, \ :cmsauthfrzmap_authno, \ :cmsauthfrzmap_frzno, \ :cmsauthfrzmap_authenddate, \ :cmsauthfrzmap_authamtstruct cmsauthfrzmap{ char cardno[33]; char authno[7]; char frzno[21]; char authenddate[11]; double authamt;};void pubInitCmsauthfrzmap(){ memset( cmsauthfrzmap_cardno, 0x00, sizeof( cmsauthfrzmap_cardno ) ) ; cmsauthfrzmap_cardno_id = 0 ; memset( cmsauthfrzmap_authno, 0x00, sizeof( cmsauthfrzmap_authno ) ) ; cmsauthfrzmap_authno_id = 0 ; memset( cmsauthfrzmap_frzno, 0x00, sizeof( cmsauthfrzmap_frzno ) ) ; cmsauthfrzmap_frzno_id = 0 ; memset( cmsauthfrzmap_authenddate, 0x00, sizeof( cmsauthfrzmap_authenddate ) ) ; cmsauthfrzmap_authenddate_id = 0 ; memset( &cmsauthfrzmap_authamt, 0x00, sizeof( cmsauthfrzmap_authamt ) ) ; cmsauthfrzmap_authamt_id = 0 ;}void pubStoVCmsauthfrzmap( struct cmsauthfrzmap * pstCmsauthfrzmap ){ pubInitCmsauthfrzmap(); if( !strlen( pstCmsauthfrzmap->cardno ) ) strcpy( pstCmsauthfrzmap->cardno, " " ); strcpy( cmsauthfrzmap_cardno, pstCmsauthfrzmap->cardno ); if( !strlen( pstCmsauthfrzmap->authno ) ) strcpy( pstCmsauthfrzmap->authno, " " ); strcpy( cmsauthfrzmap_authno, pstCmsauthfrzmap->authno ); if( !strlen( pstCmsauthfrzmap->frzno ) ) strcpy( pstCmsauthfrzmap->frzno, " " ); strcpy( cmsauthfrzmap_frzno, pstCmsauthfrzmap->frzno ); if( !strlen( pstCmsauthfrzmap->authenddate ) ) strcpy( pstCmsauthfrzmap->authenddate, " " ); strcpy( cmsauthfrzmap_authenddate, pstCmsauthfrzmap->authenddate ); cmsauthfrzmap_authamt = pstCmsauthfrzmap->authamt ; pubDround( &cmsauthfrzmap_authamt, 2 );}void pubVtoSCmsauthfrzmap( struct cmsauthfrzmap * pstCmsauthfrzmap ){ strcpy( pstCmsauthfrzmap->cardno, cmsauthfrzmap_cardno ); strpack( pstCmsauthfrzmap->cardno ); strcpy( pstCmsauthfrzmap->authno, cmsauthfrzmap_authno ); strpack( pstCmsauthfrzmap->authno ); strcpy( pstCmsauthfrzmap->frzno, cmsauthfrzmap_frzno ); strpack( pstCmsauthfrzmap->frzno ); strcpy( pstCmsauthfrzmap->authenddate, cmsauthfrzmap_authenddate ); strpack( pstCmsauthfrzmap->authenddate ); pstCmsauthfrzmap->authamt = cmsauthfrzmap_authamt ; pubDround( &pstCmsauthfrzmap->authamt, 2 );}int pubReadCmsauthfrzmap( struct cmsauthfrzmap * pstCmsauthfrzmap ){ pubInitCmsauthfrzmap(); pubStoVCmsauthfrzmap(pstCmsauthfrzmap); EXEC SQL SELECT * INTO RR_CMSAUTHFRZMAP FROM cmsauthfrzmap WHERE cardno = :cmsauthfrzmap_cardno and authno = :cmsauthfrzmap_authno ; if ( SQLCODE ) { strcpy( g_acRspCode, "999996" ); /* 数据库读错误 */ pubCrtRspInfo( "cmsauthfrzmap",SQLCODE ); pubErrLog( __LINE__, __FILE__, g_acRspMsg ); return -1; }; pubVtoSCmsauthfrzmap(pstCmsauthfrzmap); return 0; } int pubModiCmsauthfrzmap( struct cmsauthfrzmap * pstCmsauthfrzmap ){ pubInitCmsauthfrzmap(); pubStoVCmsauthfrzmap(pstCmsauthfrzmap); EXEC SQL UPDATE cmsauthfrzmap SET ( UU_CMSAUTHFRZMAP ) = ( WW_CMSAUTHFRZMAP ) WHERE cardno = :cmsauthfrzmap_cardno and authno = :cmsauthfrzmap_authno ; if ( SQLCODE ) { strcpy( g_acRspCode, "999997" ); /* 数据库更新错误 */ pubCrtRspInfo( "cmsauthfrzmap",SQLCODE ); pubErrLog( __LINE__, __FILE__, g_acRspMsg ); return -1; }; return 0; } int pubInstCmsauthfrzmap( struct cmsauthfrzmap * pstCmsauthfrzmap ){ pubInitCmsauthfrzmap(); pubStoVCmsauthfrzmap(pstCmsauthfrzmap); EXEC SQL INSERT INTO cmsauthfrzmap VALUES ( RR_CMSAUTHFRZMAP ) ; if ( SQLCODE ) { strcpy( g_acRspCode, "999998" ); /* 数据库插入错误 */ pubCrtRspInfo( "cmsauthfrzmap",SQLCODE ); pubErrLog( __LINE__, __FILE__, g_acRspMsg ); return -1; }; return 0; }
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -