How to insert the value

i want to ask u all.
what is the code for insert he value?
i mean in double

what is the code to insert value
example:
int base=Integer.parseInt(args[0]);
my question is how i make coding for double

Similar Messages

  • How to insert the value axis in a EXCEL graph

    Hello,
    how can I do to insert the value axis (name) and graph tilte in a EXCEL graph using report generation in LabVIEW??
    I'm using excel specific functions, but I don't find it anywhere.
    THANKS.

    Hi,
    the function Excel Set Graph Font.vi has an input parameter called Title that corresponds to the name of the axis selected through Axis Type parameter.
    And the funtion Excel Insert Graph.vi has an input parameter called Graph Title.
    You can see an example called Column Graph (Excel).vi in Find Examples>Toolkits and Modules>Report Generation.

  • How i insert the values in JTable

    Hi,
    Iam new to the swings i have a problem placing the values in JTable while retriving the values from DataBase .Anybody please suggest me..
    i can retriving the values but how i place the vlaues..
    This is My code
    package com.teamone.healthcare;
    import java.awt.event.ActionEvent;
    import java.awt.event.ActionListener;
    import java.sql.DriverManager;
    import java.sql.Statement;
    import javax.swing.JButton;
    import javax.swing.JScrollPane;
    import javax.swing.JTable;
    import javax.swing.WindowConstants;
    import javax.swing.table.DefaultTableModel;
    import javax.swing.table.TableModel;
    import com.mysql.jdbc.Connection;
    import com.mysql.jdbc.ResultSet;
    * This code was edited or generated using CloudGarden's Jigloo
    * SWT/Swing GUI Builder, which is free for non-commercial
    * use. If Jigloo is being used commercially (ie, by a corporation,
    * company or business for any purpose whatever) then you
    * should purchase a license for each developer using Jigloo.
    * Please visit www.cloudgarden.com for details.
    * Use of Jigloo implies acceptance of these licensing terms.
    * A COMMERCIAL LICENSE HAS NOT BEEN PURCHASED FOR
    * THIS MACHINE, SO JIGLOO OR THIS CODE CANNOT BE USED
    * LEGALLY FOR ANY CORPORATE OR COMMERCIAL PURPOSE.
    public class ClientList extends javax.swing.JFrame {
         private static final long serialVersionUID = 1L;
         private JScrollPane list;
         private JButton view;
         private JButton close;
         private JTable jTable1;
         Connection con = null;
        Statement st = null;
        ResultSet rs = null;
         * Auto-generated main method to display this JFrame
         /*public static void main(String[] args) {
              ClientList inst = new ClientList();
              inst.setVisible(true);
         public ClientList() {
              super();
              initGUI();
              this.setVisible(true);
         private void initGUI() {
              try {
                        list.setBounds(161, 133, 371, 98);
                        list.getHorizontalScrollBar().setPreferredSize(new java.awt.Dimension(10, 59));
                   setDefaultCloseOperation(WindowConstants.DISPOSE_ON_CLOSE);
                   getContentPane().setLayout(null);
              try {
                    Class.forName("com.mysql.jdbc.Driver").newInstance();
                    con = (Connection) DriverManager.getConnection("jdbc:mysql:///healthcare","yenmad","yenmad");
                    st = con.createStatement();
                    rs = (ResultSet) st.executeQuery("SELECT User_id, Username, Citizen_ID, First_Name, Phone FROM register_users");
                    while(rs.next()) {
                      int Userid = rs.getInt(1);
                      String Username = rs.getString(2);
                      String ClientId = rs.getString(3);
                      String ClientName = rs.getString(4);
                      //String Last_Name = rs.getString(5);
                      String ContactNumber = rs.getString(5);
                      System.out.println(Userid + ", " + Username + ", " +ClientId  + "," + ClientName +","+ContactNumber);
                  } catch (Exception e) {
                       System.out.println("Exception: " + e.getMessage());
                        list = new JScrollPane();
                        getContentPane().add(list);
                        list.setBounds(0, 0, 644, 217);
                             TableModel jTable1Model = new DefaultTableModel(
                                  new String[][] { { "", "", "","", "" } },
                                  new String[]{ "UserId", "UserName", "ClientId", "ClientName", "ContactNumber"});
                             jTable1 = new JTable();
                             list.setViewportView(jTable1);
                             jTable1.setModel(jTable1Model);
                        close = new JButton();
                        getContentPane().add(close);
                        close.setText("Close");
                        close.setBounds(518, 231, 63, 28);
                        view = new JButton();
                        getContentPane().add(view);
                        view.setText("View");
                        view.setBounds(441, 231, 63, 28);
                        view.addActionListener(new ActionListener() {
                             public void actionPerformed(ActionEvent evt) {
                                  viewActionPerformed(evt);
                   pack();
                   this.setSize(652, 300);
              } catch (Exception e) {
                   e.printStackTrace();
         private void viewActionPerformed(ActionEvent evt) {
              System.out.println("view.actionPerformed, event=" + evt);
              new ViewClient();
    }

    can i display this table values in vertical .. if yes how can i do that.. please suggest me..
    this is the code iam using but it is displa in horizontally...
    package com.teamone.healthcare;
    import java.awt.BorderLayout;
    import java.awt.event.ActionEvent;
    import java.awt.event.ActionListener;
    import java.sql.DriverManager;
    import java.util.Vector;
    import javax.swing.JButton;
    import javax.swing.JPanel;
    import javax.swing.JScrollPane;
    import javax.swing.JTable;
    import javax.swing.WindowConstants;
    import com.mysql.jdbc.Connection;
    import com.mysql.jdbc.ResultSet;
    import com.mysql.jdbc.ResultSetMetaData;
    import com.mysql.jdbc.Statement;
    public class ClientList extends javax.swing.JFrame {
         private static final long serialVersionUID = 1L;
         /*public static void main(String[] args) {
              ClientList inst = new ClientList();
              inst.setVisible(true);
         public ClientList() {
              super();
              initGUI();
              this.setVisible(true);
         private void initGUI() {
              try {
                   setDefaultCloseOperation(WindowConstants.DISPOSE_ON_CLOSE);
                   pack();
                   setSize(600, 500);
                   Vector columnNames = new Vector();
                Vector data = new Vector();
                try
                          this.setSize(500, 400);
                      //  Connect to the Database
                      Class.forName("com.mysql.jdbc.Driver");
                      Connection connection = (Connection) DriverManager.getConnection("jdbc:mysql:///healthcare","yenmad","yenmad" );
                      //  Read data from a table
                      String sql = "Select User_id, Username, Citizen_ID, First_Name, Last_Name, Phone from register_users";
                      Statement stmt = (Statement) connection.createStatement();
                      ResultSet rs = (ResultSet) stmt.executeQuery( sql );
                      ResultSetMetaData md = (ResultSetMetaData) rs.getMetaData();
                      int columns = md.getColumnCount();
                      //  Get column names
                      for (int i = 1; i <= columns; i++)
                       columnNames.addElement( md.getColumnName(i) );
                      //  Get row data
                      while (rs.next())
                            Vector row = new Vector(columns);
                            for (int i = 1; i <= columns; i++)
                                  row.addElement( rs.getObject(i) );
                            data.addElement( row );
                      rs.close();
                      stmt.close();
                catch(Exception e)
                      System.out.println( e );
                //  Create table with database data
                JTable table = new JTable(data, columnNames);
                JScrollPane scrollPane = new JScrollPane( table );
                getContentPane().add( scrollPane );
                JPanel buttonPanel = new JPanel();
                getContentPane().add( buttonPanel, BorderLayout.SOUTH );
                buttonPanel.setPreferredSize(new java.awt.Dimension(200, 66));
                        JButton View = new JButton();
                        buttonPanel.add(View);
                        View.setText("View");
                        View.setLayout(null);
                        View.addActionListener(new ActionListener() {
                             public void actionPerformed(ActionEvent evt) {
                                  ViewActionPerformed(evt);
                        JButton Close = new JButton();
                        buttonPanel.add(Close);
                        Close.setText("Close");
                        Close.addActionListener(new ActionListener() {
                             public void actionPerformed(ActionEvent evt) {
                                  CloseActionPerformed(evt);
                        } catch (Exception e) {
                   e.printStackTrace();
         private void CloseActionPerformed(ActionEvent evt) {
              System.out.println("Close.actionPerformed, event=" + evt);
              this.setVisible(false);
         private void ViewActionPerformed(ActionEvent evt) {
              System.out.println("View.actionPerformed, event=" + evt);
              new ViewClient();
    }

  • I'm using referential costraints in table creation.how to insert the value

    Hi,
    This is the table Script.
    CREATE TABLE Trn_Invest_DividendSU(
              DividendSU_ID               NUMBER(10)     DEFAULT 0,     
                   DividendSU_LedgerType     CHAR(1)          DEFAULT ' ',
                   DividendSU_EntryDate          DATE,     
                   DividendSU_SU_Code          VARCHAR2(20)     DEFAULT ' ',     
                   Scheme_Code           VARCHAR2(20) References Mst_Invest_Scheme(Scheme_Code),
                   Share_Code           VARCHAR2(20) References Mst_Invest_Share(Share_Code),
                   DividendSU_SchemeTypeID     NUMBER(4)     DEFAULT 0,
                   InvstMaster_ID          NUMBER(4)     DEFAULT 0,
                   DividendSU_DividentDate     DATE,     
                   DividendSU_EligibleSU          NUMBER(10,5)     DEFAULT 0,
                   DividendSU_NoSUTobe     NUMBER(10,5)     DEFAULT 0,
                   DividendSU_AverageSU     NUMBER(10,5)     DEFAULT 0,
                   DividendSU_Narration          VARCHAR2(300)     DEFAULT ' ',     
                   DividendSU_BRVDate          DATE,     
                   DividendSU_DividendSU     NUMBER(5,4)     DEFAULT 0,
                   DividendSU_MJVStatus     CHAR(1)          DEFAULT ' ',
                   DividendSU_TotalDividend     NUMBER(5,4)     DEFAULT 0,
                   SalSU_Brokerage          NUMBER(3,2)     DEFAULT 0,
                   SalSU_STT          NUMBER(4,6)     DEFAULT 0,
                   DividendSU_RequestId     NUMBER(8)     DEFAULT 0,
                   DividendSU_Timestamp     VARCHAR2(25)     DEFAULT ' '
    ALTER TABLE Trn_Invest_DividendSU ADD (CONSTRAINT Trn_Inv_DivSU_DividendSUID_PK PRIMARY KEY (DividendSU_ID));
    ALTER TABLE Trn_Invest_DividendSU ADD (CONSTRAINT Trn_Inv_DivSU_SchemeType_Id_FK FOREIGN KEY (DividendSU_SchemeTypeID) REFERENCES Mst_Invest_SchemeType (SchemeType_ID));
    ALTER TABLE Trn_Invest_DividendSU ADD (CONSTRAINT Trn_Inv_DivSU_InvID_FK FOREIGN KEY (InvstMaster_ID) REFERENCES Mst_Invest_Master (InvstMaster_ID));
    ALTER TABLE Trn_Invest_DividendSU ADD CONSTRAINT Check_Id2_FK check
    ((Scheme_Code Is Null and Share_Code Is Null) OR
    (Scheme_Code Is Not Null and Share_Code Is Null) OR
    (Scheme_Code Is Null and Share_Code Is Not Null));
    Note:
    Scheme_Code is primary key in Sheme Master
    Share_Code is primary key in Share Master
    SH01 is available in Share Master.but insert statement will not accept.
    insert into TRN_Invest_DividendSU(DIVIDENDSU_ID,DIVIDENDSU_SU_CODE,SCHEME_CODE,SHARE_CODE) values (1,'SH01',null,null)
    The Following will be coming
    ORA-02291: integrity constraint (SBNPINV.TRN_INV_DIVSU_INVID_FK) violated - parent key not found
    Pls very urgent.
    Thanks,
    V.Nagarajan

    Hi,
    I can not understand the need for this constraint excatly
    ALTER TABLE Trn_Invest_DividendSU
    ADD CONSTRAINT Check_Id2_FK check(
       (Scheme_Code Is Null and Share_Code Is Null) OR
       (Scheme_Code Is Not Null and Share_Code Is Null) OR
       (Scheme_Code Is Null and Share_Code Is Not Null)
    );If I am reading it correctly, you do not want value for both Scheme_code and Share_code at the same time. Only one of the values should be present for a particular row.
    If I read it correctly, then this constraint needs to be modified so that you can specify values for both these fields in your INSERT statement.
    Thanks,
    Ankur

  • How to Insert the value in oitm table

    Dear Members,
       In Item Master, i have created a combobox next to Price List through SDK. if i select a particular value in the combobox and click Add Button in itemMaster, the selected value has to go to oitm table. i dont want to put separate table for that.any body can help me in this regard.
    Thanks in Advance

    hi,
    for eg create a field in OITM table as UDF
    TOOLS >>> UserDefinedFields >>> Manage User Fields >>> Master Data >>> Items >>> Items
    create UDF Field so that a field UDF will be created in the table OITM (Table for ItemMaster).
    Use the Following Code in ItemEvent.
    If pVal.FormType = 150 pVal.BeforeAction = False And pVal.EventType = SAPbouiCOM.BoEventTypes.et_FORM_LOAD Then
                    Try
                       Dim oitem As SAPbouiCOM.Item = SBO_Application.Forms.Item(pVal.FormUID).Items.Item("214")
                Dim oitem2 As SAPbouiCOM.Item = SBO_Application.Forms.Item(pVal.FormUID).Items.Item("107")
                Dim oitem1 As SAPbouiCOM.Item = SBO_Application.Forms.Item(pVal.FormUID).Items.Add("UserItem", SAPbouiCOM.BoFormItemTypes.it_COMBO_BOX)
                oitem1.Left = oitem2.Left
                oitem1.Width = oitem2.Width
                oitem1.Top = oitem.Top
                oitem1.Height = oitem.Height
                oitem1.LinkTo = "215"
                oitem1.Visible = True
                oitem1.DisplayDesc = True
                Dim oCombo As SAPbouiCOM.ComboBox = oitem1.Specific
                oCombo.DataBind.SetBound(True, "OITM", "U_UDF")
                oCombo.ValidValues.Add("M", "M")
                oCombo.ValidValues.Add("L", "L")
                oCombo.ValidValues.Add("E", "E")
                    Catch ex As Exception
                        SBO_Application.StatusBar.SetText(ex.Message, SAPbouiCOM.BoMessageTime.bmt_Short, SAPbouiCOM.BoStatusBarMessageType.smt_Error)
                    End Try
                End If
    after binding UDF field to Combobox it adds to database automatically on clicking add.
    regards,
    varma

  • How to insert / Update value for PFAKT in BP Relationship

    Hi Friends / Experts,
    How to insert the value for PFAKT ( Function value ) in BP Relationship in BP tcode , in SAP CRM.
    I have tried it but it BAPI_BUPR_CONTP_CREATE. But I need it with BAPI_BUPR_RELATIONSHIP_CREATE Function Module.
    Please help me out.
    Any Enhancement points in BAPI_BUPR_RELATIONSHIP_CREATE or any user exists. Please let me know.
    Regards,
    KMF.

    you can also acheive this using MERGE( available in sql 2008 and above).
    also, you are referring to DTS. DTS is legacy solution now..are you using sql 2000,  you can use ssis, if you want and it available in sql 2005. as said, there are multiple ways you can do this.. it find the below one a easy solution, since your are
    talking about only one table.. 
    try this example..
    create table test1(sno int primary key,sname varchar(20),scity varchar(20))
    go
    create table test2(sno int primary key,sname varchar(20),scity varchar(20))
    go
    insert into test1
    values(1,'stan','atlanta'),(2,'william','newyork')
    go
    insert into test2
    values(1,'robin','orlando')
    go
    --set this in you sql job and let it run for every half an hour
    MERGE test2 t2
    USING test1 t1
    ON t2.sno = t1.sno
    WHEN MATCHED THEN
    UPDATE
    SET t2.sname = t1.sname,t2.scity=t1.scity
    WHEN NOT MATCHED by target THEN
    Insert(sno,sname,scity)
    values (sno,sname,scity);
    go
    --check this table and clean up
    select * from test2
    go
    drop table test1
    go
    drop table test2
    Hope it Helps!!

  • SQL Server 2012 Management Studio: Creating a Database and a dbo Table. Inserting VALUES into the table. How to insert 8 Values for future use in XQuery?

    Hi all,
    In my SQL Server 2012 Management Studio (SSMS2012), I tried to create a Database (MacLochainnsDB) and a dbo Table (marvel). then I wanted insert 8 VALUES into the Table by using the following code:
    USE master
    IF EXISTS
    (SELECT 1
    FROM sys.databases
    WHERE name = 'MacLochlainnsDB')
    DROP DATABASE MacLochlainnsDB
    GO
    CREATE DATABASE MacLochlainnsDB
    GO
    CREATE TABLE [dbo].[marvel] (
    [avenger_name] [char] (30) NULL)
    INSERT INTO marvel
    (avenger_name)
    VALUES
    ('Hulk', 1),
    ('Iron Man', 2),
    ('Black Widow', 3),
    ('Thor', 4),
    ('Captain America', 5),
    ('Hawkeye', 6),
    ('Winter Soldier', 7),
    ('Iron Patriot', 8)
    I got the following error Message:
    Msg 110, Level 15, State 1, Line 5
    There are fewer columns in the INSERT statement than values specified in the VALUES clause. The number of values in the VALUES clause must match the number of columns specified in the INSERT statement.
    How can I correct this problem?
    Please kindly help and advise.
    Thanks in advance,
    Scott Chang
    P. S.
    The reason I tried to create the Database, dbo Table, and then to insert the VALUES is to learn the following thing:
    You can query the entire node tree with the following xquery statement because it looks for the occurrence of any node with the /* search string:
    DECLARE @x xml;
    SET @x = N'<marvel>
    <avenger_name>Captain America</avenger_name>
    </marvel>';
    SELECT @x.query('/*');
    You can query the avenger_name elements from the marvel_xml table with the following syntax:
    SELECT xml_table.query('/marvel/avenger_name')
    FROM marvel_xml;
    It returns the following set of avenger_name elements:
    <avenger_name>Hulk</avenger_name>
    <avenger_name>Iron Man</avenger_name>
    <avenger_name>Black Widow</avenger_name>
    <avenger_name>Thor</avenger_name>
    <avenger_name>Captain America</avenger_name>
    <avenger_name>Hawkeye</avenger_name>
    <avenger_name>Winter Soldier</avenger_name>
    <avenger_name>Iron Patriot</avenger_name>
    You can query the fourth avenger_name element from the marvel_xml table with the following xquery statement:
    SELECT xml_table.query('/marvel[4]/avenger_name')
    FROM marvel_xml;
    It returns the following avenger_name element:
    <avenger_name>Thor</avenger_name>

    Hi Scott,
    The master database records all the system-level information for a SQL Server system, so best practise would be not to create any user-defined
    object within it.
    To change your default database(master by default) of your login to another, follow the next steps so that next time when connected you don't have to use "USE dbname" to switch database.
    Open SQL Server Management Studio
    --> Go to Object explorer(the left panel by default layout)
    --> Extend "Security"
    --> Extend "Logins"
    --> Right click on your login, click "propertites"
    --> Choose the "Default database" at the bottom of the pop-up window.
    --or simply by T-SQL
    Exec sp_defaultdb @loginame='yourLogin', @defdb='youDB'
    Regarding your question, you can reference the below.
    SELECT * FROM master.sys.all_objects where name ='Marvel'
    --OR
    SELECT OBJECT_ID('master.dbo.Marvel') --if non empty result returns, the object exists
    --usually the OBJECT_ID is used if a if statement as below
    IF OBJECT_ID('master.dbo.Marvel') IS NOT NULL
    PRINT ('TABLE EXISTS') --Or some other logic
    What is the sys.all_objects? See
    here.
    If you have any question, feel free to let me know.
    Eric Zhang
    TechNet Community Support

  • How to insert the data from XML to a table

    Hi,
    I'm using Oracle 10g Express Edition
    I need help in How to insert the data from XML file into the table.
    Below is the example i'm working on..
    I have create ridb user with below mentioned privileges:
    Account Status Locked Unlocked
    Default Tablespace: USERS
    Temporary Tablespace: TEMP
    User Privileges :
    Roles:
    CONNECT
    RESOURCE
    Direct Grant System Privileges:
    CREATE DATABASE LINK
    CREATE MATERIALIZED VIEW
    CREATE PROCEDURE
    CREATE PUBLIC SYNONYM
    CREATE ROLE
    CREATE SEQUENCE
    CREATE SYNONYM
    CREATE TABLE
    CREATE TRIGGER
    CREATE TYPE
    CREATE VIEW
    & table is created TRIALZIPCODES below mentioned is the DDL:
    CREATE TABLE TRIALZIPCODES
    STATE_ABBR VARCHAR2(20) NOT NULL
    , ZIP_CODE NUMBER(10, 0) NOT NULL
    , ZIP_CODE_EXT VARCHAR2(20)
    Below is the XML FILE: which is stored in C:\OracleProject Folder
    File name: trial.xml
    <?xml version="1.0" ?>
    <metadata>
    - <Zipcodes>
    - <mappings Record="4">
    <STATE_ABBREVIATION>CA</STATE_ABBREVIATION>
    <ZIPCODE>94301</ZIPCODE>
    </mappings>
    - <mappings Record="5">
    <STATE_ABBREVIATION>CO</STATE_ABBREVIATION>
    <ZIPCODE>80323</ZIPCODE>
    <ZIP_CODE_EXTN>9277</ZIP_CODE_EXTN>
    </mappings>
    </Zipcodes>
    </metadata>
    PL/SQL Procedure:which i'm trying to execute from SQLDeveloper
    create or replace
    PROCEDURE TRIAL AS
    BEGIN
    DECLARE
    -- declare attributes
    charString varchar2(80);
    finalStr varchar2(4000) := null;
    rowsp integer;
    v_FileHandle UTL_FILE.FILE_TYPE;
    l_context_handle dbms_xmlgen.ctxHandle;
    insCtx DBMS_XMLStore.ctxType;
    begin
    -- DBMS_XMLGEN.setRowTag ( ctx IN ctxHandle, rowTag IN VARCHAR2);
    -- DBMS_XMLGEN.setRowSetTag ( ctx IN ctxHandle, rowSetTag IN VARCHAR2);
    -- the name of the table as specified in our DTD
    DBMS_XMLGEN.SETROWSETTAG(l_context_handle,'zipcodes');
    -- the name of the data set as specified in our DTD
    DBMS_xmlgen.setRowTag(l_context_handle,'mappings');
    -- for getting the output on the screen
    dbms_output.enable(1000000);
    -- open the XML document in read only mode
    v_FileHandle := utl_file.fopen('c:/OracleProject','trial.xml', 'r');
    loop
    BEGIN
    utl_file.get_line(v_FileHandle, charString);
    exception
    when no_data_found then
    utl_file.fclose(v_FileHandle);
    exit;
    END;
    dbms_output.put_line(charString);
    if finalStr is not null then
    finalStr := finalStr || charString;
    else
    finalStr := charString;
    end if;
    end loop;
    -- for inserting the XML data into the table
    insCtx := DBMS_XMLSTORE.NEWCONTEXT('RIDB.TRIALZIPCODES');
    insCtx := DBMS_XMLSTORE.INSERTXML(insCtx, finalStr);
    dbms_output.put_line('INSERT DONE '||TO_CHAR(rowsp));
    DBMS_XMLStore.closeContext(insCtx);
    END;
    END TRIAL;
    For the first time when i complied i got the errors as :
    Procedure RIDB.PROCEDURE1@RIDB
    Error(16,14): PLS-00201: identifier 'UTL_FILE' must be declared
    Error(16,14): PL/SQL: Item ignored
    Error(29,1): PLS-00320: the declaration of the type of this expression is incomplete or malformed
    Error(29,1): PL/SQL: Statement ignored
    Error(33,1): PL/SQL: Statement ignored
    Error(33,19): PLS-00320: the declaration of the type of this expression is incomplete or malformed
    Error(36,1): PL/SQL: Statement ignored
    Error(36,17): PLS-00320: the declaration of the type of this expression is incomplete or malformed
    So i logged in as sys & grant the permission to execute on UTL_FILE to ridb (user):
    SQL Statement:
    grant execute on utl_file to ridb
    So, it got compiled successfully but when i execute it gives me error as:
    Source does not have a runnable target.
    What does this mean?
    So I browse through forum & i got to know that i need to initial the UTL_FILE_DIR ="C:/OracleProject" in init.ora
    So can i edit the init.ora with notepad.When i tried to do that it says permission denied
    In my system it shows the init.ora file in path C:\oraclexe\app\oracle\product\10.2.0\server\config\scripts
    but there is also other file initXETemp in the same path do i need to do the changes in it.
    I have tried even editing the SPFILE as mentioned below:
    C:\oraclexe\app\oracle\product\10.2.0\server\dbs\SPFILEEXE - I had edit this file using notepad & set the value of UTL_FILE_DIR ="C:/OracleProject". So next time when i restarted i'm unable to log on to the database.
    So i had reinstall the software again.
    Could you please let me know how to proceed..

    hi,
    I have created the directory from sys database
    CREATE or replace DIRECTORY XML_DIR2 AS 'C:\OracleProject';
    & grant read,write access to the user
    grant read,write on directory XML_DIR2 to RIDB;
    & i had change the tag name in the xml file as shown below:
    <?xml version = '1.0'?>
    <metadata>
    <Zipcodes>
    <mappings Record="4">
    <STABBRE>CA</STABBRE>
    <ZIPCODE>94301</ZIPCODE>
    </mappings>
    <mappings Record="5">
    <STABBRE>CO</STABBRE>
    <ZIPCODE>80323</ZIPCODE>
    <ZIPCODEEXT>9277</ZIPCODEEXT>
    </mappings>
    </Zipcodes>
    </metadata>
    TRIALZIPCODE table as shown below:
    CREATE TABLE "RIDB"."TRIALZIPCODE"
    (     "STABBRE" VARCHAR2(20 BYTE),
         "ZIPCODE" NUMBER(*,6) NOT NULL ENABLE,
         "ZIPCODEEXT" NUMBER
    ) PCTFREE 10 PCTUSED 40 INITRANS 1 MAXTRANS 255 NOCOMPRESS LOGGING
    STORAGE(INITIAL 65536 NEXT 1048576 MINEXTENTS 1 MAXEXTENTS 2147483645
    PCTINCREASE 0 FREELISTS 1 FREELIST GROUPS 1 BUFFER_POOL DEFAULT)
    TABLESPACE "USERS" ;
    I have tried two methods as shown below:
    Procedure 1:
    create or replace
    PROCEDURE TRIAL_V2 AS
    BEGIN
    DECLARE
    -- declare attributes
    charString varchar2(80);
    finalStr varchar2(4000) := null;
    rowsp integer;
    v_FileHandle UTL_FILE.FILE_TYPE;
    l_context_handle dbms_xmlgen.ctxHandle;
    insCtx DBMS_XMLStore.ctxType;
    cnt NUMBER;
    xmldoc xmltype := xmltype( bfilename('XML_DIR2','trialxml.xml'), nls_charset_id('AL32UTF8') );
    --XML_DIR VARCHAR2(40) := 'C:\\OracleProject';
    BEGIN
    insCtx := DBMS_XMLStore.newContext('DEV.TRIALZIPCODES');
    DBMS_XMLStore.setUpdateColumn(insCtx, 'STABBRE');
    DBMS_XMLStore.setUpdateColumn(insCtx, 'ZIPCODE');
    DBMS_XMLStore.setUpdatecolumn(insCtx, 'ZIPCODEEXT');
    DBMS_XMLStore.setRowTag(insCtx, 'mappings');
    cnt := DBMS_XMLStore.insertXML(insCtx, xmldoc);
    DBMS_XMLStore.closeContext(insCtx);
    END;
    Procedure 1 was compiled with out errors but when i execute i got the error as :
    Source does not have a runnable target.
    Procedure 2_
    CREATE OR REPLACE PROCEDURE TRIAL_V3 AS
    BEGIN
    DECLARE
    -- declare attributes
    charString varchar2(80);
    finalStr varchar2(4000) := null;
    rowsp integer;
    v_FileHandle UTL_FILE.FILE_TYPE;
    l_context_handle dbms_xmlgen.ctxHandle;
    insCtx DBMS_XMLStore.ctxType;
    cnt NUMBER;
    xmldoc xmltype := xmltype( bfilename('XML_DIR2','trialxml.xml'), nls_charset_id('AL32UTF8') );
    --XML_DIR VARCHAR2(40) := 'C:\\OracleProject';
    BEGIN
    INSERT INTO trialzipcode (STABBRE, ZIPCODE, ZIPCODEEXT)
    SELECT extractvalue(x.column_value, 'mappings/STABBRE'),
    extractvalue(x.column_value, 'mappings/ZIPCODE'),
    extractvalue(x.column_value, 'mappings/ZIPCODEEXT')
    FROM TABLE(
    XMLSequence(
    EXTRACT(
    xmltype( bfilename('XML_DIR2','trialxml.xml'), nls_charset_id('AL32UTF8') ),
    'metadata/Zipcodes/mappings'
    ) x
    END;
    END TRIAL_V3;
    Procedure 2 was complied without errors but when i execute i got the error as:
    Connecting to the database RIDB.
    ORA-22288: file or LOB operation FILEOPEN failed
    The system cannot find the file specified.
    ORA-06512: at "SYS.DBMS_LOB", line 523
    ORA-06512: at "SYS.XMLTYPE", line 287
    ORA-06512: at "RIDB.TRIAL_V3", line 12
    ORA-06512: at line 2
    Process exited.
    Disconnecting from the database RIDB.
    Could you please let me know how to proceed...

  • How to insert a value from sequence in Bussiness Components?

    How to insert a value from sequence in Bussiness Components?
    I would like to do it, but without a triger that would do it before insert.
    I know that there is a type DBSequence in BC where you can insert a sequence name but it does not work when I type there my sequence name.
    Do you now how to fix that problem?
    Bart.

    The newer way to do it is to make the type DBSequence and enter the name of the Sequence object in the sequence field. It must match the same name of the sequence object in the database. Next, you have to create a before insert for each row trigger on the table. Basically, something like this:
    CREATE OR REPLACE TRIGGER TGB_THEME_SEQ
    BEFORE INSERT ON THEME
    FOR EACH ROW
    DECLARE
    BEGIN
    -- Assign the id from the sequence if null
         IF( :new.theme_id IS NULL ) THEN
              SELECT THEME_ID_SEQ.nextval
              INTO :new.theme_id
              FROM dual;
         END IF;
    END;
    In the above example, THEME_ID_SEQ is the seuence object name in the database. If you have the name right but it still fails, then the user you are logging in as probably doesn't have access to the sequence in the database.
    Hope this helps.
    Erik

  • How to insert the data even the trigger returned null

    Hi Gurus,
    I have a question regarding on how to insert the record even the condition being used by a "before insert trigger" returned null.
    The scenario is:
    2 tables have the same structure:
    Table A (Name varchar2 (100), No Number)
    Table B (Name_1 varchar2 (100), No Number)
    A script is using to load the data into table A daily, and a “before insert trigger” is being used to get the value for A.Name = B.Name whenever the condition A.No equals to B.No.
    If the B.No exists, then the trigger work fine, otherwise the records will be rejected, this is not the way we wanted, so I just wonder, is there any way to load all the data to the other fields but still using this trigger ?
    Thanks,
    Tran

    Either amend the select in the trigger that gets the name value to not raise a NO_DATA_FOUND exception (e.g. change "select name..." to "select min(name)..." ) or handle the NO_DATA_FOUND exception in an exception handler.
    e.g.
    EXCEPTION
      WHEN no_data_found THEN
        :new.name = 'where the streets have no name';

  • How to retrieve the value of last identity has been updated in a database?

    how to retrieve the value of last identity has been updated in a database

    Hi,
    Oracle 10g, FGA - Fine grained auditing, supports DML statements (9i only select).
    Set up FGA using the DBMS_FGA.ADD_POLICY procudure:
    sql> BEGIN
    DBMS_FGA.ADD_POLICY (
    policy_name => 'AUD_EMPLOYEE_SAL',
    object_schema => 'HR',
    object_name => 'EMPLOYEE',
    audit_column => SALARY',
    audit_condition => '',
    statement_type => 'UPDATE');
    END;
    NEXT:
    sql> SELECT dbuid, lsqltesxt FROM sys.fga_logs$;
    The database inserts the audit record into the FGA_LOG$ table using an autonomous transaction; even if you roll back the update statement, the update action will still be logged in this table. The fga_log$ tracks the session, machine id, timestamp, schema, scn, etc:
    SQL> desc fga_log$
    Name Null? Type
    SESSIONID NOT NULL NUMBER
    TIMESTAMP# DATE
    DBUID VARCHAR2(30)
    OSUID VARCHAR2(255)
    OSHST VARCHAR2(128)
    CLIENTID VARCHAR2(64)
    EXTID VARCHAR2(4000)
    OBJ$SCHEMA VARCHAR2(30)
    OBJ$NAME VARCHAR2(128)
    POLICYNAME VARCHAR2(30)
    SCN NUMBER
    SQLTEXT VARCHAR2(4000)
    LSQLTEXT CLOB
    SQLBIND VARCHAR2(4000)
    COMMENT$TEXT VARCHAR2(4000)
    PLHOL LONG
    STMT_TYPE NUMBER
    NTIMESTAMP# TIMESTAMP(6)
    PROXY$SID NUMBER
    USER$GUID VARCHAR2(32)
    INSTANCE# NUMBER
    PROCESS# VARCHAR2(16)
    XID RAW(8)
    AUDITID VARCHAR2(64)
    STATEMENT NUMBER
    ENTRYID NUMBER
    DBID NUMBER
    LSQLBIND CLOB
    SQL> spool off

  • How to insert varchar2 value in timestamp column in table?

    Hi all,
    Hope doing well,
    sir i am using one stored procedure and storing time in varchar2 variable in this format: 08:00:00
    now i have to insert this value in timestamp column in table. how to insert this value in timestamp column?
    thanks

    952646 wrote:
    Hi all,
    Hope doing well,
    sir i am using one stored procedure and storing time in varchar2 variable A "Very Bad Idea"(tm)
    When you do this, there is no fundamental difference between "08:00:00" and "here's your sign".
    Data should always be stored in the correct data type. For dates and times, that data type is either DATE or TIMESTAMP. Period.
    in this format: 08:00:00
    now i have to insert this value in timestamp column in table. how to insert this value in timestamp column?
    Hopefully as remediation to the original bad design.
    thanks

  • If Both tables having References then how to insert the data each other

    Hai EveryOne..,
    My Sample data.,
    Create table emp (empno number primary key,ename varchar2(20));
    Create table emp_dup (empno number references emp(empno),ename varchar2(20) primary key);
    alter table emp add constraint ename_fk foreign key(ename) references emp(ename);
    My Question is How to insert the data into these two tables?
    Its a *"Circular Reference"* Concept.
    Please ...
    Thank You!!

    You need to set the DEFERRED clause of the constraint when you create your foreign key as DEFERRABLE by which you can move the constraint validation at transaction level.
    In an interview point of view that could be a reasonable answer. But in real time this could be strongly questionable.
    Here is an example
    SQL> create table emp1 (empno number, ename varchar2(10))
      2  /
    Table created.
    SQL> create table emp2 (empno number, ename varchar2(10))
      2  /
    Table created. Define Primary Key for two tables
    SQL> alter table emp1 add constraint emp1_pk primary key (empno)
      2  /
    Table altered.
    SQL> alter table emp2 add constraint emp2_pk primary key (ename)
      2  /
    Table altered. Add foreign key for two tables with DEFERRED clause set as DEFERRABLE
    SQL> alter table emp1 add constraint emp1_fk foreign key (ename) references emp2(ename) initially deferred deferrable
      2  /
    Table altered.
    SQL> alter table emp2 add constraint emp2_fk foreign key (empno) references emp1(empno) initially deferred deferrable
      2  /
    Table altered. Now here is the test case
    SQL> insert into emp1 values (1, 'karthick')
      2  /
    1 row created.
    SQL> commit      
      2  /
    commit
    ERROR at line 1:
    ORA-02091: transaction rolled back
    ORA-02291: integrity constraint (ARBORU.EMP1_FK) violated - parent key not found So the validation is done at Transaction level. Now let insert the value into both tables.
    SQL> insert into emp1 values (1, 'karthick')
      2  /
    1 row created.
    SQL> insert into emp2 values (1, 'karthick')
      2  /
    1 row created.
    SQL> commit
      2  /
    Commit complete.

  • How to get the values from popup window to mainwindow

    HI all,
       I want to get the details from popup window.
          i have three input fields and one search button in my main window. when i click search button it should display popup window.whenever i click on selected row of the popup window table ,values should be visible in my main window input fields.(normal tables)
       now i am able to display popup window with values.How to get the values from popup window now.
       I can anybody explain me clearly.
    Thanks&Regards
    kranthi

    Hi Kranthi,
    Every webdynpro component has a global controller called the component controller which is visible to all other controllers within the component.So whenever you want to share some data in between 2 different views you can just make it a point to use the component controller's context for the same. For your requirement (within your popups view context) you will have have to copy the component controllers context to your view. You then will have to (programmatically) fill this context with your desired data in this popup view. You can then be able to read this context from whichever view you want. I hope that this would have made it clear for you. Am also giving you an [example|http://****************/Tutorials/WebDynproABAP/Modalbox/page1.htm] which you can go through which would give you a perfect understanding of all this. In this example the user has an input field in the main view. The user enters a customer number & presses on a pushbutton. The corresponding sales orders are then displayed in a popup window for the user. The user can then select any sales order & press on a button in the popup. These values would then get copied to the table in the main view.
    Regards,
    Uday

  • How to find the value of a variable in other program

    How to find the value of a variable in other program say I am in a FM and this FM is being called in from other program and I want to know some of the variable details of the program from the FM itself. Imagine if this is a txn. and I need to know the details from some of the programs while executing the same transaction
    Regards
    Vin

    Hi Vinayak,
         you will be having your first program values in internal table or some variables,
        when you are calling the second program you wii use like this,
        SUBMIT <Second Program Name> USING SELECTION-SCREEN '1000'
                           WITH s_emp(second program select-options)   IN t_emp(first program variables)
                           WITH p_chk   EQ t_chk
                           WITH p_r1    EQ t_r1
                           WITH p_month EQ t_month
                           WITH s_cust1 IN t_cust1
                           WITH p_r2    EQ t_r2
                           WITH s_cust2 IN t_cust2
                           WITH s_week  IN t_week
                           AND RETURN.
    you have pas like this to get your first program details.

Maybe you are looking for

  • Error : CONNECT BY loop in user data

    Getting CONNECT BY loop in user data: Table X  (sample data actually have 35K rows) CODE             CASE              OLD_ID                NEW_ID            PERSON       AUTH 01              ab122         1234               0001             AU123  

  • 11g TP2 ADF Task Flows and Transaction Management

    I'm wondering how ADF Task Flow Transaction Management works vis-a-vis database sessions and using stored procedure calls in an environment with connection pooling. I haven't written the code yet but am looking for a better understanding of how it wo

  • Item/button of wrong data captured validation

    Morning All, im new to apex.. ive got a small form im designing, so far so good. but i want there to be a validation if the wrong empno is entered i.e after the getdata button is clicked. the applcaition -- http://apex.oracle.com/pls/apex/f?p=23206:1

  • Scan a file for virus before upload

    In many CRM functions, eg - Activities, Mkt Planner, etc., there is a tab for uploading/attaching files.  How can we scan the file for virus before saving?  We have a Basis 620, so we can't use the Virus Scan Interface because it is available from Ba

  • Firefox won't update past 3.6.9

    Was looking to update my pc to Firefox 4.0, since it hasn't automatically updated. When I went to check for updates it said download paused on 3.6.10 and when trying to get it to update, it simply says connecting to the update server for a time and t