Is Sql plus command avaliable in sql developer

SQL developer is able to do most of thing can be done with sql plus with GUI , cool.
However, seems sql command, such as show parameter, start database have to be done in sql plus.
is this true?
most of time in my development, I just open sql developer now. but seems in this statuation, i have to use sql plus.

jz2 wrote:
SQL developer is able to do most of thing can be done with sql plus with GUI , cool.
However, seems sql command, such as show parameter, start database have to be done in sql plus.
is this true?
most of time in my development, I just open sql developer now. but seems in this statuation, i have to use sql plus.As far as I know you still have to start the database from SQL*PLUS. If your schema has privileges you can get parameter values in SQL*Developer by querying V$PARAMETER (SET_CATALOG_ROLE privilege).
The two tools are not the same. Much of what you can do with SQL*PLUS you can do with SQL*Developer but I feel that SQL*PLUS still has better scripting abilities along with its bind variable storate. On the other hand the GUI interface of SQL*Developer Is fairly easy to use. The danger is editing procedures/functions/packages in the database forgetting to back them up from SQL*Developer first; SQL*PLUS forces me to use scripts.
Depending on what I am doing I use either SQL*PLUS or SQL*Developer (which I like better for queries with long select lists).
I'm having trouble getting DBMS_OUTPUT.PUT_LINE to work the way I expect in SQL*Developer; sometimes the output just does not appear without repeated executions of the generating program.

Similar Messages

  • .......Embedding  SQL PLUS commands inside PL/SQL.....

    hai every body,
    I have a doubt regarding sql plus commands and PL/SQL..I am using Oracle 10g..I have created 1 procedure for deletion/updation of transactions..and the number of effected rows I just displayed with using " *dbms_output.put_line* (SQL%ROWCOUNT)"..hence before executing the procedure the sqlPlus command "*SET SERVEROUTPUT ON*" should turn on..at most times it is forget to turn on and output becomes vague..
    hence my question is "*Is there any package or any thing to execute sql plus commands(here it is SET SERVER OUTPUT ON) through PL/SQL statements???*"
    with thanks,
    jp@valapad

    jp@valapad wrote:
    I have a doubt regarding sql plus commands and PL/SQL..
    Easy PL/SQL supports PL/SQL commands and embedded SQL, which are found in the PL/SQL and SQL reference manuals.
    http://download.oracle.com/docs/cd/E11882_01/appdev.112/e10472/toc.htm
    http://download.oracle.com/docs/cd/E11882_01/server.112/e10592/toc.htm
    It does not support the commands of other applications or languages such as SQL*Plus, Unix or COBOL for example.
    I am using Oracle 10g..I have created 1 procedure for deletion/updation of transactions..and the number of effected rows I just displayed with using " *dbms_output.put_line* (SQL%ROWCOUNT)"..hence before executing the procedure the sqlPlus command "*SET SERVEROUTPUT ON*" should turn on..at most times it is forget to turn on and output becomes vague..You can set serveroutput on in your log in script for SQL*Plus if you keep forgetting.
    http://download.oracle.com/docs/cd/E11882_01/server.112/e10823/ch_two.htm#sthref94
    hence my question is "*Is there any package or any thing to execute sql plus commands(here it is SET SERVER OUTPUT ON) through PL/SQL statements???*"No.

  • How to issue a SQL*Plus command from PL/SQL program?

    Thanks.

    You can't issue a SQL*PLus command from a PL/SQL program. If you can tell us more about what you are trying to do, perhaps we can offer a substitute.

  • Need to execute SQL PLUS commands from C# code

    Hello all,
    This is my first question here and hopefully I will get my solution :)
    Right now we are doing 3 tasks manually
    1) Clearing everything from a DB.
    We use sql plus and execute this :
    RAMNIVAS_CI/RAMNIVAS_CI@orclwex3
    set pages 0
    set lines 80
    spool c:\delete_objects_CI
    select 'drop '||object_type||' '||object_name||';'
    from user_objects;
    spool off
    start c:\delete_objects_CI.lst
    purge recyclebin;
    set pages 100
    select count(*) from user_objects;
    RAMNIVAS_CI/RAMNIVAS_CI@orclwex3 are the username and pwd which gets input when we paste entire thing in sql plus
    2) Then we restore that DB again using sql plus to do it using the command:
    imp file=CL.DMP log=CL.log buffer=1000000 fromuser=RAMNIVAS_CL touser=RAMNIVAS_CL statistics=none grants=n commit=y
    3)Execute sql scripts on it using sql developer. (This is not hard I guess coz I know we can use oracle client)
    4) Take backup using this command:
    exp RAMNIVAS_CI/RAMNIVAS_CI@ORCLWEX3 file=CI.dmp log=CI.log direct=y compress=y buffer=1000000 grants=n statistics=none
    Is there anything I cna do to execute SQL PLUS commands using c#?

    Hi,
    You can execute OS commands via the SHELL function provided in .NET. See the MSDN for more info.
    Some of the things you can do directly from .NET via ODP and PLSQL, some not.
    1) Dropping the user objects can be done via a plsql procedure where you open a cursor for "select 'drop '||object_type||' '||object_name||';' ..." and then use EXECUTE IMMEDIATE to execute the resulting commands. You can invoke the procedure via ODP.
    2) IMP is an exe, not a sqlplus command, so you're not actually using sqlplus there. You can still use the SHELL command though to invoke that.
    3) Executing SQL Scripts via ODP.NET is not something you can do very easily. If you search the threads here you should be able to find some solutions others have come up with to parse the file and execute the statements one by one, but there's nothing built in to ODP to execute a script file.
    You may want to just shell out to sqlplus user/pwd@db @scriptfile.sql but you may have issues trying to track down errors if any occurred, as I'm not sure where they go in that case.
    4) just as with IMP, EXP is an exe, so you could shell out to that.
    Corrections/comments welcome.
    Greg

  • SQL Plus command to print a report in Landscape format

    Hi,
    what is the SQL Plus command to print a report in Landscape format?

    841731 wrote:
    Hi,
    what is the SQL Plus command to print a report in Landscape format?SQLPlus doesn't print, and it doesn't know about 'landscape' vs. 'portrait' any more than it knows about fonts. the only 'formatting' it knows is line size, page size. And all it does with line size is know where to insert a CR/LF pair (windows) or a CR (*nix). The only thing it knows to do with page size is repeat column headers.
    The rest is up to whatever application you use to open the pure asciii text spool file.

  • How to find GUI SQL*Plus command tool in Oracle 8i (version 8.1.7)

    I had installed Oracel 8i Enterprise Edition (version 8.1.7) on my server machine (Windows NT 4.0), I'd like to use Oracle Navigator (GUI SQL*PLUS command tool), but I can not find it from the menu. I know Oracle Navigator is available in Oracle 7. Can anyone tell me where and how to use GUI SQL*PLUS command tool in Oracle 8i Enterprise Edition (version 8.1.7) ?
    thanks a lot.
    David Zhu

    Hi
    Oracle Navigator is part of Personal Oracle7 and Oracle Lite. I don't know is it available in 8i Personal Edition but I am sure that it is not part of Standard and Enterprise Edition.
    Regards
    null

  • Fire OMB Plus commands from PL/SQL

    Hi all,
    does anyone know if it is possible to fire OMB Plus commands from PL/SQL procedures?
    I can imagine that there might be a PL/SQL package in the repository owner schema that accepts OMB Plus commands as strings...or something similar...
    Thanks,
    Elio

    Hi Elio
    I don't know about any existing package that could do that.
    What I'd suggest is to build a stored procedure/function/package that could do that. Or even, execute OMB Scripts in the host from a pl/sql program.
    Good luck.
    Regards,
    Marcos

  • Executing Sql* plus commands

    Hi
    Can we execute SQL *plus commands using JDBC OCI Driver. If so What is the procedure to execute and Which parameters to be set
    With Regards
    Vara Prasad

    AFAIK: no, you can't. SQL*plus is kind of a shell (the worst one I've seen so far), so via JDBC (both OCI and thin), you lack the interpreter.

  • Running a SQL*Plus command from Java

    I have a requirement to run SQL* Plus commands from Java. The results as they would appear in SQL*Plus window or spool file should be captured and stored in a table.
    For example,
    SQL> select * from dual;
    D
    X
    1 row selected;
    SQL>
    All the lines above should be stored for later use.
    Could any one give pointers?
    Thanks,
    Ravi

    <p>
    Hi,
    </p>
    <p>
    <strong><font face="Courier New">
    public class RuntimeExecApp {
     public static void main(String args[]) throws IOException
      Runtime r = Runtime.getRuntime();
      r.exec(&quot;C:\\Oracle\\sqlplus.exe&quot;);
    }</font></strong>
    </p>
    <p>
    Kuba 
    </p>
    Message was edited by:
    KUBA

  • SQL * Plus commands using JDBC

    Hi,
    Is it possible to run SQL * Plus commands using JDBC?
    Like Describe mytable , @mysql.sql etc....
    Pl. let me know any hints or way to handle it..
    Regards,
    Kavi

    like masuda1967 said, and you have MetaData objects for ResultSets as well.
    @something.sql you can call using CallableStatement objects, look it up in jdbc docs....

  • Error 45 Initializing In SQL*Plus When Running A Sql Script

    Hi All
    I have a daily scheduled jobs running on Windows server 2003 and 2008. Oracle Version :10.2.0.1 and 10.2.0.4
    right now jobs are not even starting when i run them manually. Found the error Error 45 Initializing In SQL*Plus When Running A Sql Script.
    it says Bug:3039738.
    what is the solution to fix this Bug ?
    thanks
    Shawn

    user9174724 wrote:
    Hi
    do you think the Problem is not with the script ?
    when i run the job its reaching SQLPLUS and giving error
    Error 45 Initializing In SQL*Plus When Running A Sql Script .
    Server:windows 2003 and oracle version :10.2.0.1
    CMD /C %ORACLE_HOME_PRIME%\bin\sqlplus.exe /NOLOG @ %xxxx_HOME%\DBA_Backup\BackupDo.sql testdb BackupFull
    The above line does the following:
    1) launches a command procesor
    2) passes that command processor the following command line parms:
    /C
    (process the following command, then terminate)
    %ORACLE_HOME_PRIME%\bin\sqlplus.exe
    the launched processor will process the executable 'sqlplus.exe' found in the \bin subdirectory, found in the directory indicated by the environment variable ' ORACLE_HOME_PRIME'. The remainder of the command line will be passed to sqlplus.exe for interpretation and processing
    /NOLOG
    tell sqlplus to start up without trying to immediately log on to a database
    typically used to indicate to sqlplus that the immediately following string names a file of sql and sqlplus commands to be processed.
    %xxxx_HOME%\DBA_Backup\BackupDo.sql
    tell sqlplus to execute the commands found in the file 'BackupDo.sql', found in the subdirectory DBA_Backup, found in the directory name by the environment variable 'xxxx_HOME'.
    testdb
    BackupFull
    pass the values 'testdb' and 'BackupFull' to be used as values for substitution variables &1 and &2 in the file 'BackupDo.sql'
    Script:
    rmanbackup.rman
    BACKUP AS COMPRESSED BACKUPSET DATABASE FORCE PLUS ARCHIVELOG;
    DELETE NOPROMPT ARCHIVELOG ALL BACKED UP 2 TIMES TO DEVICE TYPE DISK;
    LIST BACKUP SUMMARY;
    LIST BACKUP;
    EXIT;I don't know what you expect of this. It is an rman script and we've seen no sign of an rman script being executed in any of what you've shown us. RMAN commands are processed by rman, not sqlplus.
    Unfortunately, you didn't think showing us the contents of BackupDo.sql was of any value in finding out what your problem was.
    Edited by: EdStevens on Jul 11, 2011 7:58 PM

  • Maximum length of SQL*Plus Command?

    I'm typing a long query into SQL*Plus (Linux, version 9.2.0.1... yes, I know it's ancient).
    If I run this query, all works fine:
    select 'update myauditing_table set test_details='''||grantee||''' where myaudit_refno=''A.FE'';' from (select case when upper(value) in ('DBO','TRUE')  then (select agg_concat(grantee) from dba_tab_privs where table_name='AUD$')
    else (select 'AUDIT_TRAIL is set to: '||value from dual) end as grantee from v$parameter where upper(name)='AUDIT_TRAIL' order by grantee);
    'UPDATEMYAUDITING_TABLESETTEST_DETAILS='''||GRANTEE||'''WHEREMYAUDIT_REFNO=''A.F
    update myauditing_table set test_details='AUDIT_TRAIL is set to: DB' where myaud
    it_refno='A.FE';(In other words, is SQL that generates other SQL: if AUDIT_TRAIL is set to something interesting, tell me who has access to the AUD$ table. And it's working fine... the agg_concat function mentioned is simply Tom Kyte's stragg function under another name, as lifted word-for-word from http://www.sqlsnippets.com/en/topic-11591.html)
    Now this is what happens if I take out the linebreak after the mention of AUD$, so that the command is submitted as one single line of code:
    SQL> select 'update myauditing_table set test_details='''||grantee||''' where myaudit_refno=''A.FE'';' from (select case when upper(value) in ('DBO','TRUE')  then (select agg_concat(grantee) from dba_tab_privs where table_name='AUD$') else (select 'AUDIT_TRAIL is set to: '||value from dual) end as grantee from v$parameter where upper(name)='AUDIT_TRAIL' order by grantee);
    SP2-0734: unknown command beginning "s set to: ..." - rest of line ignored.The error message indicates that the text has been 'split' at the 'AUDIT_TRAIL is set to...' bit, so that "s set to" is being treated as a new command, which is of course syntactically invalid. There is definitely no other change in text between the two versions, apart from the removal of a carriage return before the "else" statement.
    Possibly a coincidence, but the first "s" in "s set to" appears at position 258 in the entire text... close to a possible 255 or 256 character limit, perhaps?
    The same problem happens whether I run the command as a script (@mysql.sql) or typed in directly into a client SQL*Plus session. Is there some inherent limit to the length of commands that SQL*Plus can process in this version? My code runs fine on 10g and 11g databases/clients, whether it's on one line or two. Anyone know of a bug in 9i regarding this? And if there's a workaround (other than the obvious one of upgrading, of course!)

    As mentioned, it's choking at the 258th character, not the 240th. Also, it's a SELECT statement, not a COPY command (one relates to the database, the other is an internal SQL*Plus feature). And someone else also kindly pointed out that SQL*Plus has a command limit length (i.e., database-related commands) of 2500 characters. So I don't think that's the issue.
    I can be a bit more specific about this one now, though. I've a sequence of Solaris boxes running 9.2.0.1 up, and the results are that 9.2.0.1 is affected; and it's a problem for 9.2.0.7:
    SQL> select * from v$version;
    BANNER
    Oracle9i Enterprise Edition Release 9.2.0.1.0 - 64bit Production
    PL/SQL Release 9.2.0.1.0 - Production
    CORE    9.2.0.1.0       Production
    TNS for Solaris: Version 9.2.0.1.0 - Production
    NLSRTL Version 9.2.0.1.0 - Production
    SQL> select 'update myauditing_table set test_details='''||grantee||''' where myaudit_refno=''A.FE'';' from (select case when upper(value) in ('DBO','TRUE')  then (select agg_concat(grantee) from dba_tab_privs where table_name='AUD$') else (select 'AUDIT_TRAIL is set to: '||value from dual) end as grantee from v$parameter where upper(name)='AUDIT_TRAIL' order by grantee);
    SP2-0734: unknown command beginning "s set to: ..." - rest of line ignored.And...
    SQL> select * from v$version;
    BANNER
    Oracle9i Enterprise Edition Release 9.2.0.7.0 - 64bit Production
    PL/SQL Release 9.2.0.7.0 - Production
    CORE    9.2.0.7.0       Production
    TNS for Solaris: Version 9.2.0.7.0 - Production
    NLSRTL Version 9.2.0.7.0 - Production
    SQL> select 'update myauditing_table set test_details='''||grantee||''' where myaudit_refno=''A.FE'';' from (select case when upper(value) in ('DBO','TRUE')  then (select agg_concat(grantee) from dba_tab_privs where table_name='AUD$') else (select 'AUDIT_TRAIL is set to: '||value from dual) end as grantee from v$parameter where upper(name)='AUDIT_TRAIL' order by grantee);
    SP2-0734: unknown command beginning "s set to: ..." - rest of line ignored.But in 10.2.0.1, the problem disappears.
    I am not sure, but it is perhaps related to metalink note 285913.1, since we did get some ORA-00600: internal error code, arguments: [qernsRowP], [1] errors in the alert log with a slightly different version of the above query. Changing the query obviously alters the test, though, so it may be completely unrelated.
    Either way, I think it's definitely a version-specific SQL*Plus bug (though it would be nice if any other 9i owners out there could try it and report back!)
    Anyway, the workaround is simply to submit the command on two separate lines, wherever possible. And of course... to upgrade.

  • SQL works from SQL*Plus command line but not as a DBMS_JOB submitted job

    Oracle 10g 10.2
    Got a procedure which does not run correctly as an Oracle job but runs fine as a SQL script.
    There are no Oracle errors (or any errors) of any kind when the job does not run fine – it just does not update any rows. But when run as a SQL script – the same way it is run as a job – then the rows are updated.
    Any ideas?

    Good stuff....
    See my replies to some of the questions in italics
    a) Different NLS settings => The job uses the NLS settings of the session that created it. If you create it with some tool like TOAD, you might have a different environment than with sql*plus. Runs good in TOAD and SQL*Plus using the command-line feature - just 'acts funky' when submitted.
    b) Interval issue. Are you sure the job was running? Isn't still running? The job runs successfully - even logs a successful message in our logging table.
    c) User/priviledge issue. Sometimes a job needs direct grants whereus a procedure can be called with priviledges granted through roles. Don't know - need to check this out.
    d) Transaction handling / Error Handling. The job runs into some error, but the error is supressed, because of bad exception handling. What is the value in the BROKEN column, when you do: select * from user_jobs; I would think that, since the errors are logged into a side table, an error would be found there. However, no errors are found. The BROKEN column is 'N'.

  • SQL Plus command line: Arrow keys not giving previous commands back

    As in tittle, I'm using sqlplus on Windows XP and OEL 5.5 and I can use up,down arrows in Windows to select previous command but I can't do it in Linux.
    My DB is 11gR2 on OEL 5.5 .

    Hi,
    Sorry, I don't know anything about Linux. The up-arrow feature on Windows seems to be provided by the operating system, not by Oracle. I would guess it's that way on Linux, too.
    In Windows, there's one more thing that affect this: Properties -> Options -> Command History. Perhaps Linux has something similar.
    In Windows (not just SQL*Plus or Oracle programs) if you right-click on the title bar at the top of a window, uyou get a small drop-down.
    If you select the last item, "Properties", you get a small window with 4 tabs, the 1st of which is "Options".
    On that "Options" tab, there are some settings for "Command History", oncluding Buffer Size. That seems to be the number of old ommands it will keep. You can set it to 0, but that seems to still keep 1 old command available via up-arrow.
    Sorry I don't know any more.

  • How to control layout in SQL*plus command

    Hi, All,
    I use SQL*plus to generate a simple report
    BREAK ON <column1> duplicates skip page ON REPORT
    COMPUTE COUNT LABEL 'Total number of trader shown on this report for this :' OF <column2> On <column1>
    it shows '********' and '-------------------' above the lable and compute result.
    Can I take '******' and '----------------' off
    and the label can not longer than the length of <column1>, otherwise it will be truncated.
    what if it is longer than the length of <column1>
    and I don't want to change the layout of <column1> ?
    Thanks

    Peter,
    FYI, this forum is dedicated for Oracle Reports issues. There's another forum dedicated to SQL*Plus - I believe it's now called iSQL*Plus, btw. You should try your question in the other forum.
    regards,
    Stewart

Maybe you are looking for