Get the timestamp value in the form of array of 8 bytes, whileretrieving da

3) How we can get the timestamp value in the form of array of 8 bytes, while retrieving the data?
4.) How we can pass the 8 byte array to stored procedure? What will the data type of the parameter?

duplicate post:
timestamp value in the form of array of 8 bytes

Similar Messages

  • Timestamp value in the form of array of 8 bytes

    1) How we can get the timestamp value in the form of array of 8 bytes, while retrieving the data?
    2) How we can pass the 8 byte array to stored procedure? What will the data type of the parameter?

    1). using to_char
    SQL> select to_char(systimestamp, 'ddmmyyyy') from dual ;
    TO_CHAR(
    10052006
    SQL>2). as varchar2, and use to_timestamp to convert to timestamp:
    SQL> select to_timestamp('10052006', 'ddmmyyyy') from dual ;
    TO_TIMESTAMP('10052006','DDMMYYYY')
    10-MAY-06 12.00.00.000000000 AM
    SQL>

  • How to get the old value of the ValueChangeEvent

    I'm using the JSF component selectManyListbox. I have assigned a value change listener to it. When I try get the old value using getOldValue() of the ValueChangeEvent Im always getting a null value. The only value Im getting is from the method getNewValue(), which is the last item I clicked in the selectManyListbox items before submitting the whole form. Is there a way to get the old value of this component or Im doing something wrong?

    Here is the partial bean code
    public class TestUI extends PageCodeBase {
         private static Logger logger = Logger.getLogger(pagecode.protected1.TestUI.class);
         protected Object [] menuValue;
         protected Object [] listBoxValue;
         protected List allTaskCodes;
         * @return Returns the listBoxValue.
         public Object[] getListBoxValue() {
              return listBoxValue;
         * @param listBoxValue The listBoxValue to set.
         public void setListBoxValue(Object[] listBoxValue) {
              this.listBoxValue = listBoxValue;
    public void handleSelectManyListboxValueChange(
                   ValueChangeEvent vce) {
              logger.debug(".. first component was heard..");
              String[] s1 = (String[]) vce.getOldValue();
              String[] s2 = (String[]) vce.getNewValue();
              //vce.getComponent().
              if (s1!=null&&s1.length!=0) {
                   logger.debug("length of first array is " + s1.length );
              //for(int i=0; i<s1.length; i++)
                        logger.debug("value of old is " + s1[0] );
              if (s2!=null&&s2.length!=0) {
                   logger.debug("length of second array is " + s2.length );
                   //for(int i=0; i<s1.length; i++)
                        logger.debug("value of new is " + s2[0]);
    Here is the jsf code
    <h:selectManyListbox styleClass="selectManyListbox" id="listbox1"
                        size="3" valueChangeListener="#{pc_TestUI.handleSelectManyListboxValueChange}"
    onchange="submit()" value="#{pc_TestUI.listBoxValue}">
    <f:selectItem itemValue="value1" itemLabel="select1" />
                        <f:selectItem itemValue="Value2" itemLabel="select2" />
                        <f:selectItem itemValue="Value3" itemLabel="select3" />
    <f:selectItem itemValue="value4" itemLabel="select1" />
                        <f:selectItem itemValue="Value5" itemLabel="select2" />
                   </h:selectManyListbox>

  • How can i get the all values from the Property file to Hashtable?

    how can i get the all values from the Property file to Hashtable?
    ok,consider my property file name is pro.PROPERTIES
    and it contain
    8326=sun developer
    4306=sun java developer
    3943=java developer
    how can i get the all keys & values from the pro.PROPERTIES to hashtable
    plz help guys..............

    The Properties class is already a subclass of Hashtable. So if you have a Properties object, you already have a Hashtable. So all you need to do is the first part of that:Properties props = new Properties();
    InputStream is = new FileInputStream("tivoli.properties");
    props.load(is);

  • Need to get the selected values from the selectManyShuttle

    Hi,
    I am using ADF11g newer version.
    I have a selectManyShuttle and a command button. Need to insert all the selected values on the right hand side of the selectManyShuttle into a database table.
    I created the selectManyShuttle with the values. Need help in getting the values on the right hand side.
    <af:selectManyShuttle value="#{bindings.UserMgmtVO1.inputValue}"
    id="sms2">
    <f:selectItems value="#{bindings.UserMgmtVO1.items}"
    id="si6"/>
    </af:selectManyShuttle>
    Any sample code or link is really appreicated.
    Thanks

    Thanks for the reply.
    I am using a View Object and I dropped it as SelectManyShuttle
    <af:selectManyShuttle value="#{bindings.UserMgmtVO1.inputValue}"
    id="sms2"
    valueChangeListener="#{POBacking.getSelectedValues}"
    valuePassThru="true"
    autoSubmit="true">
    <f:selectItems value="#{bindings.UserMgmtVO1.items}"
    id="si6"/>
    </af:selectManyShuttle>
    public void getSelectedValues(ValueChangeEvent valueChangeEvent) {
    System.out.println("Testing Shuttle");
    ArrayList list = new ArrayList(Arrays.asList(valueChangeEvent.getNewValue()));
    String val = "";
    String sqlStmt = "";
    try {
    if (list != null) {
    for (int i = 0; i < list.size(); i++) {
    int l = list.size() - 1;
    val = list.get(l).toString(); //returns , delimited string
    System.out.println(" value:" + val);
    if (val != null) {
    val = val.replaceAll("[\\[\\]]", ""); //remove []
    StringTokenizer st = new StringTokenizer(val, ",");
    int nto = st.countTokens();
    for (int j = 0; j < nto; j++) {
    String users = st.nextToken().trim();
    System.out.println("Users:" + users);
    //sqlStmt = " update xxpp_project_clip set clip_status='true', clip_seq = "+j * 10+
    // " where project_id = "+rHdr.getAttribute("ProjectId") +
    // " and clip_name ='"+ clip_Name +"'";
    //System.out.println("sqlStmt:" + sqlStmt);
    //stmt.executeUpdate(sqlStmt);
    //am.getDBTransaction().commit();
    //if (stmt != null)
    // stmt.close();
    // am.getDBTransaction().commit();
    } catch (Exception ex) {
    ex.printStackTrace();
    I don't see the values in the list.
    I gets printed as
    value:[Ljava.lang.Integer;@1b10691
    Users:Ljava.lang.Integer;@1b10691
    how to get the individual values in the list?
    Thanks
    Saru

  • How to get a field value in the report

    hi all :-
    i need to get the field value in the formate trigger inside a specified field in the report?

    please post your request in the report category forum

  • How to keep the field value in the forms for one week

    I have an application that when the user logs on to it , it shows all the documents that are in the current dept.
    the form has the following fields:
    document no
    sent date
    assigned to
    dep_LOV
    and a check box
    if a user clicks the check box and assignes the document to another dept by cliking the LOv then the assigned to field should be populated with the new value and the sent date should be today's date(sysdate). the requirment is that once the user assignes the documnet to certain depts (for example sales dept) the assigned to field and the sent date should show up in the form for one week and the user should be able to see that data in the form the next time she /he logs onto the application. the one week time is to make sure the documcnt has reached the assigned dept. after one week from today's date the updated assigned_to field and the document no should not display on the form. During the one week if the user logs on to the form again that particular document and the assigned to and sent to fields shoould be grayed out and shhould not be updatable. I will greatly appreciate any suggetion as of what to do to solve this problem. it is urgent. Pleade help

    -> so you are saying that I should have a block level post_query trigger and put the where clause in it?
    No. Post-query trigger runs AFTER the query has been executed, and it runs once for each row fetched. It is for other purposes, NOT for setting a where clause.
    -> Plus i want to be able to gray out the field once populated with the sales dept.I have come up with the following code:
    Your Set_item_instance_property is almost correct. And THAT line would go into the Post-Query trigger. This is what you might use:
    <pre><font face = "Lucida Console, Courier New, Courier, Fixed" size = "1" color = "navy"> Set_item_instance_property ('docs.assigned_to',:system.trigger_record, Enabled,Property_False);</font></pre>
    Please watch your use of underscore, dashes, commas and parentheses: _ - , ( )
    The way to set your default where clause would be the following, and you should do it in the key-exeqry trigger, or someplace similar:
    <pre><font face = "Lucida Console, Courier New, Courier, Fixed" size = "1" color = "navy"> set_block_property('DOCS', default_where,
    'NVL(sent_date,sysdate) >= sysdate-7' );
    Go_block('DOCS');
    Execute_Query;</font></pre>
    I used the NVL function so your select will show rows where sent_date is null OR sent_date has a value that is within 7 days prior to the current date.
    What is the field :docs.assigned_to used for? If you want to include ONLY rows that are assigned to a particular person, then your where clause might be:
    <pre><font face = "Lucida Console, Courier New, Courier, Fixed" size = "1" color = "navy"> 'assigned_to = :ctrl.assigned_to and NVL(sent_date,sysdate) >= sysdate-7' </font></pre>
    and you should have a control block with the assigned_to field in it, where the user can enter a value before querying the DOCS block.

  • How to directly get the selected value in the dropdown

    Hi Experts
        Now, in POV, i want to directly get the selected value in the dropdown. Because, the program doesn't enter the PAI before POV part. Therefore, the corresponding variable of dropdown doesn't store the selected value. That's reason why i want to find a way to directly get the selected value in the dropdown. is there any function module to do this?

    you can use INITIALIZATION event which triggers first before any other events..
    and u can use VRM_SET_VALUES to populate the values in the list
    DATA : v TYPE vrm_values.
    DATA : vw LIKE LINE OF v.
    INITIALIZATION.
      vw-key = '1'.
      vw-text = 'ABC'.
      APPEND vw TO v.
      vw-key = '2'.
      vw-text = 'DEF'.
      APPEND vw TO v.
      CALL FUNCTION 'VRM_SET_VALUES'
        EXPORTING
          id              = 'A'
          values          = v.
    PARAMETERS : a TYPE c VISIBLE LENGTH 10 AS LISTBOX.

  • Problem in getting the current value of the drop down while calling value change listener

    I have 2 drop down list. I am trying to get the value of first drop down from other drop downs value change listener. Initially one drop down contains a default value. First time I got the value while calling the value change listener. But if I change the default value to other in the first drop down and call the value change listener of the second drop down then I got the old value in the bean. Can anyone suggest a process

    If I use the following code it gives me the current index.
                valueChangeEvent.getComponent().processUpdates(FacesContext.getCurrentInstance());
                System.out.println(valueChangeEvent.getNewValue());
    This is also giving me current index.
    BindingContainer container = BindingContext.getCurrent().getCurrentBindingsEntry();
    AttributeBinding attrIdBinding = (AttributeBinding)container.getControlBinding("PersonTypeId1");
    if(attrIdBinding.getInputValue()!=null)
                   System.out.println(attrIdBinding.getInputValue().toString());
    But at last I got some help from Shay Shmeltzer's Weblog.
    BindingContainer bindings =
                    BindingContext.getCurrent().getCurrentBindingsEntry();
                    // Get the sepecific list binding
                    JUCtrlListBinding listBinding =
                    (JUCtrlListBinding)bindings.get("PersonTypeId1");
                    // Get the value which is currently selected
                    Object selectedValue = listBinding.getSelectedValue();
                      long value =0L;
                    if(selectedValue!=null){
                        System.out.println("Sudip.. Person Type using bindings"+selectedValue.toString());
    But this returns "ViewRow [oracle.jbo.Key[300000860721156 ]]"
    300000860721156 is the original value.. Would you please help me to figure it.

  • BO XI Desk-I graph The negative values are rising form the lowest value up

    The negative values are rising form the lowest value up. Instead of dropping from the Zero-line. Where is the problem originating?  BO FP2.3.
    The positives values are also rising from the lowest value up.
    The problem only occurs withing Desk-I. Within Web-I this problem does not occur.
    Edited by: A. SMULDERS on Sep 7, 2010 10:35 AM

    Hi
    Try with the following symbol in the field
    &ITAB-NETWR(>)&  - will write the sign  as (100.00-)
    &ITAB-NETWR(<)&  - will write the sign  as (-100.00)
    and based on some field  in the program write like
    If itab-shkzg = 'H'.
      itab-netwr = itab-netwe * -1.
    endif.
    and try to print this field in the form.
    <b>Reward points for useful Answers</b>
    Regards
    Anji

  • How to get the max value in the query??

    Plant  calday(mm.dd.yyyy)       Soldout.Qty
    0001   01.01.2005               10
    0001   01.02.2005               20
    0001   01.03.2005               05
    0001   01.04.2005               16
    0001   01.05.2005               10
    0001   01.06.2005               14
        From the above values , how can i findout Max(Soldout.Qty)(i.e 20) for the above week...Suppose present aggregation = summation...How can i findout the value in the Query??don't want to do changes to design...

    Hi Bhanu,
      I tried the calculation results as...Maximum,..
      But that will pick the maximum value among the avialable values..like
    plant1 max 10
    plant2 max 20
    plant3 max 30
    then it will show as..
    plant1 max 30
    plant2 max 30
    ...like this...but my case is
    plant1 calday1 10
    plant1 calday2 05
    plan1  calday7 08
    plant2 calday1 10
    plant2 calday2 05
    plan2  calday7 20
    so for each set it need to bring the maximum value...

  • How to get warning by using the previous value of the column and new value

    Hi all,
    Suppose the column A has the true and when I click on button which also sets the value of the column as true I should dispaly warning that column a is already true.How can I achieve this.How to store the original value of the column and then check wirth the new value.
    Thanks in advance.

    You dont have to store the value anywhere
    You can do this from setMethod of EOImpl.java
    eg:
    void setAttributeXXX(String Value)
    // value contains new value
    // getAttributeXXX() contains oldValue
    if (value.equals(getAttributeXXX()))
    // Verify value is > 0 if (value.compareTo(0) <= 0)
    throw new OAAttrValException(OAException.TYP_ENTITY_OBJECT, // indicates EO source
    getEntityDef().getFullName(), // entity name
    getPrimaryKey(), // entity primary key
    "AttributeXXX", // attribute Name
    value, // bad attribute value
    "AK", // nessage application short name
    "FWK_TBX_T_EMP_SALARY_REQUIRED"); // message name
    setAttributeInternal(AttributeXXX, value);
    --Prasanna                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                       

  • [svn:fx-trunk] 7553: Fix the default value of the [skinPart] "required" attribute for asdoc.

    Revision: 7553
    Author:   [email protected]
    Date:     2009-06-04 09:32:51 -0700 (Thu, 04 Jun 2009)
    Log Message:
    Fix the default value of the "required" attribute for asdoc.
    Bugs: SDK-21488
    QE Notes: None.
    Doc Notes: None.
    tests: checkintests
    Ticket Links:
        http://bugs.adobe.com/jira/browse/SDK-21488
    Modified Paths:
        flex/sdk/trunk/modules/compiler/src/java/flex2/compiler/asdoc/TopLevelGenerator.java

    ${ui:cond( uix.current.isNewRow, 'true', ui:cond( bindings.AddProjectNutsoverleg.value == 1, 'true', 'false' ) ) } notice the '.value' it could also be '.inputValue'.
    If not there is also an option to make sure that when the checkbox is empty a value is returned anyways this work like this:
      protected void processUpdateModel( DataActionContext ctx )
        //First look for the request parameter
        Object cbInRequest = ctx.getHttpServletRequest().getParameter( "nameofthecheckbox" );
        //We only need to do anything if it was not submitted
        if( cbInRequest == null )
          // Get hold of the Form Bean containing the record
          BindingContainerActionForm updateForm = (BindingContainerActionForm) ctx.getActionForm();
          //Get the binding for our particular column
          JUCtrlAttrsBinding checkBoxBinding = (JUCtrlAttrsBinding)updateForm.get( "nameofthecheckbox" );
          //Reset that explicitly to the *unchecked* value
          checkBoxBinding.setAttribute( 0, new oracle.jbo.domain.Number( 0 ) );
        super.processUpdateModel( ctx );
      }Maybe this helps.

  • Need help Take out the null values from the ResultSet and Create a XML file

    hi,
    I wrote something which connects to Database and gets the ResultSet. From that ResultSet I am creating
    a XML file. IN my program these are the main two classes Frame1 and ResultSetToXML. ResultSetToXML which
    takes ResultSet & Boolean value in its constructor. I am passing the ResultSet and Boolean value
    from Frame1 class. I am passing the boolean value to get the null values from the ResultSet and then add those
    null values to XML File. When i run the program it works alright and adds the null and not null values to
    the file. But when i pass the boolean value to take out the null values it would not take it out and adds
    the null and not null values.
    Please look at the code i am posing. I am showing step by step where its not adding the null values.
    Any help is always appreciated.
    Thanks in advance.
    ============================================================================
    Frame1 Class
    ============
    public class Frame1 extends JFrame{
    private JPanel contentPane;
    private XQuery xQuery1 = new XQuery();
    private XYLayout xYLayout1 = new XYLayout();
    public Document doc;
    private JButton jButton2 = new JButton();
    private Connection con;
    private Statement stmt;
    private ResultSetToXML rstx;
    //Construct the frame
    public Frame1() {
    enableEvents(AWTEvent.WINDOW_EVENT_MASK);
    try {
    jbInit();
    catch(Exception e) {
    e.printStackTrace();
    //Component initialization
    private void jbInit() throws Exception {
    //setIconImage(Toolkit.getDefaultToolkit().createImage(Frame1.class.getResource("[Your Icon]")));
    contentPane = (JPanel) this.getContentPane();
    xQuery1.setSql("");
    xQuery1.setUrl("jdbc:odbc:SCANODBC");
    xQuery1.setUserName("SYSDBA");
    xQuery1.setPassword("masterkey");
    xQuery1.setDriver("sun.jdbc.odbc.JdbcOdbcDriver");
    contentPane.setLayout(xYLayout1);
    this.setSize(new Dimension(400, 300));
    this.setTitle("Frame Title");
    xQuery1.setSql("Select * from Pinfo where pid=2 or pid=4");
    jButton2.setText("Get XML from DB");
    try {
    Class.forName("sun.jdbc.odbc.JdbcOdbcDriver");
    catch(java.lang.ClassNotFoundException ex) {
    System.err.print("ClassNotFoundException: ");
    System.err.println(ex.getMessage());
    try {
    con = DriverManager.getConnection("jdbc:odbc:SCANODBC","SYSDBA", "masterkey");
    stmt = con.createStatement();
    catch(SQLException ex) {
    System.err.println("SQLException: " + ex.getMessage());
    jButton2.addActionListener(new java.awt.event.ActionListener() {
    public void actionPerformed(ActionEvent e) {
    jButton2_actionPerformed(e);
    contentPane.add(jButton2, new XYConstraints(126, 113, -1, -1));
    //Overridden so we can exit when window is closed
    protected void processWindowEvent(WindowEvent e) {
    super.processWindowEvent(e);
    if (e.getID() == WindowEvent.WINDOW_CLOSING) {
    System.exit(0);
    void jButton2_actionPerformed(ActionEvent e) {
    try{
    OutputStream out;
    XMLOutputter outputter;
    Element root;
    org.jdom.Document doc;
    root = new Element("PINFO");
    String query = "SELECT * FROM PINFO WHERE PID=2 OR PID=4";
    ResultSet rs = stmt.executeQuery(query);
    /*===========This is where i am passing the ResultSet and boolean=======
    ===========value to either add the null or not null values in the file======*/
    rstx = new ResultSetToXML(rs,true);
    } //end of try
    catch(SQLException ex) {
    System.err.println("SQLException: " + ex.getMessage());
    ======================================================================================
    ResultSetToXML class
    ====================
    public class ResultSetToXML {
    private OutputStream out;
    private Element root;
    private XMLOutputter outputter;
    private Document doc;
    // Constructor
    public ResultSetToXML(ResultSet rs, boolean checkifnull){
    try{
    String tagname="";
    String tagvalue="";
    root = new Element("pinfo");
    while (rs.next()){
    Element users = new Element("Record");
    for(int i=1;i<=rs.getMetaData().getColumnCount(); ++i){
    tagname= rs.getMetaData().getColumnName(i);
    tagvalue=rs.getString(i);
    System.out.println(tagname);
    System.out.println(tagvalue);
    /*============if the boolean value is false it adds the null and not
    null value to the file =====================*/
    /*============else it checks if the value is null or the length is
    less than 0 and does the else clause in the if(checkifnull)===*/
    if(checkifnull){ 
    if((tagvalue == null) || tagvalue.length() < 0 ){
    users.addContent((new Element(tagname).setText(tagvalue)));
    else{
    users.addContent((new Element(tagname).setText(tagvalue)));
    else{
    users.addContent((new Element(tagname).setText(tagvalue)));
    root.addContent(users);
    out=new FileOutputStream("c:/XMLFile.xml");
    doc = new Document(root);
    outputter = new XMLOutputter();
    outputter.output(doc,out);
    catch(IOException ioe){
    System.out.println(ioe);
    catch(SQLException sqle){

    Can someone please help me with this problem
    Thanks.

  • Format the total value in the column of the graph table

    Hello all,
    I have a graph table and I need to format the total value in the column of the table.
    I am trying to find my table bean with the code below but it's not working in the processRequest. Is there anything else that should be done?
    // Get the graph
    OAGraphTableBean graphBean = (OAGraphTableBean)webBean.findChildRecursive("MyGraph");
    // Get the table
    OATableBean tblBean = (OATableBean)graphBean.findChildRecursive("MyTable");
    The tblBean is null in the processRequest. In the processFormRequest the tblBean is not null.
    Thanks and Regards,
    Andrea

    Hi,
    The code OAGraphTableBean graphBean = (OAGraphTableBean)webBean.findChildRecursive("MyTable"); does not work because in this case I am getting the table but casting to a graph.
    The MyTable bean is a child of MyGraph.
    When creating a graph bean we have the option to create a table as a child (select your graphTable region in the Structure pane, and choose New > tabularFormat - to create the table).
    The table bean child I can get just in the processFormRequest, but the graph I can get in both processRequest and processFormRequest.
    I need to get the table bean in the processRequest to format the total value column.
    Do you know if is there anything else that should be done to format the total column?
    Thanks and Regards,
    Andrea

Maybe you are looking for

  • Read and write from and to text file

     Hi All, I am trying to read some portion of a text file and make measurement and calculation with those numbers and write back to the same text file and also to a excel file. I need to create a 2 D  array of 20 by 20 from the text file values and wr

  • Cumulative Key figure

    Hi all, can anybody tell me abt cumulative or non cumulative key figure with sutabel example . why those type of key figures are use in BW3.5 ?? if anybody have document related to the same then send it to me id : modi.ankit1 at the rate gmail Thanks

  • I synced my iPhone and lost purchased songs

    I synchronized my iPhone yesterday and realized that recently downloaded song disappeared after the sync. 

  • T440s - i7-4600U CPU - ONLY ONE core operating :((

    Hi, I am an owner of Thinkpad T440s ultrabook, which has Intel i7 4600U CPU installed (exact model is 20AQ006BMC - the one with GeForce 730M graphic card). Regarding to the documentation on Intel website, this CPU should have 2 cores and 4 threads (H

  • 12154: "Could not resolve service name"

    [oracle@proton dbs]$ sqlplus system/manager@bcqa SQL*Plus: Release 8.1.7.0.0 - Production on Fri May 4 16:00:00 2001 (c) Copyright 2000 Oracle Corporation. All rights reserved. ERROR: ORA-12154: TNS:could not resolve service name I have read many doc