当前位置:网站首页>DBMS in Oracle_ output. put_ How to use line
DBMS in Oracle_ output. put_ How to use line
2022-06-23 13:23:00 【Yisu cloud】
Oracle in dbms_output.put_line How do you use it?
This article mainly introduces “Oracle in dbms_output.put_line How do you use it? ”, In daily operation , I believe a lot of people are Oracle in dbms_output.put_line There are doubts about how to use it , Xiao Bian consulted all kinds of materials , Sort out simple and easy-to-use operation methods , I hope to answer ”Oracle in dbms_output.put_line How do you use it? ” Your doubts help ! Next , Please follow Xiaobian to learn !
dbms_output.put_line Usage of
The knowledge points involved are as follows :
1、enable:
stay serveroutput on Under the circumstances , Used to make dbms_output take effect ( Open by default )
set serveroutput on -- take output Service open
2、disable:
stay serveroutput on Under the circumstances , Used to make dbms_output invalid
set serveroutput off -- take output Service closing

3、put:
Write content to memory , wait until put_line Output together ,new_line You can also output .
begin dbms_output.put_line('hello world1111111'); dbms_output.new_line(); dbms_output.put('Hello, Lao An '); dbms_output.put('Hello, Lao An '); dbms_output.new_line(); dbms_output.put_line('Hello, Lao An ');end;/Output :

4、put_line:
Needless to say , The output characters , And refresh buffer, Premise is set severoutput on;
exec dbms_output.put_line('hello world1111111');
5、new_line:
As the end of a line , It can be understood as writing buffer Line break at
set serveroutput onbegin dbms_output.put_line('hello world1111111'); dbms_output.put('Hello, Lao An'); dbms_output.new_line(); dbms_output.put_line('Hello, Lao An');end;/
It uses begin+/ To execute PL/SQL The process , Let me explain oracle Middle slash (/) The meaning of
The slash is to make The server Execute the previously written sql Script . If it's normal select sentence , A semicolon , You can do it . But if it's a stored procedure , Then meet a semicolon , You can't do it right away . This is the time , You need to pass the slash (/) To execute .

6、get_line(value, index):
Get the single line information of the buffer .
notes : Use get_line You can't use put_line Output , because put_line After that will be buffer Empty .( Of course. serveroutput off Under the circumstances put_line It doesn't affect buffer Of ).
7、get_lines(array, index):
Get the multi line information of the buffer in the form of an array
declare v_data dbms_output.chararr; -- Declare local variables first v_numlines number; begin --enable the buffer first. dbms_output.enable(1000000); -- Set the size of the buffer dbms_output.put_line('line one'); dbms_output.put_line('line two'); dbms_output.put_line('line three'); v_numlines := 3; dbms_output.get_lines(v_data, v_numlines); --array, index for v_counter in 1..v_numlines loop dbms_output.put_line(v_data(v_counter)); end loop; end; /Output :

Here we are , About “Oracle in dbms_output.put_line How do you use it? ” That's the end of my study , I hope we can solve your doubts . The combination of theory and practice can better help you learn , Let's try ! If you want to continue to learn more related knowledge , Please continue to pay attention to Yisu cloud website , Xiaobian will continue to strive to bring you more practical articles !
边栏推荐
- KDD 2022 | epileptic wave prediction based on hierarchical graph diffusion learning
- Follow the promotional music MV of domestic tour in Thailand and travel to Bangkok like local people
- If there is a problem with minority browsers, do you need to do a compatibility test?
- 服务稳定性治理
- How do the top ten securities firms open accounts? Is online account opening safe?
- Is it safe for flush to open an account online? What should we pay attention to
- 逆向调试入门-了解PE结构文件
- What a talented company that can turn SAP system into a chicken rib!
- A bug development means that the user will not operate like this, and there is no need to repair it. How should testers respond?
- 20 years' Shanghai station D question Walker (two points, concise)
猜你喜欢

Can cold plate, submerged and spray liquid cooling lead the development of high-performance computing?

KDD 2022 | epileptic wave prediction based on hierarchical graph diffusion learning

Germancreditdata of dataset: a detailed introduction to the introduction, download and use of germancreditdata dataset

"Developer talk" nail connector +oa approval to realize digitalization of school students' leave and work scenes

Network foundation and framework

Ablebits Ultimate Suite for Excel

在線文本過濾小於指定長度工具

The two 985 universities share the same president! School: true

【网站架构】10年数据库设计浓缩的绝技,实打实的设计步骤与规范
[email protected] Hdmi2.0 optical transceiver HDMI HD video optical transceiver"/>4k-hdmi optical transceiver 1 channel [email protected] Hdmi2.0 optical transceiver HDMI HD video optical transceiver
随机推荐
Hanyuan hi tech 1-channel gigabit optical port to 4-channel Gigabit Ethernet electrical port Gigabit 1-optical 4-electric optical fiber transceiver
How do the top ten securities firms open accounts? Is online account opening safe?
16 channel HD-SDI optical transceiver multi channel HD-SDI HD video optical transceiver 16 channel 3g-sdi HD audio video optical transceiver
Hanyuan high tech new generation green energy-saving Ethernet access industrial switch high efficiency energy-saving Gigabit Industrial Ethernet switch
React query tutorial ④ - cache status and debugging tools
Chinatown hiking: feel the strong Chinese flavor in the exotic New York
Analyse et résolution des défaillances de connexion causées par MySQL utilisant replicationconnection
Principle analysis of three methods for exchanging two numbers
Part C - value types and reference types
4-way telephone +1-way Gigabit Ethernet 4-way PCM telephone optical transceiver
20000 words + 30 pictures | MySQL log: what is the use of undo log, redo log and binlog?
Excel-vba quick start (I. macros, VBA, procedures, types and variables, functions)
After the uncommitted transactions in the redo log buffer of MySQL InnoDB are persisted to the redo log, what happens if the transaction rollback occurs?
Hanyuan hi tech 8-way telephone +1-way 100M Ethernet RJ11 telephone optical transceiver 8-way PCM telephone optical transceiver
Tt-slam: dense monocular slam for flat environment (IEEE 2021)
技术分享| WVP+ZLMediaKit实现摄像头GB28181推流播放
R语言dplyr包filter函数过滤dataframe数据中指定数据列的内容包含指定字符串的数据行、基于grepl函数
支持HomeKit、NFC:智汀智能门锁SL1仅需要149元
2-optical-2-electric cascaded optical fiber transceiver Gigabit 2-optical-2-electric optical fiber transceiver Mini embedded industrial mine intrinsic safety optical fiber transceiver
R语言使用MASS包的polr函数构建有序多分类logistic回归模型、使用exp函数和coef函数获取模型中每个变量(自变量改变一个单位)对应的优势比(odds ratio)