Missing Time value in Date

Hi Pros,
I have a table in my oracle database, lets say TableA having a cloumn, say ColumnA with data type as DATE.
Now, inside my JDBC code, I fire a query which returns number of coulmns in a ResultSet (Including the one having DATE datatype).
When I fetch the value of 'ColumnA' column while iterating the resultset, I get a value of type java.sql.Date.
Now on UI side I need to display date and time value from this coulmn in a format dd-mm-yy hh:mm:ss, I used SimpleDateFormat to do that
but the Date on UI shows a date and time value with time value set to 00:00:00 for every row which has been fetch by the query.
SimpleDateFormat formatter = new SimpleDateFormat("dd-MM-yyyy  HH:mm:ss");
String dateAndTimeAsString  = formatter.format(resultSet.getDate("CREATION_DATETIME"))The thing is can see the proper time values in database table, but it seems it is being skipped somhow.
I also tried convetring java.sal.Date to java.uitl.Date using following code format , but still the same results........
java.util.Date    utilDate = new java.util.Date((resultSet.getDate("CREATION_DATETIME")).getTime();then converted this Date into string using SimpleDateFormt.format() method, but still did not hit the spot :(
String dateAndTimeAsString = formatter.format(utilDate);Any idea ? how can i achive this .................
Thanks in advance..........

marathaWarrior wrote:
You are right, I should have tried it before replying,
But the thing is for a single line of change in code , it takes nearly an hour to re-build the project (and there is no short cut as code builds so many dependent jars). Hope you can understand. Any way I will give it a try.I glad you got it working.
You don't necessarily have to re-build your entire application to try something.
The next time you are in a similar situation try making a little test app that just does what you want to test.

Similar Messages

  • Convert millisecond time value to date

    If i have a millisecond time value, say long timeValue, how do I convert this value to a time and a date?

    Or directly set a new date using the constructor
    Date(long date)
    Allocates a Date object and initializes it to represent the specified number of milliseconds since the standard base time known as "the epoch", namely January 1, 1970, 00:00:00 GMT.
    N.B. - Note that the Date class method to set a date from a long is:
    setTime(long time)
    Sets this Date object to represent a point in time that is time milliseconds after January 1, 1970 00:00:00 GMT.
    setTimeInMillis() is a Calendar method , only.

  • Query needed for sorting by time value

    Hi Folks
    We have table it consists two columns like below
    Job_name varchar2(50)
    Scheduled_time date
    The filed scheduled time keep date and time value like below
    25-Jul-2009 4:00:10 AM
    26-Jul-2009 4:00:01 PM
    27-Jul-2009 4:00:00 PM
    28-Jul-2009 4:05:00 PM
    01-Jul-2009 4:06:00 PM
    02-Jun-2009 4:15:40 AM
    We need output as sorting by time value NOT date value. Expected output to be below
    25-Jul-2009 4:00:10 AM
    02-Jun-2009 4:15:40 AM
    27-Jul-2009 4:00:00 PM
    26-Jul-2009 4:00:01 PM
    28-Jul-2009 4:05:00 PM
    01-Jul-2009 4:06:00 PM
    I am using oracle 10G
    Thanks in Advance

    Here's how :
    SQL> create table job_table (job_name varchar2(50) not null, scheduled_time date);
    Table created.
    SQL> insert into job_table
      2  values ('Job_abc',to_date('25-JUL-2009 04:00:00','DD-MON-YYYY HH24:MI:SS'));
    1 row created.
    SQL> insert into job_table
      2  values ('Job_fdw',to_date('02-JUN-2009 04:15:40','DD-MON-YYYY HH24:MI:SS'));
    1 row created.
    SQL> insert into job_table
      2  values ('Job_fxj',to_date('27-JUL-2009 03:59:00','DD-MON-YYYY HH24:MI:SS'));
    1 row created.
    SQL> insert into job_table
      2  values ('Job_rjt',to_date('20-JUL-2009 14:59:00','DD-MON-YYYY HH24:MI:SS'));
    1 row created.
    SQL> commit;
    Commit complete.
    SQL> alter session set nls_date_format='DD-MON-YYYY HH:MI:SS AM';
    Session altered.
    SQL> select job_name, scheduled_time from job_table
      2  order by to_char(scheduled_time,'HH24:MI:SS');
    JOB_NAME                                           SCHEDULED_TIME
    Job_fxj                                            27-JUL-2009 03:59:00 AM
    Job_abc                                            25-JUL-2009 04:00:00 AM
    Job_fdw                                            02-JUN-2009 04:15:40 AM
    Job_rjt                                            20-JUL-2009 02:59:00 PM
    SQL>

  • How to get the date-time value?

    Hi All
    I have a a field "START_TIME of type DATE". The value stored for that particular field is of the form "10/17/2006 2:23:40 PM" i.e. a date-time value.
    Now when i try to get the values stored in the table in which the START_TIME field is defined i get the value in the form of "10/17/2006" .... I missed out the time information. Why is this so? How do i get the complete value as a string?
    Thanks in advance. Vijay

    Hi All
    I have a a field "START_TIME of type DATE". The value stored for that particular
    field is of the form "10/17/2006 2:23:40 PM" i.e. a date-time value.Actually it is stored as an internal date format (see my example SQL below, taking note of the dump'ed data).
    Now when i try to get the values stored in the table in which the START_TIME field is defined i get the
    value in the form of "10/17/2006" ....
    I missed out the time information. Why is this so?
    How do i get the complete value as a string?The value you see on the screen is the display format and this is determined by the client application that is displaying the date and what settings it is using. If a date column is retrieved from the database then all the data (date and time) is given back, but it's up to the application how that is displayed. e.g. you may see it differently if you view it is SQL*Plus against some other tool such as TOAD.
    To change the display settings you can change your NLS_DATE_FORMAT setting or whatever setting is suitable for your client application, or you can use TO_CHAR with a format string to specify the components you want to see. The different with TO_CHAR is that you are converting it to a character string so don't attempt to do any date type comparisons on it after that conversion, e.g. don't try and compare if one date is greater than another, without converting it back to DATE datatype first.
    SQL> create table t (x date);
    Table created.
    SQL> insert into t (x) values (sysdate);
    1 row created.
    SQL> select x from t;
    X
    02-JUN-08
    SQL> select x, dump(x) from t;
    X
    DUMP(X)
    02-JUN-08
    Typ=12 Len=7: 120,108,6,2,13,32,51
    SQL> alter session set nls_date_format = 'DD/MM/YYYY HH24:MI:SS';
    Session altered.
    SQL> select x, dump(x) from t;
    X
    DUMP(X)
    02/06/2008 12:31:50
    Typ=12 Len=7: 120,108,6,2,13,32,51
    SQL>

  • Missing Parameter Values - C# - Pushing Datatables to feed data to Report

    Hello,
    I am working on a .NET project to process close to 650 "existing" reports developed in Crystal Reports 8.5. Rendering reports without subreports is working just fine. However I am getting the following error everytime I try to render a report that has multiple subreports
    Missing parameter values. at CrystalDecisions.ReportAppServer.ConvertDotNetToErom.ThrowDotNetException(Exception e)
    Following is how the reports are built.
    Main Report - Fed with a Datatable whose name corresponds to the name of the SQL Query configured in Crystal UI
        SubReport1 - Fed with a Datatable whose name corresponds to the name of the SQL Query configured in Crystal UI. The                           subreport is linked to the parent report using one of the fields in the Datatable that is passed to the main report.
    Example: the main report receives a datatable with the following fields
    EmployeeId (integer), EmployeeName (string)
    The subreport receives a datatable with the following fields : EmployeeId (Integer), EmployeeHobbies (string)
    The link is established as follows:
    SubReportQueryName.EmployeeId link to MainReportQueryName.EmployeeId
    _I have checked the data, its correct in terms of the fields required to render the report. The report parameters are being set from the code and ApplyCurrentValues is being called to ensure that the set values are used when rendering the report.
    Please note that I am not using live connections to the database
    I tried saving a copy of the above mentioned report and removing the subreport and then rendering the report, all works fine. However the moment i introduce the subreport, per the above mentioned report design/architecture all hell breaks loose and i cannot render the report.
    The environment is Windows Vista and I am running VS 2008.
    Any help is appreciated.
    Thanks
    Edited by: pkumbhat on Sep 15, 2010 4:43 PM

    The issue has been dealt with.
    The solution is to set the datasource with a dataset even if the report or subreport expects or is configured to work with a single table.

  • How to substract two date&time values

    Well,i just need to substract last visited date&time value from systemdate. The last visited date&time(from the filed named SONBULUNMAZAMANI, ) is selected from table (IHALE_KATILIMCILAR ) in the format DD-MM-RRRR HH24:MI and systemdate is in the same format. And i need to get value in minutes. Then i need to check if the value is greater then 20 minutes, finally i will update database and set IHALE_KATILIMCILAR.AKTIF=0. Here is the code i used;
    DECLARE
    MinDiff number;
    DateTime1 ihale_katilimcilar.sonbulunmazamani%TYPE;
    BEGIN
    select t.sonbulunmazamani into DateTime1 from ihale_katilimcilar t where t.ihlkodu=141 and t.ihlaltktgkodu=132 and t.id_iliski=193;
    MinDiff := ABS( TO_DATE( TO_CHAR(SYSDATE, 'DD-MM-RRRR') || TO_CHAR(SYSDATE , 'HH24:MI'), 'DD-MM-RRRR HH24:MI' ) - TO_DATE( TO_CHAR(DateTime1, 'DD-MM-RRRR') || TO_CHAR(DateTime1, 'HH24:MI'), 'DD-MM-RRRR HH24:MI' ) );
    DBMS_OUTPUT.PUT_LINE('Difference is ' || MinDiff);
    END;
    However the result i get is always pointed values such as ,1895833333333333333333333333333333333333. How can i handle this?
    And here is the scripts of table:
    create table IHALE_KATILIMCILAR
    KULADI VARCHAR2(20),
    SONUC NUMBER(1),
    AKTIF NUMBER(1) default 1,
    SRKTKODU VARCHAR2(10) not null,
    SONBULUNMAZAMANI DATE default sysdate,
    SIRA NUMBER(1) default 0,
    MESAJ VARCHAR2(200),
    ID NUMBER(6) not null,
    IHLKODU NUMBER not null,
    IHLALTKTGKODU VARCHAR2(10) not null,
    ID_ILISKI NUMBER,
    IHLSIRA NUMBER(1) default 0,
    CEVAP VARCHAR2(200)
    insert into IHALE_KATILIMCILAR (KULADI, SONUC, AKTIF, SRKTKODU, SONBULUNMAZAMANI, SIRA, MESAJ, ID, IHLKODU,
    IHLALTKTGKODU, ID_ILISKI, IHLSIRA, CEVAP)
    values ('asd', null, 1, '4444', to_date('19-02-2008 10:29:44', 'dd-mm-yyyy hh24:mi:ss'), 0, 'süre talep 2', 76, 145,
    '135', 345, 0, 'al sna süre 77');
    insert into IHALE_KATILIMCILAR (KULADI, SONUC, AKTIF, SRKTKODU, SONBULUNMAZAMANI, SIRA, MESAJ, ID, IHLKODU,
    IHLALTKTGKODU, ID_ILISKI, IHLSIRA, CEVAP)
    values ('asd', null, 1, '4444', to_date('20-02-2008 14:49:52', 'dd-mm-yyyy hh24:mi:ss'), 0, null, 77, 145, '135',
    345, 0, null);
    insert into IHALE_KATILIMCILAR (KULADI, SONUC, AKTIF, SRKTKODU, SONBULUNMAZAMANI, SIRA, MESAJ, ID, IHLKODU,
    IHLALTKTGKODU, ID_ILISKI, IHLSIRA, CEVAP)
    values ('asd', null, 1, '4444', to_date('19-02-2008 10:29:44', 'dd-mm-yyyy hh24:mi:ss'), 0, null, 78, 145, '135',
    345, 0, null);
    insert into IHALE_KATILIMCILAR (KULADI, SONUC, AKTIF, SRKTKODU, SONBULUNMAZAMANI, SIRA, MESAJ, ID, IHLKODU,
    IHLALTKTGKODU, ID_ILISKI, IHLSIRA, CEVAP)
    values ('asd', null, 1, '4444', to_date('19-02-2008 10:29:44', 'dd-mm-yyyy hh24:mi:ss'), 0, null, 79, 145, '135',
    345, 0, null);
    insert into IHALE_KATILIMCILAR (KULADI, SONUC, AKTIF, SRKTKODU, SONBULUNMAZAMANI, SIRA, MESAJ, ID, IHLKODU,
    IHLALTKTGKODU, ID_ILISKI, IHLSIRA, CEVAP)
    values ('KEMMM', null, 0, '42', to_date('17-03-2008 09:29:20', 'dd-mm-yyyy hh24:mi:ss'), 0, null, 63, 141, '134',
    191, 0, null);
    insert into IHALE_KATILIMCILAR (KULADI, SONUC, AKTIF, SRKTKODU, SONBULUNMAZAMANI, SIRA, MESAJ, ID, IHLKODU,
    IHLALTKTGKODU, ID_ILISKI, IHLSIRA, CEVAP)
    values ('MLK', null, 1, '46', to_date('07-03-2008 09:52:20', 'dd-mm-yyyy hh24:mi:ss'), 0, null, 64, 141, '134', 192,
    0, null);
    insert into IHALE_KATILIMCILAR (KULADI, SONUC, AKTIF, SRKTKODU, SONBULUNMAZAMANI, SIRA, MESAJ, ID, IHLKODU,
    IHLALTKTGKODU, ID_ILISKI, IHLSIRA, CEVAP)
    values ('KEM.ESM', null, 1, '44', to_date('06-03-2008 13:28:50', 'dd-mm-yyyy hh24:mi:ss'), 0, null, 61, 145, '135',
    189, 0, null);
    insert into IHALE_KATILIMCILAR (KULADI, SONUC, AKTIF, SRKTKODU, SONBULUNMAZAMANI, SIRA, MESAJ, ID, IHLKODU,
    IHLALTKTGKODU, ID_ILISKI, IHLSIRA, CEVAP)
    values ('KE.ES', null, 1, '45', to_date('07-03-2008 11:16:41', 'dd-mm-yyyy hh24:mi:ss'), 0, null, 69, 141, '133',
    197, 0, null);
    insert into IHALE_KATILIMCILAR (KULADI, SONUC, AKTIF, SRKTKODU, SONBULUNMAZAMANI, SIRA, MESAJ, ID, IHLKODU,
    IHLALTKTGKODU, ID_ILISKI, IHLSIRA, CEVAP)
    values ('KEMMM', null, 0, '42', to_date('17-03-2008 09:29:20', 'dd-mm-yyyy hh24:mi:ss'), 0, null, 65, 141, '132',
    193, 1, null);
    insert into IHALE_KATILIMCILAR (KULADI, SONUC, AKTIF, SRKTKODU, SONBULUNMAZAMANI, SIRA, MESAJ, ID, IHLKODU,
    IHLALTKTGKODU, ID_ILISKI, IHLSIRA, CEVAP)
    values ('KE.ES', null, 1, '45', to_date('07-03-2008 11:16:41', 'dd-mm-yyyy hh24:mi:ss'), 2, null, 66, 141, '132',
    194, 1, null);
    insert into IHALE_KATILIMCILAR (KULADI, SONUC, AKTIF, SRKTKODU, SONBULUNMAZAMANI, SIRA, MESAJ, ID, IHLKODU,
    IHLALTKTGKODU, ID_ILISKI, IHLSIRA, CEVAP)
    values ('MLK', null, 1, '46', to_date('07-03-2008 09:52:20', 'dd-mm-yyyy hh24:mi:ss'), 0, null, 67, 141, '132', 195,
    1, null);
    insert into IHALE_KATILIMCILAR (KULADI, SONUC, AKTIF, SRKTKODU, SONBULUNMAZAMANI, SIRA, MESAJ, ID, IHLKODU,
    IHLALTKTGKODU, ID_ILISKI, IHLSIRA, CEVAP)
    values ('KEMMM', null, 0, '42', to_date('17-03-2008 09:29:20', 'dd-mm-yyyy hh24:mi:ss'), 0, null, 68, 141, '133',
    196, 0, null);
    insert into IHALE_KATILIMCILAR (KULADI, SONUC, AKTIF, SRKTKODU, SONBULUNMAZAMANI, SIRA, MESAJ, ID, IHLKODU,
    IHLALTKTGKODU, ID_ILISKI, IHLSIRA, CEVAP)
    values ('KEM.ESM', null, 1, '44', to_date('12-03-2008 15:00:58', 'dd-mm-yyyy hh24:mi:ss'), 0, null, 70, 142, '252',
    198, 1, null);
    insert into IHALE_KATILIMCILAR (KULADI, SONUC, AKTIF, SRKTKODU, SONBULUNMAZAMANI, SIRA, MESAJ, ID, IHLKODU,
    IHLALTKTGKODU, ID_ILISKI, IHLSIRA, CEVAP)
    values ('KE.ES', null, 1, '45', to_date('10-03-2008 10:08:17', 'dd-mm-yyyy hh24:mi:ss'), 0, null, 71, 142, '252',
    199, 1, null);
    insert into IHALE_KATILIMCILAR (KULADI, SONUC, AKTIF, SRKTKODU, SONBULUNMAZAMANI, SIRA, MESAJ, ID, IHLKODU,
    IHLALTKTGKODU, ID_ILISKI, IHLSIRA, CEVAP)
    values ('KEM.ESM', null, 1, '44', to_date('10-03-2008 10:08:56', 'dd-mm-yyyy hh24:mi:ss'), 0, null, 72, 143, '253',
    200, 1, null);
    insert into IHALE_KATILIMCILAR (KULADI, SONUC, AKTIF, SRKTKODU, SONBULUNMAZAMANI, SIRA, MESAJ, ID, IHLKODU,
    IHLALTKTGKODU, ID_ILISKI, IHLSIRA, CEVAP)
    values ('MLK', null, 1, '46', to_date('12-02-2008 13:34:40', 'dd-mm-yyyy hh24:mi:ss'), 0, null, 73, 143, '253', 201,
    1, null);
    insert into IHALE_KATILIMCILAR (KULADI, SONUC, AKTIF, SRKTKODU, SONBULUNMAZAMANI, SIRA, MESAJ, ID, IHLKODU,
    IHLALTKTGKODU, ID_ILISKI, IHLSIRA, CEVAP)
    values ('KE.ES', null, 1, '45', to_date('06-03-2008 14:09:40', 'dd-mm-yyyy hh24:mi:ss'), 0, null, 60, 145, '136',
    188, 1, null);
    insert into IHALE_KATILIMCILAR (KULADI, SONUC, AKTIF, SRKTKODU, SONBULUNMAZAMANI, SIRA, MESAJ, ID, IHLKODU,
    IHLALTKTGKODU, ID_ILISKI, IHLSIRA, CEVAP)
    values ('KEM.ESM', null, 1, '44', to_date('06-03-2008 13:28:50', 'dd-mm-yyyy hh24:mi:ss'), 0, null, 74, 145, '136',
    202, 1, null);
    insert into IHALE_KATILIMCILAR (KULADI, SONUC, AKTIF, SRKTKODU, SONBULUNMAZAMANI, SIRA, MESAJ, ID, IHLKODU,
    IHLALTKTGKODU, ID_ILISKI, IHLSIRA, CEVAP)
    values ('KE.ES', null, 1, '45', to_date('06-03-2008 14:09:40', 'dd-mm-yyyy hh24:mi:ss'), 0, null, 75, 145, '135',
    203, 0, null);
    Thanks...

    What version of SQLServer do you have? Datediff is not an Oracle built-in function.
    OP:
    THe difference between two dates in Oracle is in days. The decimal portion refers to partial days, so you need to convert that to the required precision. Also, both sysdate and your column are date type, and contain a time portion, so you do not need all the to_date/to_char stuff. Something like:
    SQL> SELECT end_dt, start_dt, (end_dt - start_dt) * 24*60 diff
      2  FROM (SELECT sysdate end_dt, TRUNC(sysdate) start_dt
      3        FROM dual);
    END_DT             START_DT                 DIFF
    17-mar-08 10:39:39 17-mar-08 00:00:00     639.65John

  • When retrieving a 'date time' value, why is there a '.0' appended?

    Hi
    I am storing 'date time' values in a MySQL 'DATETIME' column.
    I retrieve the value by executing code (more or less) like this:
    ResultSet resultSet = statement.executeQuery(query);
    // other statements here...
    String theDate = resultSet.getString(i);If the 'date time' being stored is *2008-08-26 16:39:21*, the code returns this: *2008-08-26 16:39:21.0*
    Is there same 'simple' way to retrieve the value without a *.0* appended?
    Thanks
    Pete

    Hi Roy
    I'm not quite with you.
    You should get it from the database as a date object.Do you mean something like this?:
    ResultSet.getDate()This returns a java.sql.Date object.
    For presentation use SimpleDateFormatter to display it the way you want toI presume you are referring to java.text.SimpleDateFormat ? In that case I require the date as a java.util.Date object.
    Perhaps you could clarify a bit more?
    Thanks
    Pete

  • Invalid date/time value error

    I downloaded a trial version of Acrobat XI Pro when I try to save or edit and resave a document I get 'invalid date/time value', error.  I presume it's set for the US and not the UK, can you tell me where I can change the date/time format?
    I'm running on Windows 7

    Hi Rave
    Susan's on leave at the moment so I'm replying on her behalf in the vain hope we can sort things before she gets back and before the trial period runs out!  I'm not sure I understand what you mean by column of date and time - we have a review date in the Word document before we pdf but that's all.  Yes we are saving to a sharepoint server.
    Thanks

  • Problem with DateDiff and Date/Time value.

    The form below displayed perfectly until I added the line for DateDiff between VacStart and VacEnd. I receive an error message;
    An error occurred while evaluating the expression:
    #DateDiff("w", "VacStart", "VacEnd")#
    Error near line 48, column 51.
    Parameter 2 of function DateDiff which is now "VacStart" must be a date/time value
    The error occurred while processing an element with a general identifier of (#DateDiff("w", "VacStart", "VacEnd")#), occupying document position (48:50) to (48:86).
    I have tried changing the DB value to Date/Time as well as Text and get the same result each time. Any help would be greatly appreciated. Here is my code:
    <cfquery datasource="manna_premier" name="TM_log">
    SELECT *
    FROM TMStatusLog
    </cfquery>
    <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
    <html xmlns="http://www.w3.org/1999/xhtml">
    <head>
    <meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1" />
    <title>TM Status Log</title>
    </head>
    <body>
    <p align="center" class="style4">Territory Manager Status Log </p>
    <table width="1448" border="0">
      <tr>
        <th width="71"><span class="style3">ID No.#</span></th>
    <th width="88"><span class="style3"> Date</span></th>
    <th width="166"><span class="style3">TM Name</span></th>
    <th width="129"><span class="style3">Status</span></th>
    <th width="139"><span class="style3">Vac Start </span></th>
    <th width="137"><span class="style3">Vac End</span></th>
    <th width="203">Ttl Days </th>
    <th width="203"><span class="style3">DSR Ride Along Name</span></th>
    <th width="274"><span class="style3">Service Call Name</span></th>
      </tr><cfoutput query="TM_log">
      <tr>
        <td><span class="style3">#ID#</span></td>
        <td><div align="center"><span class="style3">#DateFormat(LogDate, "mm/dd/yyyy")#</span></div></td>
        <td><div align="center"><span class="style3">#TerritoryManager#</span></div></td>
        <td><div align="center"><span class="style3">#Status#</span></div></td>
        <td><div align="center"><span class="style3">#DateFormat(VacStart, "mm/dd/yyyy")#</span></div></td>
        <td><div align="center"><span class="style3">#DateFormat(VacEnd, "mm/dd/yyyy")#</span></div></td>
    <cfif VacStart IS NOT "Null">
        <td><div align="center"><span class="style3">#DateDiff("w", "VacStart", "VacEnd")#</span></div></td>
    </cfif>
        <td><div align="center"><span class="style3">#DSRName#</span></div></td>
        <td><div align="center"><span class="style3">#ServiceName#</span></div></td>
      </tr></cfoutput>
    </table>
    </body>
    </html>

    Error Diagnostic Information
    An error occurred while evaluating the expression:
    #DateDiff("w", VacStart, VacEnd)#
    Error near line 47, column 48.
    Parameter 2 of function DateDiff which is now "" must be a date/time value
    The error occurred while processing an element with a general identifier of (#DateDiff("w", VacStart, VacEnd)#), occupying document position (47:47) to (47:79).
    Any other suggestions? Thanks!
    Well... what does the error message say?
    Parameter 2 of function DateDiff which is now "" must be a date/time value
    What does this tell you?  What is parameter 2 of that function call?  It's VacStart.  So it's saying VacStart is an empty string, and it's saying an empty string is not a valid value for that parameter.
    So the question you need to ask yourself is whether you expect VacStart to be an empty string?  Or do you perhaps expect it to be a date?  I would guess you're expecting it to be a date.  So the question becomes... Why is VacStart an empty string?
    Adam

  • Problem in storing date & Time value

    How to store the Date & time value in 1 textfield only.In my case i am selectecting The Time from two LOV's (HH & MM),then Date value is selecting from simple i/ptext,
    I want to store the (Date+HH+MM) in the date field.......
    code is....
    public String CalculationM() {
    BindingContainer bindings = getBindings();
    DCIteratorBinding dcIterBinding = (DCIteratorBinding)bindings.get("Timeview1Iterator");
    RowSetIterator row= dcIterBinding.getLovRowSetIterator();
    String i=selectOneChoice5.getValue().toString();
    int index=Integer.parseInt(i);
    int index2=index+1;
    Row r= row.getRowAtRangeIndex(index2);
    String val=r.getAttribute("Hour").toString();
    String i1=selectOneChoice6.getValue().toString();
    // System.out.println("HH index="+index2+" MM index is="+i1);
    int index1=Integer.parseInt(i1);
    int index3=index1+1;
    Row r1=row.getRowAtRangeIndex(index3);
    String val1=r1.getAttribute("Minutes").toString();
    int valint=Integer.parseInt(val);
    String valnew;
    if(valint<=12)
    {  if(valint==12)
    valnew=val+":"+val1+":"+"PM";
    else
    valnew=val+":"+val1+":"+"AM";
    else
    val=String.valueOf((valint-12));
    valnew=val+":"+val1+":"+"PM";
    valnew=val+val1;
    String Dateis= inputText4.getValue().toString();
    String Date1=Dateis+" "+valnew;
    System.out.println("TOTAl Date Is="+Date1);
    try
    { SimpleDateFormat sdf = new SimpleDateFormat("dd:MM:yyyy hh:mm");
    java.util.Date date = sdf.parse(Date1);
    java.sql.Date sqlDate = new java.sql.Date(date.getTime());
    oracle.jbo.domain.Date ojdd = new oracle.jbo.domain.Date(sqlDate);
    FacesContext context = FacesContext.getCurrentInstance();
    Application app = context.getApplication();
    DCBindingContainer binding = (DCBindingContainer) app.getVariableResolver().resolveVariable(context, "bindings");
    binding.findIteratorBinding("AppointDetView1Iterator").getCurrentRow().setAttribute(7,ojdd);
    catch(ParseException e)
    System.out.println("Error is:"+e.toString());
    OperationBinding operationBinding =bindings.getOperationBinding("Commit");
    Object result = operationBinding.execute();
    if (!operationBinding.getErrors().isEmpty()) {
    return null;
    return null;
    But i am getting error ....the Time is not storing in Date field bt the Time which we r giving with the Date field is storing.......
    My Date Attribute has Date format as dd-MM-yyyy hh:mm:aa
    If i changed it to dd-MM-yyyy then .... The value "12-3-2008" is not a valid date. Valid example: "29-11-2005 ".this error is getting
    Error
    - Not a date.
    Plz help me in this case ...wil be very thankful for ur help.........

    actually i am inputting the value 12-03-2008 but i am getting tha error which i hav told before....
    plz reply me....
    Message was edited by:
    user553181

  • Time values in logged thermocouple data not realistic

    I'm in desperate need of LabVIEW programming help!  When the run arrow is clicked, my VI is designed to simultaneously start logging filtered thermocouple data and send a TTL-type pulse out of a CTR port on my ELVIS II+.  The pulse part of my code works fine (it's from an example VI), but the thermocouple part has a big issue.  The temperature data logs correctly, but the times associated with each data point are completely wrong.  I measured the time I ran my code the most recent time--it was about 20 seconds.  The logged data shows what appear to be the correct number of data points, but the last time value is only 2.88 seconds.  I have a feeling the filter might be part of the issue, but I don't know how to fix it.  I would be so completely grateful for any help anyone can provide!  My VI and LVM output files are attached.
    Megan
    Attachments:
    TC.SPEC.DAQ_MKT_20140211.vi ‏96 KB
    MENG352TC1_TCProgram.csv ‏10 KB

    It sounds as though you may have two separate problems. One is the timing of readings and file updates and the other is what you are calling "unstable" readings.
    Please provide some numerical values for the "unstable" readings. What do you mean by "exponentially high or low values?"  Obviously you expect the values to change when you touch the thermocouple. If the readings are way out of range (much different from your finger temperature), the problem is likely in hardware and should be corrected there, if possible, rather than trying to "filter it out" later. Filters tend to not be good ways to handle impulse-like interference. The transient response of the filter is excited by the impulse and you have to wait for it to die out. 
    Please post some data which shows one or more fo the instabilities, along with your estimate of wht the actual temperatures should have been.
    There are many ways to address the timing issues. First, define both the slowest and the fastest frequencies from which you will alow the user to select for temperature readings. You indicated that one reading every 5 seconds is the slowest. What is the fastest? How many options wil the user have between those limits? What else does the system do besides the temperature measurements? Will the user change the rate while the program is running or only before starting the acquisition?
    Lyn

  • Metric shows real time value but does not show historical data

    I am using OEM 12c.I am facing an issue and I don't know where to look for problem.
    I had created one customized metric for percentage flash recovery area through metric extension.I deployed to it target databases.
    When I check it through Database --> All Metrics it shows me real time value for metric,Collection schedule,upload interval and last upload time.IT is all fine.
    When I check metric value history,
    For all the columns like Last Known Value,
    Collection Time stamp,
    Average Value,
    High Value,
    Low Value
    it shows no data.It even does not show anything in Metric Value History graph.
    Even the metric test in Metric Extension works fine.
    All the client agents are uploading the the data to OEM successfully.
    Any help,guide is appreciated.

    bit late but there are two options on metric creation "Alerting Only" or "Alerting and Historical Trending" - I assume you need the latter to show history so was this option used?

  • Getting a Time value from a datetime data type in SQL Server - URGENT!

    Hi guys
    I have an urgent issue here -
    I have a datetime data type in a SQL Server database. The field holds both a time, and a date within it.
    I am able to pull the date out of the field by using:
    Date sDate = Date();
    while (gd.next()) {
    sDate = gd.getDate(2);
    how do this with the time????
    Thanks

    Hi,
    The funny part here is that you have already done it! The API is a great thing to use to help in your programming.
    API: The class Date represents a specific instant in time, with millisecond precision.
    You want time, you got it! How about:
    sDate.getTime();
    sDate.getMinutes();
    sDate.getHours();
    sDate.getSeconds();
    Not enough?

  • Error Missing parameter values - I get this in 11g app server only

    Hi.. I had an application in JSP-Struts, previously on 10g app server.  I now migrated the code into 11g. 
    I get the error on CrystalViewer.jsp 
    Error
    Missing parameter values
    Steps that lead up to the error:
    The very first time anyone enters the application and clicks a submit button on the jsp, after entering data and/or picking from drop menus, the error shows up on a separate page (thrown by crystalViewer.jsp)
    When I get this error, and click the browsers back button, and simply click the submit button on the jsp screen again, the reports work fine (like they do in 10g).
    Tried the following:
    I used log4j and followed the data as it made its way from Struts to Crystal Factory.  But once it gets out of Struts, and forwards to Crystal, I receive the error from the CrystalViewer.jsp
    Next, I removed code in struts-action, that used crystal factory to 'set parameter', and didnt send any parameters, letting my crystal report bring back some random records.. And this works even the first submit!  So the problem is only when I have to send parameters to crystsl
    Additional info:
    I do not send any null values across, since I read on these forums that folks were having issues with setting nulls etc... I check for null and then force 'All' in the parameter if the user does not enter data or pick from the drop-down.
    I need help resolving this . Thanks and have a great day.
    (Are there any changes to be made to the Struts config, or any additions to Web.xml? Should Crystal reports be changed in anyway so they can function like they did in 10g?)

    The Crystal SDK doesn't know or care that you're using Struts. 
    The exception is stating you're not setting parameters. 
    So wherever you're trying to set parameters, whatever's reaching the viewer don't have them set.
    Why not trace the workflow to see what's where?
    Sincerely,
    Ted Ueda

  • Missing Parameter Values while using Change SubReport links

    Hi,
    I am using Change SubReport Links to pass data from Main Report to the SubReport. The report works fine at design time when I preview it, but at runtime I get "Missing Parameter Values" error.
    As I have used Chanage SubReport Links do I still need to pass the parameter to the SubReport from the code.
    cr.Export gives this error.
    Below is the code
    ExportOptions crExportOptions;
            DiskFileDestinationOptions crDiskFileDestinationOptions;
            string Fname = string.Empty;
            string strReportName = string.Empty;
            ReportDocument cr = new ReportDocument();
            string strReportPath = Request.PhysicalApplicationPath.ToString() + @"Members\Reports\UnPaidReceipt.rpt";
            if (!System.IO.File.Exists(strReportPath))
                throw (new Exception("Unable to locate report file:\n" + strReportPath));
            cr.Load(strReportPath);
            MtollBLL Unpaid = new MtollBLL();
            cr.SetDataSource(Unpaid.GetUnpaidPayments().DefaultView.Table);
            // Set the Crytal Report Viewer control's source to the report document.
            CrystalReportViewer1.ReportSource = cr;
            MtollBLL Violation= new MtollBLL();
            cr.Subreports[0].SetDataSource(Violation.GetReportViolation().DefaultView.Table);
            // cr.PrintToPrinter(1, False, 0, 0)
            Response.Write( cr.Subreports[0].DataDefinition.ParameterFields.Count);
            Fname = Request.PhysicalApplicationPath.ToString() + Session.SessionID.ToString() + ".pdf";
            crDiskFileDestinationOptions = new DiskFileDestinationOptions();
            crDiskFileDestinationOptions.DiskFileName = Fname;
            crExportOptions = cr.ExportOptions;
            crExportOptions.DestinationOptions = crDiskFileDestinationOptions;
            crExportOptions.ExportDestinationType = ExportDestinationType.DiskFile;
            crExportOptions.ExportFormatType = ExportFormatType.PortableDocFormat;
            cr.VerifyDatabase();
            cr.Subreports[0].VerifyDatabase();
            cr.Export();//' The following code writes the pdf file to the Clientu2019s browser
    Please Advise.

    Please post your SDK development questions to the Developers forum

Maybe you are looking for

  • HELP!!  Photoshop cs4 and Windows 8 - Printer Not Found

    Just installed PS cs4 on my new all-in-one with Windoz 8 and my cs4 is saying that there is no printer installed.  I can print from other sources like disks and picture viewer.  Are there any fixes for this???  I REALLY don't want to purchase yet ano

  • Placed PDF file prints jagged

    My company recently upgraded from Adobe Suite CS2 to CS4.  We also purchased a new printer.  I am still figuring out things but I haven't found a solution to my problem yet.  I am not sure if it is the program or the printer (Ikon Business Pro 560c -

  • Problem archiving file using FTP adapter

    Hi, I am polling some files from another server using FTP adapter in SOA 11g. Even though I have checked the option to archive the files, the files get archived successfully on the server where the SOA process is running, but I am unable to archive t

  • Net-SNMP 5.0.9 used in Solaris 10 sma

    We are using AgentX protocol in an application sub-agent According to Net-SNMP change log, AgentX protocol support was experimental up to release 5.0.7 but going to the following link: http://net-snmp.sourceforge.net/tutorial/tutorial-5/toolkit/demon

  • My 4215 all in one HP printer error message suddenly reads "remove and check right cartridge" .

    My all in one 4215 printer suddenly is flashing an error message in the screen saying "remove and check right cartridge"...For what I am checking it is unclear. I have removed and reinstalled the cartridge and it looks OK to me...It is not empty, and