Date query ran in PL/SQL Developer shows time, but does not show in Oracle SQL Developer

前端 未结 3 491
情书的邮戳
情书的邮戳 2020-12-21 23:15

The same query ran in PL/SQL Developer shows time, however it does not show in Oracle SQL Developer. Is there a way to get the time in SQL Developer?

In SQL Develope

相关标签:
3条回答
  • 2020-12-21 23:33

    You can change this in the Tools / Preferences dialog of SQL developer:

    1. Select Database / NLS Parameters in the tree view on the left.

    2. Then put dd/mm/yyyy hh24:mi:ss into the Date Format field.

    3. Press OK to close the dialog.

    0 讨论(0)
  • 2020-12-21 23:53

    To make it simple: use to_char() function, it will work with SQL developer as well as Pl/sql.

    select to_char(sysdate,'MM-DD-YYYY HH:Mi:SS') from table_name;

    0 讨论(0)
  • 2020-12-21 23:54

    Can't see your query, but in oracle, it would look like this:

     select sysdate from dual
    
    0 讨论(0)
提交回复
热议问题