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.

相关推荐
float_六七19 小时前
数据库连接池:性能优化的秘密武器
数据库·oracle·性能优化
IT 小阿姨(数据库)19 小时前
PgSQL中pg_stat_user_tables 和 pg_stat_user_objects参数详解
linux·运维·数据库·sql·postgresql·oracle
float_六七1 天前
预编译SQL:安全与性能的双重保障
sql·安全·oracle
代码的余温1 天前
Oracle RAC认证矩阵:规避风险的关键指南
数据库·oracle·矩阵
吃饭最爱2 天前
JUnit技术的核心和用法
数据库·oracle·sqlserver
沙二原住民2 天前
提升数据库性能的秘密武器:深入解析慢查询、连接池与Druid监控
java·数据库·oracle
Mr_Xuhhh2 天前
sqlite3的使用
jvm·oracle·sqlite
xianyinsuifeng2 天前
Oracle 10g → Oracle 19c 升级后问题解决方案(Pro*C 项目)
c语言·数据库·oracle
半夏陌离3 天前
SQL 拓展指南:不同数据库差异对比(MySQL/Oracle/SQL Server 基础区别)
大数据·数据库·sql·mysql·oracle·数据库架构
jnrjian3 天前
v$lock TS lock id1 用于发现Oracle pdb不能关闭的sid
sql·oracle