How we can create Oracle 9i Database through Commands.

How we can create Oracle 9i Database through Commands.
We need step by step process and all the scripts.

CREATE DATABASE
Caution:
This statement prepares a database for initial use and erases any data currently in the specified files. Use this statement only when you understand its ramifications.
Note Regarding Security Enhancements:
In this release of Oracle and in subsequent releases, several enhancements are being made to ensure the security of default database user accounts.
To provide guidance for configuring Oracle9i in a secure manner, Oracle Corporation provides a security checklist. Oracle Corporation recommends that you read this checklist and configure your database accordingly. The security checklist can be found at the following URL:
http://otn.oracle.com/deploy/security/oracle9i/pdf/9iR2_checklist.pdf
Examples
Creating a Database: Example
The following statement creates a database and fully specifies each argument:
CREATE DATABASE sample
CONTROLFILE REUSE
LOGFILE
GROUP 1 ('diskx:log1.log', 'disky:log1.log') SIZE 50K,
GROUP 2 ('diskx:log2.log', 'disky:log2.log') SIZE 50K
MAXLOGFILES 5
MAXLOGHISTORY 100
MAXDATAFILES 10
MAXINSTANCES 2
ARCHIVELOG
CHARACTER SET AL32UTF8
NATIONAL CHARACTER SET AL16UTF16
DATAFILE
'disk1:df1.dbf' AUTOEXTEND ON,
'disk2:df2.dbf' AUTOEXTEND ON NEXT 10M MAXSIZE UNLIMITED
DEFAULT TEMPORARY TABLESPACE temp_ts
UNDO TABLESPACE undo_ts
SET TIME_ZONE = '+02:00';
http://download-west.oracle.com/docs/cd/B10501_01/server.920/a96540/statements_55a.htm#SQLRF01204
Joel P�rez

Similar Messages

  • How do l create a new database in Oracle 10g Express

    How do l create a new database in Oracle 10g Express, other than the one that is created on installation?

    Hello,
    You cannot create a second XE database on the same server.
    But, Oracle database can support as many Schema as you want.
    "Oracle database" is like "SQL Server Instance" and "Oracle Schema" is like "SQL Server database". I means by this shortcut that for
    the end users accessing to different Schemas looks like accessing to different databases.
    You can have several applications on the same database. Each application has its own Schema and Datafile (Tablespace) structure.
    So on your XE database you can add a new Tablespace and create a new User/Schema as follows:
    sqlplus /nolog
    connect / as sysdba
    create tablespace {color:red}new_tablespace_name{color}
    extent management local autoallocate
    SEGMENT SPACE MANAGEMENT AUTO
    datafile '{color:red}complete_datafile_name{color}' size 100M autoextend on next 10M maxsize unlimited;
    create user {color:red}new_schema_name{color} identified by {color:red}password{color}
    default tablespace {color:red}new_tablespace_name{color}
    temporary tablespace TEMP
    quota unlimited on {color:red}new_tablespace_name{color}
    grant connect, resource to {color:red}new_schema_name{color};Then you can connect to this new User/Schema as you defined it and create your new structure and load datas.
    Hope it can help.
    Best regards,
    Jean-Valentin

  • How i can Create Master Repository with MySQL Database?

    How i can Create Master Repository with MySQL Database? i need to using MySQL Database to Master & Work Repository.
    I try to add mysql libary jar file to drivers . But , can't display MySQL Technology in Database List for Create Master Repository ?
    Please..
    Edited by: MadoatZ on Feb 19, 2011 1:47 AM

    Creation of ODI master repository is limited to few relational databases only. Check certification matrix for ODI 11g
    Oracle 10.2.0.4+
    Oracle 11.1.0.7+
    Oracle 11.2.0.1+
    Microsoft SQL Server 2005
    Microsoft SQL Server 2008
    IBM DB2/UDB 9.7 and later FixPaks
    IBM DB2/400 (V5R4+)
    Hypersonic SQL 1.7.3+
    Sybase AS Enterprise 15.0.x
    thanks

  • Inserting files in to Oracle 8i database through JDBC - Only 4k data file

    Hi,
    I need to insert a files(images or excel files, doc files etc..) in to oracle 8i database through JDBC program. But i am not able to store more than 4k data files in to files. can any body give me solutions regarding this.
    My code is like this...
    String fileName ="Sample.jpg";
                                  String dataSource = "jdbc/oracle";
                   File file=null;
                   FileInputStream fis = null;
                   Context initCtx=null;
                   DataSource ds = null;
                   Connection con = null;
                   try
                        initCtx = new InitialContext();
                        ds = (DataSource)initCtx.lookup(dataSource);
                        con = ds.getConnection();
                      try
                         file = new File(fileName);
                         fis = new FileInputStream(file);
                        catch(FileNotFoundException fe)
                             out.println("File Not Found");
                                            PreparedStatement pstmt = con.prepareStatement("insert into bfiles values(?,?)");
                        pstmt.setString(1, fileName);
                        pstmt.setBinaryStream(2, fis, (int)file.length());
                        pstmt.executeUpdate();
                        out.println("Inserted");
                        fis.close();
                        pstmt.close();
                        con.close();
                        out.println("closed");
                   catch(Exception e)
                        out.println(e);
               }     in Oracle bi i have created a table like this :
    CREATE TABLE BFILES
      FILENAME     VARCHAR2(100)                    DEFAULT NULL,
      FILECONTENT  BLOB                             DEFAULT EMPTY_BLOB()
    )Please help me ourt to solve this problem.
    i got struck in this problem.
    its urgent
    thanks in advance
    djshivu

    Hi Shanu.
    Thanks for your help...
    By Using THIN driver also we can insert any files more than 4k and and retrive same. Fallowing codes worked fine for me using thin Driver .
    Following are the 2 programs to write and read.
    we can insert and retrieve any format of files ( jpg, gif, doc, xsl, exe, etc...)
    =======================================================
    // Program to insert files in to table
    import oracle.jdbc.driver.*;
    import oracle.sql.*;
    import java.sql.*;
    import java.io.*;
    import java.awt.image.*;
    import java.awt.*;
    * @author  Shivakumar D.J
    * @version
    public class WriteBlob{
    public static void main(String[] args){
    String filename = "018-Annexure-A.xls";
    Connection conn = null;
    try{
        Class.forName("oracle.jdbc.driver.OracleDriver");
        conn=DriverManager.getConnection("jdbc:oracle:thin:@test:1521:orcl","modelytics","modelytics");
        conn.setAutoCommit(false);
        Statement st = conn.createStatement();
        int b= st.executeUpdate("insert into bfiles values('"+filename+"', empty_blob())");
        ResultSet rs= st.executeQuery("select * from bfiles for update");
        rs.next();
        BLOB blob=((oracle.jdbc.driver.OracleResultSet)rs).getBLOB(2);
        FileInputStream instream = new FileInputStream(filename);
        OutputStream outstream = blob.getBinaryOutputStream();
        int chunk = blob.getChunkSize();
        byte[] buff = new byte[chunk];
        int le;
        while( (le=instream.read(buff)) !=-1)
            outstream.write(buff,0,le);
        instream.close();
        outstream.close();
        conn.commit();
        conn.close();
        conn = null;
        System.out.println("Inserted.....");
       catch(Exception e){
            System.out.println("exception"+e.getMessage());
            e.printStackTrace();
       }//catch
    }=======================
    // Program to retrieve files from database
    [import java.sql.*;
    import java.io.*;
    import java.awt.*;
    public class ReadImage
    public static void main(String a[])
        String fileName ="018-Annexure-A.xls";
        try
              Driver driver = new oracle.jdbc.driver.OracleDriver();
              DriverManager.registerDriver(driver);
              Connection con = DriverManager.getConnection("jdbc:oracle:thin:@test:1521:orcl", "modelytics", "modelytics");
            File file = new File("C:/Documents and Settings/USERID/Desktop/dump.xls");
              FileOutputStream targetFile=  new FileOutputStream(file); // define the output stream
              PreparedStatement pstmt = con.prepareStatement("select filecontent from bfiles where filename= ?");
              pstmt.setString(1, fileName);
               ResultSet rs = pstmt.executeQuery();
               rs.next();
               InputStream is = rs.getBinaryStream(1);
              byte[] buff = new byte[1024];
               int i = 0;
               while ((i = is.read(buff)) != -1) {
                    targetFile.write(buff, 0, i);
                   System.out.println("Completed...");
            is.close();
            targetFile.close();
            pstmt.close();
           con.close();
        catch(Exception e)
              System.out.println(e);
    }====================
    Table Structure is like this
    CREATE TABLE BFILES
      FILENAME     VARCHAR2(100)                    DEFAULT NULL,
      FILECONTENT  BLOB                             DEFAULT EMPTY_BLOB()
    )========================================================
    i hope above codes will helpful for our future programmers
    thanks shanu...
    regards
    djshivu...(javashivu)

  • ATG 10.1 How we can create user segment programitically

    Hi,
    I want to create user segment programitically, not through BCC.
    Rule for the segment I will be getting from some third party. I have to create rule for my segment programitically and assign the user segment to a profile group.
    I checked the user properties and got to know as for every profile user segments will be assigned as a dynamic property.
    How I can create the same programitically after getting the rule from third party.
    Thanks in advance
    Agil

    >Why (no body) help me?.
    >Is my question not clear?
    Yes, your question is not clear.
    >
    http://www.libyabuild.com/news1.htm
    Is that one of the pages on your site? Do you just want to
    add a feature that searches your site for relevant content? If so,
    check out
    http://www.wrensoft.com/zoom/support/dreamweaver.html
    So I don't understand why you are asking about a database -
    are you trying generate results that link to other sites?

  • Newbie....  How do I create a new database in mysql????

    I have added the mysql service, but I have no idea where the front end is, or how to access it so that I can create a new database, and set the user name and PW for this database??? I am used to using things like MAMP and XAMP, where it has the web front end. Does OSX server have the same thing? I want to configure a test Joomla test site.... Thank you...

    There's no built-in GUI for managing MySQL in Mac OS X, but you're free to install any of the MySQL tools to do so if you're not up to managing it via the command line.
    There's the free PHPMyAdmin, or the commercial NaviCat, amongst others.

  • How I can create view with parameters?

    I have very big query (2000 rows) and 2 parameters.
    How I can create view with parameters?

    If I use this small part of my query than I have error :
    java.lang.NullPointerException
         at oracle.javatools.db.ora.OracleSQLQueryBuilder.buildQuery(OracleSQLQueryBuilder.java:199)
         at oracle.javatools.db.ora.OracleSQLQueryBuilder.buildQuery(OracleSQLQueryBuilder.java:147)
    What does it means?
    select
    ' Payroll ' as Revenue
    , t.umonth, nvl(p.hmy, 0), nvl(t.sMTD, 0), nvl(a.inormalbalance, 0), nvl(T.sbudget, 0), nvl(a.scode, 0)
    from
    acct a, total t, property p, param par
    where
    nvl(t.hacct, 0) = nvl(a.hmy, 0)
    and nvl(par.hretain, 0) <> nvl(a.hmy, 0)
    and nvl(t.iBook, 0) = 0
    and nvl(a.iacctType, 0) = 0 /*Regular accts*/
    and nvl(t.hppty, 0) = nvl(p.hmy, 0)
    and ( nvl(a.scode, 0) between 60000 and 6009000 )
    union all ---------------------------------------------------------------------------------------------------------------------------------
    select
    ' Payroll Taxes '
    , t.umonth, nvl(p.hmy, 0), nvl(t.sMTD, 0), nvl(a.inormalbalance, 0), nvl(T.sbudget, 0), nvl(a.scode, 0)
    from
    acct a, total t, property p, param par
    where
    nvl(t.hacct, 0) = nvl(a.hmy, 0)
    and nvl(par.hretain, 0) <> nvl(a.hmy, 0)
    and nvl(t.iBook, 0) = 0
    and nvl(a.iacctType, 0) = 0 /*Regular accts*/
    and nvl(t.hppty, 0) = nvl(p.hmy, 0)
    and
    (nvl(a.scode, 0) between 60100 and 60690 )
    union all -------------------------------------------------------------------------------------------------------------------------------
    select
    ' Workers Comp/Disability '
    , t.umonth, nvl(p.hmy, 0), nvl(t.sMTD, 0), nvl(a.inormalbalance, 0), nvl(T.sbudget, 0), nvl(a.scode, 0)
    from
    acct a, total t, property p, param par
    where
    nvl(t.hacct, 0) = nvl(a.hmy, 0)
    and nvl(par.hretain, 0) <> nvl(a.hmy, 0)
    and nvl(t.iBook, 0) = 0
    and nvl(a.iacctType, 0) = 0 /*Regular accts*/
    and nvl(t.hppty, 0) = nvl(p.hmy, 0)
    and
    ( nvl(a.scode, 0) between 61200 and 61260)
    union all -------------------------------------------------------------------------------------------------------------------------------
    select
    ' Pension and Hospitalization '
    , t.umonth, nvl(p.hmy, 0), nvl(t.sMTD, 0), nvl(a.inormalbalance, 0), nvl(T.sbudget, 0), nvl(a.scode, 0)
    from
    acct a, total t, property p, param par
    where
    nvl(t.hacct, 0) = nvl(a.hmy, 0)
    and nvl(par.hretain, 0) <> nvl(a.hmy, 0)
    and nvl(t.iBook, 0) = 0
    and nvl(a.iacctType, 0) = 0 /*Regular accts*/
    and nvl(t.hppty, 0) = nvl(p.hmy, 0)
    and
    ( nvl(a.scode, 0) between 61000 and 61550 )
    union all -------------------------------------------------------------------------------------------------------------------------------
    select
    ' Other Labor Costs '
    , t.umonth, nvl(p.hmy, 0), nvl(t.sMTD, 0), nvl(a.inormalbalance, 0), nvl(T.sbudget, 0), nvl(a.scode, 0)
    from
    acct a, total t, property p, param par
    where
    nvl(t.hacct, 0) = nvl(a.hmy, 0)
    and nvl(par.hretain, 0) <> nvl(a.hmy, 0)
    and nvl(t.iBook, 0) = 0
    and nvl(a.iacctType, 0) = 0 /*Regular accts*/
    and nvl(t.hppty, 0) = nvl(p.hmy, 0)
    and
    ( nvl(a.scode, 0) between 616000 and 616400 )

  • How to exclude create oracle job when during oracle imp

    Hi Expert,
    I would like to know how to exclude create oracle job during oracle import . It is schema export. Tks
    Regard
    Liang

    Oracle attempts to reimport job definitions as well. However, if you have an existing job with the same JOB_ID, the job definition fails (as there is a Unique Constraint on it).
    So, one "workaround" is to precreate dummy jobs before the import (which also means that the database account must be created in advance). To ensure that the JOB_ID is the same, you may have to keep incrementing the JOB_ID sequence.
    Hemant K Chitale

  • How i can create animated slide show?

    How i can create animated slide show to my web sites listed bellow? Is Adobe PS suitble for it ?
    My websites are
    http://insurance-helpz.blogspot.com/
    http://www.autoinsurance-helpz.blogspot.com/
    You knowladge will help me to develop my sites with attractive slide show
    Thank you

    JJMack covers some possibilities, predicated on the embedded player in your Web site.
    You might want to look at another pair of Adobe programs, that work well together: Adobe Premiere Elements and Photoshop Elements. They are available in a bundle, and, if you do not have Photoshop Extended (up through CS 5.5), or Ps CS 6, or Ps CC, they cost MUCH less.
    One can create the SlideShow in the Organizer (sort of like Bridge, but with some differences), then can Send to Premiere Elements for final editing, such as the addition of Narration, or a Soundtrack. From PrE, one can then output to many, many different formats for linking to the player on the Web site.
    Now, if you have Ps Extended, Ps CS 6, or Ps CC already, you have video-editing capabilities, but some of the output options (and even Import options), will be limited.
    If searching for a program (or bundle of programs), then the Elements duo will do exactly what you need. Also, both of those programs have their own, very active forums, so you will have two communities to offer you support.
    Good luck,
    Hunt

  • I have only oradata folder. how i can create orapwd file.

    i have oracle 8.1.7 installed on oracle 2000 professional. my harddisk crashed but i have oradata file only.
    how i can create orapwd from that
    thanks and regard
    Rizwan

    user4305377 wrote:
    i have oracle 8.1.7 installed on oracle 2000 professional. my harddisk crashed but i have oradata file only.
    how i can create orapwd from that
    thanks and regardRizwan
    You don't need oradata folder to create the password file. All you need is the orapwd util to create it. Just do as follows,
    E:\>orapwd
    Usage: orapwd file=<fname> password=<password> entries=<users> force=<y/n>
      where
        file - name of password file (mand),
        password - password for SYS (mand),
        entries - maximum number of distinct DBA and     force - whether to overwrite existing file (opt),
    OPERs (opt),
      There are no spaces around the equal-to (=) character.
    E:\>orapwd file=<your file location> password=<your password here> enteries=5 force=NOracle would create the password file for you in the Databsae folder.
    HTH
    Aman....

  • How i can create menus

    Dear All
    How i can create my own menus with security issues.
    Rai

    You can create your own area menus using SE43.
    In SE43, cerate a new menu like z_test_menu.
    Further, use the toolbar option , add entry as subnode, to include your transactions.
    Basis Activity -
    Further, you can attach this area menu with the roles through Xn PFCG. And users can be assigned to this role.
    So only the users who have been assigned the role which contains this new area menu will be able to see this area menu.
    Thanks,
    Ram

  • I would like to know how i can create a bell graph with out using sub VIs, the data that i created consists in 500 readings with values of 0 to 100, i calculated the mean value and standard diviation. I hope some one can help me

    I would like to know how i can create a bell graph with out using sub VIs, the data that i created consists in 500 readings with values of 0 to 100, i calculated the mean value and standard diviation. I hope some one can help me

    Here's a quick example I threw together that generates a sort-of-bell-curve shaped data distribution, then performs the binning and plotting.
    -Kevin P.
    Message Edited by Kevin Price on 12-01-2006 02:42 PM
    Attachments:
    Binning example.vi ‏51 KB
    Binning example.png ‏12 KB

  • How I can create a XML file from java Aplication

    How I can create a XML file from java Aplication
    whith have a the following structure
    <users>
    <user>
    <login>anyName</login>     
    <password>xxxx</password>
    </user>
    </users>
    the password label must be encripted
    accept any suggestion

    Let us assume you have all the data from the jsp form in an java bean object..
    Now you want a xml file. This can be acheived in 2 ways
    1. Write it into a file using java.io classes. Say you have a class with name
    write("<name>"+obj.getName+</name>);
    bingo you have a flat file with the xml
    2. Use data binding to do the trick
    will recommend JiBx and Castor for the 2nd option
    Regards,
    Rajagopal

  • Can't startup the database through "isqlplusdba"

    I have connectd as sysdba to the oracle 9i database through iSQLPLUSDBA. My database was initially in started mode. Then I did a normal shutdown(successfully).
    But When I try to startup it gives me following error.
    LRM-00101: unknown parameter name 'db_cache_size' LRM-00101: unknown parameter name 'dispatchers' LRM-00101: unknown parameter name 'fast_start_mttr_target' LRM-00101: unknown parameter name 'pga_aggregate_target' LRM-00101: unknown parameter name 'undo_management' LRM-00101: unknown parameter name 'undo_retention' LRM-00101: unknown parameter name 'undo_tablespace' ORA-01078: failure in processing system parameters

    Hi,
    I am having exactly the same problem:
    SQL> startup nomount pfile='D:\oracle\admin\MYDB\pfile\initmydb.ora'
    LRM-00101: unknown parameter name 'db_cache_size'
    LRM-00101: unknown parameter name 'dispatchers'
    LRM-00101: unknown parameter name 'fast_start_mttr_target'
    LRM-00101: unknown parameter name 'pga_aggregate_target'
    LRM-00101: unknown parameter name 'undo_management'
    LRM-00101: unknown parameter name 'undo_retention'
    LRM-00101: unknown parameter name 'undo_tablespace'
    ORA-01078: failure in processing system parameters
    SQL>
    This is my "ini" file:
    *.aq_tm_processes=1
    *.background_dump_dest='d:\oracle\admin\mydb\bdump'
    *.compatible='9.2.0.0.0'
    *.control_files='d:\oracle\oradata\mydb\control01.ctl','d:\oracle\oradata\mydb\control02.ctl','d:\oracle\oradata\mydb\control03.ctl'
    *.core_dump_dest='d:\oracle\admin\mydb\cdump'
    *.db_block_size=8192
    *.db_cache_size=629145600
    *.db_domain='skmconsulting.com'
    *.db_file_multiblock_read_count=16
    *.db_name='mydb'
    *.dispatchers='(PROTOCOL=TCP)'
    *.fast_start_mttr_target=300
    *.hash_join_enabled=TRUE
    *.instance_name='mydb'
    *.java_pool_size=33554432
    *.job_queue_processes=10
    *.large_pool_size=8388608
    *.log_archive_format='arch_mydb_%t_%s.arc'
    *.log_archive_dest = D:\oracle\archive-logs\mydb
    *.log_archive_start=TRUE
    *.max_enabled_roles=148
    *.open_cursors=500
    *.optimizer_mode='rule'
    *.pga_aggregate_target=25165824
    *.processes=200
    *.query_rewrite_enabled='FALSE'
    *.remote_login_passwordfile='EXCLUSIVE'
    *.shared_pool_size=83886080
    *.sort_area_size=524288
    *.star_transformation_enabled='FALSE'
    *.timed_statistics=TRUE
    *.undo_management='AUTO'
    *.undo_retention=10800
    *.undo_tablespace='UNDOTBS1'
    *.user_dump_dest='d:\oracle\admin\mydb\udump'
    Any ideas?
    Thanks.

  • Does anyone know how I can create a text field in a pdf document that will multiply a total in another box?

    does anyone know how I can create a text field in a pdf document that will multiply a total in another box? I’m making an interactive pdf for an order form (attached), and I need to find a way for the “total quantity” number to multiply by 9 and total in the “Amount Due” box.

    Hey Gary,
    Have a look at this post: Re: horizontal scrolling similar to excel
    Andy's reply will show you how to make a table scroll horizontally, but it will be tough to accomplish it in some sort of easily replicable way. I am working on a JQuery extension that will help accomplish this, but I have had my time invested in another project at the moment.
    Good Luck,
    Tyson

Maybe you are looking for