Running a SQL Script to Create an Object Type

When I do Database Development with JDeveloper and fellow the instruction at
http://www.oracle.com/technology/obe/obe1013jdev/dbdevelopment/obe_%20dbasedevmt.htm
and try to Running a SQL Script to Create an Object Type by Right-clicking emp_rec.sql in the editor and
choose Run in SQL*Plus > hrconn, the new Obuect type can not created. The screen flashs and I only got the
message
"Invoking SQL*Plus...
D:\oracle\product\10.2.0\db_1\BIN\cemutls.exe
hr@(DESCRIPTION=(ADDRESS_LIST=(ADDRESS=(PROTOCOL=TCP)(HOST=localhost)(PORT=1521)))(CONNECT_DATA=(SID=ORCL)))
@emp_rec.sql" and nothing else (No error like JBO-XXXXX).
Can anybody Help Me? Thanks a lot!
SID: ORCL

Hi Simon,
Having had a closer look at your original message it seems that rather than selecting the SQL*Plus executable in the directory you have managed to select the file 'D:\oracle\product\10.2.0\db_1\BIN\cemutls.exe'.
If you go to 'Tools | Preferences' and select the 'Database Connections' node and alter the 'SQL*Plus Executable' field to 'D:\oracle\product\10.2.0\db_1\BIN\sqlplus.exe' and then try again, this should then work.
Regards,
Lisa

Similar Messages

  • How can I run a SQL script file...

    How can I run a SQL script file from a location on my computer without providing the whole path?
    Is there some way I can set a "Working folder" in SQL Plus??
    Thanks!
    Tom

    You can create an environment variable called "SQLPATH" which is a list of directories that SQL*Plus will search for your .SQL
    scripts.
    I would like to use another directory than the oracle/bin...
    How can I do this ??
    Hello,
    U can do this by this way:
    Save odm_script.sql file to the default Oracle
    directory i.e. Oracle-Home/bin and Run following command
    through SQL Plus.
    SQL>@Script_Name
    I hope this will resolve ur problem.
    Regards,
    Omer Saeed Khan.

  • Getting windows error during running the sql scripts from form 6i

    I made a little form application. The purpose of this application is to generate explain plan for a particular SQL. Some sql scripts run internally in order to populate the result on form’s screen after pressing the form’s button but I am getting windows error during running the sql scripts from form 6i.
    I am using forms 6i with patch 17 with Oracle 10G database on windows 2000 professional on same computer.
    This application runs fine with 8i.
    Please inform me where the problem is and how to overcome it.
    Zafri.

    I am using Text_IO in my form's when button press trigger , inorder to create the
    text file, then in the same when button press triger
    I am calling RMAN via host command in order to run the script which was created by text_IO.
    Below you find some of the code. I will appreciate if you solve the problem.
    when button press trigger:
    Declare
    in_file3 Text_IO.File_Type;
    linebuf3 VARCHAR2(1800);
    output11 varchar2(1000);
    BEGIN
         output11:='C:\EXPLAIN_PLUS\misc\rm_file.bat ';
    Host(output11,no_screen);
    :sql.execution_plan:= 'Working........................';
    synchronize;
    in_file3 := Text_IO.Fopen('c:\explain_plus\misc\create_table.txt', 'w');
    Text_IO.Put_Line(in_file3, linebuf3);
    Text_IO.put_line(in_file3,' ');
    Text_IO.put_line(in_file3,' run { sql "create table PLAN_TABLE (statement_id,...object_name varchar2(30),object_instance numeric,object_type varchar2(30),optimizer varchar2(255),search_columns number,id .....partition_start varchar2(255),partition_stop  varchar2(255),partition_id numeric,other long,distribution varchar2(30)) "; } ');
    Text_IO.put_line(in_file3,' ');
    Text_IO.put_line(in_file3,' ');
    Text_IO.FCLOSE(in_file3)
              Declare
    un VARCHAR2(80);
    pw VARCHAR2(80);
    cn VARCHAR2(80);
    output VARCHAR2(1000);
    output2 VARCHAR2(1000);
    dummy varchar2(40);
    in_file Text_IO.File_Type;
    linebuf VARCHAR2(1800);
    BEGIN
         Get_Connect_Info(un,pw,cn);
         /* for Plan_table Begg. Second INNER BLOCK */
         declare
              dummy2 varchar2(40);
         begin
         select table_name into dummy2 from all_tables where table_name='PLAN_TABLE';
         if dummy2 = 'PLAN_TABLE' then
         output2:='rman target/ nocatalog @C:\EXPLAIN_PLUS\MISC\TRUNC2.txt ' ;
    Host(output2,no_screen);
         end if;
         exception
         when no_data_found     then
    output2:='rman target/ nocatalog @C:\EXPLAIN_PLUS\misc\create_table.txt ';
    Host(output2,no_screen);
         end; --

  • AWM 11.1.0.7B question running global_11g_create_cubes.sql script

    Hi everybody,
    I installed AWM 11.1.0.7B and Oracle Database 11g software, version 11.1.0.6.0.
    I am trying to install Sample Schemas & Code.
    I got an error running global_11g_create_cubes.sql script that I downloaded from the http://www.oracle.com/technology/products/bi/olap/olap_downloads.html#software
    Here is an error:
    Begin installation
    ... deleting GLOBAL AW (if it exists)
    ... creating GLOBAL AW
    begin
    ERROR at line 1:
    ORA-37162: OLAP error
    XOQ-00506: Unable to parse XML string sent from the client to the server
    ORA-06512: at "SYS.DBMS_CUBE", line 88
    ORA-06512: at "SYS.DBMS_CUBE", line 134
    ORA-06512: at "SYS.DBMS_CUBE", line 154
    ORA-06512: at "SYS.DBMS_CUBE", line 144
    ORA-06512: at "SYS.DBMS_CUBE", line 181
    ORA-06512: at line 2
    The following line in the script gives an error:
    dbms_cube.import_xml('GLOBAL_INSTALL', 'GLOBAL_MV.XML');
    Any help will be greatly appretiated.
    Thank you.
    - t

    I suspect the problem is that you are using an 11.1.0.7 client to access an 11.1.0.6 server. This configuration should work, but there was a bug at some point with new clients and old servers. In any case you would be advised to upgrade your server to either 11.1.0.7 or, at least, the latest 11.1.0.6 OLAP patch.

  • Silent installation then run a sql script

    I'm trying to do a silent install of 10g on a windows server.
    I have created the response file and it works correctly.
    After the oracle software has successfully installed I want to run some sql scripts on the newly created database, how do I do this automatically?
    I have tried to create a batch script to do it but because the setup command opens in a separate window it never returns back to the batch script to run the sql.
    install.bat:
    start /wait c:\oracle_software\database\install_oraclesw.bat
    call run_sqlscripts.bat
    pause
    install_oraclesw.bat:
    setup -silent -responseFile c:\oracle_software\database\response\standard.rsp -nowait
    Thanks in advance

    I'm doing a 10gr1 silent install and one problem I ran into was the setup executes when cause java, then it closes, so the next step in my script executed immediately.
    I had to use the choice command to bring up a prompt to pause the script.
    start cmd /c setup.exe -responseFile c:\stardard.rsp -nowelcome -silent
    choice /C YN /M "Press Y if install completes successufully, else press N."

  • How and where to run utlxplan.sql script?

    Hi,
    A basic question: where and how to run utlxplan.sql script? I'd like to know both in window and linux environment.
    regards.....

    From sqlplus, you can connect as sys and run the utlxplan.sql. Then you need to grant privileges to other users and create synonyms...

  • How to run a sql script in oracle forms

    Hi,
    For me there is an sql script. I need to run that sql script in forms.
    Actually we will run that sql file in pl/sql developer by giving @and the file name.
    But how to run that file in forms.
    Can any one help on these.Which book I have to look.
    Thanks

    Actually there is a script files which will drop all the indexes and tables.
    DROP querry will be there for each index and each table.
    So I run the script all the indexes and all the tables will be deleted. So using forms I have to run that script.
    Thanks

  • How to run the SQL Script in SQL Prompt?

    Hi ExpertGroup,
    I have written one SQL Script name called "MySQLSCript.SQL". I want to know how to run the SQL Script in SQL Prompt?.
    Generally, I run SQL Script in PL/SQL Developer tool. But In this case, some SET command is not working/supporting in PL/SQL Developer Tool.
    Let me know, How to Run in SQl Prompt.
    Thanks & Regards,
    Senthil K Kumar.

    This is my SQL Script....
    SET COLSEP '|'
    SET LINESIZE 32767
    SET PAGESIZE 50000
    /* SET LINESIZE 3000
    SET PAGESIZE 50000
    SET DEFINE OFF */
    SET ECHO OFF
    SET FEEDBACK OFF
    --SET HEADING OFF
    SET TRIMSPOOL ON
    SET NEWPAGE NONE
    SET UNDERLINE OFF
    SPOOL &&EnterPath;
    SELECT * FROM &&TableName;
    SPOOL OFF
    SET FEEDBACK ON
    --SET DEFINE ON
    PROMPT Done.
    I am able to run this script in SQL Prompt....
    Its executing fine...
    But, If I am executing again it maynot asking for new set of data....
    alternativily its taking old values only.....
    how can i exeute with new set of data in the sql prompt.....

  • 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

  • OEM12c Job - Run a SQL Script from a central location against multiple targets

    Hi All:
    I need to execute a SQL script that can be run as OEM Job against multiple targets from a single location so that the output csv files are all in that central location. My problem is that the sql script job documentation says "Make sure that the script file is installed in the appropriate location on all targets". Is anyone aware of a way I can do this so that the SQl script is executed from a location on my OMS console?
    Cheers

    Hi
    Create SQL job to run against on the server. Save those results (csv) file in local target. And crete one OS job, to collect all csv files into your OMS Console.
    Regards
    Krishnan

  • Running a SQL Script during task sequence

    We are about to roll out new workstations to our entire enterprise.  With that rollout comes updated software.  The primary application that our end users work with on a daily basis uses SQL Express 2008 R2.  A challenge that we've come across
    is with a SQL script that we need to run, after the workstation has joined our domain.  I have created a batch file, and copied it to the same directory as the AddADGroup.sql script.  I have created an application in SCCM to run the batch file and
    SQL script.  The following is the batch file:
    @echo off
    Set Path=%path%;C:\Program Files\Microsoft SQL Server\110\Tools\Binn
    echo.
    SQLCMD -S .\SQLEXPRESS -U sausername -P xxxxxxxxxxxxxxxxx -i AddADGroup.sql
    echo.
    What I need to know is how to get this batch file to run, and be successful (about 4000 times).  Is running this batch file the best practice?  If not, what is the alternative?
    Thanks! Nate

    Hi,
    The following blog describes that how to deploy bat and script by Packages. 
    SCCM 2012 – deploying bat files and scripts
    (Note: Microsoft provides third-party contact information to help you find technical support. This contact information may change without notice.
    Microsoft does not guarantee the accuracy of this third-party contact information.)
    Best Regards,
    Joyce Li
    We
    are trying to better understand customer views on social support experience, so your participation in this
    interview project would be greatly appreciated if you have time.
    Thanks for helping make community forums a great place.

  • Running utlbstat.sql script

    for testing performance i want to run the utlbstat.sql script
    can i run this script using windows run command.
    i cant run utlesast.sql also.
    so i cant see the report using report.txt

    The UTLBSTAT.SQL is ran from the SQL prompt in SQLPLUS like this as in the case of UN*X:
    SQL> @ ${ORACLE_HOME}/rdbms/admin/utlbstat.sql
    The @ tells SQLPLUS to read the commands/statements from a file.
    It is on a similar path in windoze.
    William

  • Running a SQL Script step invoking PeopleSoft binary

    Running PeopleTools upgrade from 8.53 to 8.54.
    At step, Running the Updated PeopleTools Script, it fails as show below. It does not make sure while all the above steps where SQL Script is involved ran successfully but this one. Did anybody run into the same issue?
    Appreciate any suggestions

    looks different, ideally it should not through this error.
    If your access id details are fine, then raise a case with oracle

  • Run multiple sql scripts using osql

    We have 2 databases which should be installed on each and every sql server.
    STEPS DONE
    1. scripted out these two DB'S as    ex:    db1.sql     db2.sql
    2.Scripted lookup tables in these DB's into two scripts        ex:    lookup1.sql   lookup2.sql
    3.scripted permissions of service accounts in two databases as     ex: perm1.sql    perm2.sql
    In order to run all these scripts in sequence I am planning to use an batch file which executes all these scripts in sequence and also we know the database creation script db.sql looks for the same path for DATA and LOG file locations as it is in the script. Is
    that possible to use parameters to allow dba to set location paths while running batch file?
    The sequence should be as
    db1.sql
    lookup1.sql
    perm1.sql
    db2.sql
    lookup2.sq
    perm2.sql

    Setup a ControlParms table. Let the DBA configure the values in the table.
    Change the .sql scripts to read the ControlParms table for path or other configuration value.
    Dynamic SQL: http://www.sqlusa.com/bestpractices/dynamicsql/
    Kalman Toth Database & OLAP Architect
    SQL Server 2014 Design & Programming
    New Book / Kindle: Exam 70-461 Bootcamp: Querying Microsoft SQL Server 2012

  • Running oracle sql scripts by batch.

    Hi. I need to run a batch of sql scripts. How do I do this using dos batch file.
    Thanks.
    Message was edited by:
    Chael

    in your createtable.sql you can spool the output
    set serveroutput on
    spool c:\yourspoolfile.txt
    select statements....
    spool off
    exit
    for more information you can checkt the sqlplus reference:
    http://download-uk.oracle.com/docs/cd/B19306_01/server.102/b14357/toc.htm
    regards

Maybe you are looking for

  • Stock report with grn no & date

    hello gurus, I need standard stock reports available in SAP with GRN no. and date. points assured* Anand

  • [SOLVED] Is full UTF-8 supported in unicode-rxvt?

    Does urxvt have full UTF-8 support, or it only supports 16 bit unicode characters? I have set inconsolata font for URXVT adding to .Xdefaults this line: URxvt*font: xft: Inconsolata:pixelsize=17:antialias=True:hinting=True I can write most characters

  • PAR DC and SC JDI

    Hi,   What is the best practice  for maitaining EP projects in JDI. I have a bunch of PAR files. 1. should i create a DC for each PAR? 2. Should i create a one SC and assign all my DC's to that SC? 3. what are the files of PAR DC that are normally ch

  • Filling aggregate with different level of aggregation.....

    WE have total 7 aggregates to be activated and filled, 4 belongs to first level ,and three in second level.By mistake we filled  one of the  aggregate at second level, now we want to fill the aggregate which are in the first level....... will there b

  • JDBC CONNECTIONS

    hi all, i have a doubt regarding