Home > Database > Mysql Tutorial > oracle pl/sql 本地打印html报表

oracle pl/sql 本地打印html报表

WBOY
Release: 2016-06-07 14:54:44
Original
1544 people have browsed it

将打印到output的过长一行句子,自动截断成几行,用来打印本地报表: from http://hgworkhouse.org PL/SQL 报表打印 Oracle Procedure my_output(p_text in varchar2) is p_sum_length number := 0; p_length number := 200; p_index number := 1; p_time numb

将打印到output的过长一行句子,自动截断成几行,用来打印本地报表: from http://hgworkhouse.org PL/SQL 报表打印 Oracle
Procedure my_output(p_text in varchar2) is
    p_sum_length number := 0;
    p_length     number := 200;
    p_index      number := 1;
    p_time       number := 0;
  begin
    select length(p_text) into p_sum_length from dual;
    p_time := ceil(p_sum_length / p_length);

    for i in 1 .. p_time loop
      dbms_output.put_line(substr(p_text, p_index, p_length));
      p_index := p_index + p_length;
    end loop;
  end my_output;
Copy after login
Related labels:
source:php.cn
Statement of this Website
The content of this article is voluntarily contributed by netizens, and the copyright belongs to the original author. This site does not assume corresponding legal responsibility. If you find any content suspected of plagiarism or infringement, please contact admin@php.cn
Popular Tutorials
More>
Latest Downloads
More>
Web Effects
Website Source Code
Website Materials
Front End Template