i am trying to run the 'describe table_name' command on oracle. I am using dbeaver for accessing oracle. But, when i run the command, it shows SQLException and error message "invalid sql statement". How can i perform the operation?
-
try using `desc
. – Chaitanya K May 10 '16 at 09:10;` -
I tried it, but the error still occurs – NIDHEESH KRISHNA May 10 '16 at 09:14
-
can you check this link its blocked for me :( https://www.google.co.in/url?sa=t&rct=j&q=&esrc=s&source=web&cd=2&ved=0ahUKEwiFgsirpc_MAhXFBI4KHZw5CXcQFggiMAE&url=http%3A%2F%2Fdbeaver.jkiss.org%2Fforum%2Fviewtopic.php%3Ff%3D2%26t%3D958&usg=AFQjCNFKksnAlOGpL5ERw95oNxUakFvxQQ&sig2=8MXP09iq9hZBmJttfJ_gGg&bvm=bv.121421273,d.c2E&cad=rja – Chaitanya K May 10 '16 at 10:26
-
1Describe is a [client command](http://docs.oracle.com/cd/E11882_01/server.112/e16604/ch_twelve019.htm), not native SQL, so if your client doesn't support it [you may need to roll your own equivalent](http://stackoverflow.com/a/28581465/266304). – Alex Poole May 10 '16 at 10:36
-
hi chaitanya, the link provided you shows the content: DESCRIBE is a keyword from MySQL. Also it is a command in SQL*Plus tool.DBeaver doesn't support SQL*Plus syntax (however you may execute SQL*Plus scripts directly from DBeaver using Tools->Execute Script context menu action). – NIDHEESH KRISHNA May 10 '16 at 10:45
4 Answers
describe
is not a SQL statement, otherwise it would have been documented in the SQL language reference:
The documentation for the describe
command can be found in the SQL*Plus command reference:
which means it is only available in SQL*Plus (and probably in SQL Developer as well). It is a client side command and thus the SQL client you are using needs to support it.
-
1It is supported in Toad, too. (Toad for Oracle 12.10 as of now) – Jonathan Bergeron Jun 22 '21 at 13:11
Highlight the object and press f4 , this would give you the table/object details
https://dbeaver.io/forum/viewtopic.php?f=3&t=1937
as @a_horse_with_no_name has already said desc is not a SQL statement. So we can use this shortcut for that

- 145
- 3
- 16
I just tried it on SQL Developer and it worked. Maybe it wasn't available before, but certainly is SQL Developer 19.1.

- 11
- 3
DESC[RIBE] command is an SQL*Plus command only, even if you try it in SQL Developer it will not work !
Source : https://ss64.com/ora/desc.html

- 1
- 3