简体   繁体   English

Oracle 在 2 个表中返回值

[英]Oracle returns value in 2 tables

currently I'm facing a problem where I select the data from db where it returns the data into 2 tables.目前我面临一个问题,我从数据库中选择数据,它将数据返回到 2 个表中。

I have attached a screenshot of the output.我附上了输出的屏幕截图。 Hope you guys can help.希望大家能帮忙。 Thanks谢谢

This is Screenshot.这是截图。

You need to format the output in the SQL*Plus to make the output looks proper.您需要在 SQL*Plus 中格式化输出以使输出看起来正确。

You can use您可以使用

COLUMN <column_name> FORMAT <format>;

for string:对于字符串:

COLUMN SCENE_NAME FORMAT a15

Example for numbers:数字示例:

COLUMN SCENE_ID FORMAT 99

For more details on column formatting, please refer Oracle documentation here有关列格式的更多详细信息,请参阅此处的Oracle 文档

Also, you will need to set the LINESIZE using此外,您需要使用设置LINESIZE

set linesize 250

here, 250 means the total character that can fit into one line and the size of the character is calculated based on the column format.这里,250表示一行可以容纳的总字符数,字符的大小是根据列格式计算的。

Before that you mention which database table you will display.在此之前,您提到将显示哪个数据库表。 After do select query做选择查询后

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM