Skip to content
Advertisement

Oracle sqlplus functions shows as ###

After submitting a select query, which contains functions such as row_number() or any other function the result is ####. If I use rownum as something, it shows ### if I use just rownum everything is ok.

I had this problem with other generic columns but I could simply use column columnname format 9999;

The problem is not that there is not enough space, there is only one digit per record.

I have googled all over the internet and nothing has answered my problem yet.

Does anyone know what could be the problem with functions and how to format them?

Query and result here

Have tried clear columns, did not work.

Advertisement

Answer

It looks as if you formatted numeric column with a wrong format, which doesn’t allow all digits to be displayed.

For example, this is someone’s salary – looks OK:

But, if you formatted it as follows (i.e. saying that I want to have only two digits (99) for that column), the result is ###:

What to do? The simplest way is to clear formatting:


Another possibility is that numformat (in general) is wrongly set; all these columns are NUMBER, and all of them are affected with this set numformat:

How to fix that? Exit SQL*Plus and reconnect.

User contributions licensed under: CC BY-SA
10 People found this is helpful
Advertisement