当前位置:网站首页>DBMS in Oracle_ output. put_ Line output problem solving process
DBMS in Oracle_ output. put_ Line output problem solving process
2022-06-28 15:05:00 【1024 Q】
Preface
1. Turn on oracle Output
2. use sqlplus land oracle
3. pl/sql Execute output statement
summary
PrefaceRecently I wrote oracle The process , There is one ORACLE in dbms_output.put_line Problems that cannot be output . It took nearly an hour . The following describes the process of solving the problem ( Check data and solve ):
1. Turn on oracle OutputChecked the data , be supposed to oracle The default is off . To execute :
set serveroutput on;
Can only be , So in pl/sql develope Execute the statement in , Report errors , reason : pl/sql I won't support it .
solve : stay windows cmd In the implementation of sqlplus command .
2. use sqlplus land oracle1、 Start in cmd Internal execution : sqlplus /nolog
Report errors : The main idea is No such order
General cause : No installation oracle client , Or there is something wrong with the environment variables .
solve : My is reinstalled oralce client , Then you need to check whether there is this variable in the environment variable , If not, add it manually , Generally, it is necessary to reinstall .
2、 perform sqlplus/nolog
Then input oracle Link information . Here is a link to a remote database
Format :sqlplus user/[email protected]_ip:port/ Instance name
Example :sqlplus xxgx/[email protected]:1521/orcl
The reason for logging in remotely , There will be a slight pause , After connecting . It can be executed show user; Show current user .
Correct display indicates successful login .
additional : View all tables under the current user :
select TABLE_NAME from USER_TABLES;
thus sqlplus Successful landing .
3. pl/sql Execute output statementperform :
--pl/sql programing language --pl/sql Programming languages are right for sql Language extension , bring sql The language has the characteristics of procedural programming .--pl/sql Programming languages are better than general procedural programming languages , More flexible and efficient .--pl/sql Programming language is mainly used to write stored procedures and stored functions .-- The way of life -- The assignment operation can use =: You can also use into Query statement assignment .declare i number(2) := 10 ; s varchar2(10) := ' Ha dd Ha ' ; ena XXGX_TJ_RBBTJ.SYS_TIME%type ; -- Referential variables begin dbms_output.put_line(i); dbms_output.put_line(s); select SYS_TIME into ena from XXGX_TJ_RBBTJ where ID = 1000060; dbms_output.put_line(ena);end;
Show :
Here's what I want to say This output , I haven't found where to output for a long time , It's just SQL There is a Output The window of . Click to see . At that time, I was still confused Ah .
summaryThis is about ORACLE in dbms_output.put_line This is the end of the article on output problem solving , More about ORACLE dbms_output.put_line Please search the previous articles of SDN or continue to browse the related articles below. I hope you will support SDN more in the future !
边栏推荐
- Tencent was underweight again by prosus, the major shareholder: the latter also cashed out $3.7 billion from JD
- 5000倍回报,南非报业投资腾讯赚了一个省
- 安杰思医学冲刺科创板:年营收3亿 拟募资7.7亿
- 力扣今日题-522. 最长特殊序列
- Facebook出手!自适应梯度打败人工调参
- Leetcode (665) -- non decreasing column
- Introduction to common components of IOT low code platform
- High "green premium" of environmental protection products? How far is the low-carbon lifestyle from people
- Leetcode(406)——根据身高重建队列
- [Zhongyi Xinsheng] 5 SPI interface test TF Card
猜你喜欢
Softing epgate Pb series Gateway - integrates the Profibus bus into the ethernet/ip network
【空间&单细胞组学】第1期:单细胞结合空间转录组研究PDAC肿瘤微环境
Le patron a donné trois ordres: discret, discret, discret
QQ被盗号后群发黄图,大批用户“社死”
Tencent was underweight again by prosus, the major shareholder: the latter also cashed out $3.7 billion from JD
[MySQL learning notes 23] index optimization
动力电池,是这样被“瓜分”的
WPF 视频硬解码渲染播放(无空域)(支持4K、8K、高帧率视频)
Facebook出手!自适应梯度打败人工调参
坐拥1200亿,她又要IPO敲钟了
随机推荐
Express template engine
vscode编写markdown文件并生成pdf
笔试面试算法经典–最长回文子串
Leetcode(406)——根据身高重建队列
js 判断字符串为空或者不为空
解决Unable to create process using ‘D:\Program File
code snippet
Facebook! Adaptive gradient defeats manual parameter adjustment
名创优品通过上市聆讯:寻求双重主要上市 年营收91亿
【黑马早报】腾讯回应大批用户QQ号被盗;薇娅丈夫公司被罚19万;中国恒大被申请清盘;关晓彤奶茶店回应被加盟商起诉...
法兰克福地区目前支持sql了吗?
【空间&单细胞组学】第1期:单细胞结合空间转录组研究PDAC肿瘤微环境
智能化转型被加速,企业需要新的工具箱
Jingyuan's safe sprint to the Growth Enterprise Market: it plans to raise 400million yuan for investment and Yunyou software is the shareholder
What are the benefits of this PMP certificate?
安杰思医学冲刺科创板:年营收3亿 拟募资7.7亿
力扣今日题-522. 最长特殊序列
JS judge whether the string is empty or not
Softing epgate Pb series Gateway - integrates the Profibus bus into the ethernet/ip network
R语言ggplot2可视化:使用patchwork包(直接使用加号+)将两个ggplot2可视化结果横向组合起来形成单个可视化结果图