当前位置:网站首页>数据库函数的用法「建议收藏」
数据库函数的用法「建议收藏」
2022-07-04 13:54:00 【全栈程序员站长】
大家好,又见面了,我是你们的朋友全栈君。
dgkhjbxx–客户表 列(khmc)客户名称 列(khbh)客户编号
apply_main_crdt–申请表 列(cust_no)客户编号
create or replace function cmis_getkhmc(id varchar2)
return varchar2 is khmc_mingcheng dgkhjbxx.khmc%type;
begin
select a.khmc into khmc_mingcheng from dgkhjbxx a where a.khbh=id;
return khmc_mingcheng;
end;
sql中的用法就是
select cmis_getkhmc(cust_no) from apply_main_crdt;
这个用法就是在对应的表中(dgkhjbxx)有对应的客户编号,才能查询出对应的名称,
没有对应的编号就会显示成空,有对应的编号就会显示出对应的客户名称
发布者:全栈程序员栈长,转载请注明出处:https://javaforall.cn/149321.html原文链接:https://javaforall.cn
边栏推荐
猜你喜欢
IO流:节点流和处理流详细归纳。
Force button brush question 01 (reverse linked list + sliding window +lru cache mechanism)
Who the final say whether the product is good or not? Sonar puts forward performance indicators for analysis to help you easily judge product performance and performance
Helix Swarm中文包发布,Perforce进一步提升中国用户体验
Redis的4种缓存模式分享
关于FPGA底层资源的细节问题
How to handle exceptions in multithreading?
程序员自曝接私活:10个月时间接了30多个单子,纯收入40万
Ali was laid off employees, looking for a job n day, headhunters came bad news
numpy笔记
随机推荐
%f格式符
C language course design questions
Redis哨兵模式实现一主二从三哨兵
宽度与对齐
PLC Analog input analog conversion FC s_ ITR (CoDeSys platform)
Is BigDecimal safe to calculate the amount? Look at these five pits~~
如何配和弦
Summary of common problems in development
When synchronized encounters this thing, there is a big hole, pay attention!
Who the final say whether the product is good or not? Sonar puts forward performance indicators for analysis to help you easily judge product performance and performance
LVGL 8.2 LED
openresty 重定向
Programmer turns direction
leecode学习笔记-约瑟夫问题
Comment configurer un accord
PLC模拟量输入 模拟量转换FC S_ITR (CODESYS平台)
Redis的4种缓存模式分享
[differential privacy and data adaptability] differential privacy code implementation series (XIV)
es6模块化
Implementation of macro instruction of first-order RC low-pass filter in signal processing (easy touch screen)