creating an HTML file with SQL*Plus

Here is an example of creating an HTML file with SQL*Plus:

  1. Create a script, call it runhtml.sql, with the following code:

set ver off

set term off

set markup html on spool on

spool <drive>:\ex1.html

select * from table_name;

select * from table_name;

spool off

  1. Execute this script using:

SQL> @runhtml.sql

  1. Open the output file ex1.html, which, in our example, it is saved on the C:\ drive.

  2. Now you can import this ex1.html in Excel 2000. You do not need to create a csv file anymore. You can also use an html file.

相关推荐
2***s67211 小时前
给SQL server数据库表字段添加注释SQL,附修改、删除注释SQL及演示
数据库·sql·oracle
2***d88512 小时前
使用 MySQL 从 JSON 字符串提取数据
mysql·oracle·json
I***261513 小时前
智能生成ER图工具。使用 SQL 生成 ER 图:让数据库设计更高效
数据库·sql·oracle
i***118614 小时前
【Sql Server】随机查询一条表记录,并重重温回顾下存储过程的封装和使用
数据库·oracle
杨DaB18 小时前
【MySQL】02 数据库的基本操作
数据库·mysql·oracle
jnrjian18 小时前
Oracle hints 空格要求
sql·oracle
YJlio1 天前
「C++ 40 周年」:从“野蛮生长的指针地狱”到 AI 时代的系统底座
c++·人工智能·oracle
x***13391 天前
SQL Server 创建用户并授权
数据库·oracle
Gobysec1 天前
Goby 漏洞安全通告|Oracle Identity Manager 命令执行漏洞(CVE-2025-61757)
安全·oracle·漏洞检测·cve-2025-61757·漏洞研究
last_zhiyin1 天前
Oracle sql tuning guide 翻译 Part 6-5 --- Hint使用报告的操作方法和例子
数据库·sql·oracle·sql tunning