Date Time Stamping issue

When I use select xyz_Date from abc table in coldfusion
cfquery tag, the out put comes as follows:
CF5 - '05-MON-2007'
CF8 - '2008-01-27 00:00:00.0'
Note: The xyz_Date is stored without time stamp in the
database.
both running on 10.2.0.3 Oracle version. This is creating
problem when inserting dates when we only use xyz_date as a value
to be inserted. It worked fine on CF5 but not on CF8 due to format
change. Is there a way to set it to behave like CF5. It appears
that the later is using JDBC driver.

I assume that your oracle field is a date field and not
varchar. Also, your xyz_date is a date object. The most important
thing to remember is that the format does not matter.
This will work - #xyz_date# (no quotes)
cfqueryparam will also work and has some performance
advantages.

Similar Messages

  • HCM Process & Forms: Date & Time Stamp issue in Prev Comments Box

    Hi
    We implemented HCM Process and Forms and we are in EHP4.  We need user name, date and time stamp in each step for audit purpose.
    Form Process Example:
    Step1: Manager -> Initiates a Form for employee pay/position changes  (REQUEST)
    Step2: 1-Up Manager -> Approves a Form for employee pay/position changes (APPROVE)
    Step3: HR Admin -> Process a Form for employee pay/position changes (PROCESS)
    Process Overview: HR Admin can open a form once all steps are completed and they want to see all 3 steps date & stamp here.
    New Comments -> To enter user comments in each step. Used data type HRASR_CURRENT_NOTE
    Previous Comments-> To display prev. step / user's comments including user name, date & time. Used data type HRASR_PREVIOUS_NOTES.
    I tried all different property settings in the form. May be I am still missing some property settings here.
    Issue:  If user enters any comments in "New Comments" box then only date & time stamp is coming along with their comments in "Previous Comments" otherwise not showing anything, just blank in the Prev. Comments.  I added some code in form script in case no data in "New Comments" then default a value ":" . It is working fine for first step but not working the same for other 2 steps.
    Trying in different way:
    Creating 3 text fields in a form just for display purpose and modifying each field (data set) with some text (combination of user name, system date and time) at each stage/step in a BADI.
    Method: IF_HRASR00GEN_SERVICE~DO_OPERATIONS
    Here it is updating correctly for first step/stage (REQUEST) and other 2 fields are not updating accordingly. I did debug for each step and updating the data set correctly but finally not dispalying the valuse in a form except first field.
    Can someone please share your ideas or inputs.
    Appreciate your time & help!
    Thanks
    Hari

    Hi Sahir
    Thank you for your reply.
    As I explained in my post, user details with date & stamp are coming when user enters some comments otherwise it is blank., All users may not enter comments because it is not a "required".
    HR is needed this for audit purpose, just at end of the process they need to see all user names, date & stamp in the form. Forget about comment boxes, Can't we make just simple text fields with user details for each step (all 3 stages)?
    FYI:
    Issue:  If user enters any comments in "New Comments" box then only date & time stamp is coming along with their comments in "Previous Comments" otherwise not showing anything, just blank in the Prev. Comments.  I added some code in form script in case no data in "New Comments" then default a value ":" . It is working fine for first step but not working the same for other 2 steps.
    Appreciate your inputs !
    Thanks
    Hari

  • LG Octane Camera Date/Time Stamp Issues

    The pics I take with my LG Octane are designated a number associated with the date/time the pic was taken (ex 0401121345, would be April 1, 2012 at 145pm). When I transfer the pics from my phones memory card to my computer and open the pics, I can see the pics info (date/time) and everything seems correct.
    The problem comes in when I load my pics onto a website that verifies the pics date/time thru the digital encoding on the pics file. (Digital Pics are encoded with date/time stamps that can be recognized with computer software). This website rejects my submitted pics from my LG Octane because this encoding is either not there or not set correctly. I had no issue previously when using my Samsung env last year. Please Help!

    I take it you are noticing that the photo shows in your gallery with the correct time for the name. But, when you look at the photos on your computer it is showing a time so many hours off (ie. phone shows 12:00 and computer shows 4:00). What it is actually doing is time stamping it for GMT for some reason.  This has been a problem for as long as I know. I have not found an answer and have come to believe there is not a way of changing the time/date stamp on the phone. I have not even found an app for it.
    Sorry I don't have an answer. But, maybe some one else will.

  • Date/time stamp issue when transferring vids/pics to computer. Help please.

    Hi, i am having an issue when transferring my vids/pics from my Z2 to my PC.
    On all my previous phones when transferring media to my PC it would be copied and labelled with a date stamp followed by a picture number- an example being 2014-01-13- 0123. This has always made organising and finding my pics/vids in there relavent folders an eay task.
    The problem i am now faced with is when i transfer pics/vids from my Z2.  The pictures are stamped with DSC_0001 for example and the videos with MOV_0001. This means when on my PC i have to examine each file individually to find out its date and time of origin.
    Even more of an headache is everytime i have transferred files from my Z2 and then take more pics/vids and then try to transfer them to my PC the computer will not allow transfer as the stamp on the file i am transferring from my Z2 eg - DSC_0001 is already present on the PC from a previous transfer. This means i have to rename all the PC files first.
    I hope this makes sense and hopefully there is an easy fix.
    I am new to Android and overall i am very happy with the operating system, being a massive improvement generally over my previous phones. Fingers crossed this is down to my lack of knowledge and just involves a settings change somewhere.
    Thanks in advance for any help.

    Hi.
    The case you described is right. But it´s not a bug.
    Why don´t you organise your pics/vids on your desktop with picasa for example. There you have many tools, also to rename your files, so that the filename contains the creation date.
    Or you use a cloud solution like dropbox, google+ or amazon clouddrive to sync pics/vids from your phone automatically.
    But never use the built-in sony playmemories. It´s really slow, pics are down-scaled to 1280x720 and vids are not synced. It´s the worst cloud-service for pics I´ve seen.
    Best
    arni

  • FileMonitor issue for date time stamp change.

    Hi I have an app that runs with a minor issue and I am looking for some insight for a workaround or code change.
    I have a File Monitor that checks a specific directory every second.
    Users send a batch run to this directory throughout the day. There are two types of files, .ZIPs and .DONEs.
    So for each .ZIP a .DONE is sent to notify the app it can begin to process the file.
    Here is what I receive
    /elements/process/File1.ZIP     Oct 15 08:19
    /elements/process/File1.DONE     Oct 15 08:19
    The problem I am encountering is sometimes the .DONE and. ZIP are sent and the date time stamp of both files are the same so when the monitor reads the directory it looks like there is no change so both files sit in the directory and do not process. To make this work, I usually go in and touch a file to change the date time stamp.
    This is a java app that runs on an AIX box.
    Here is my code, is there anything any once can suggest to help me out. Thanks in advance.
       * Subclass of FileMonitor, Handles the timer event
       * @param none
      private class FileMonitorNotifier extends TimerTask
        public void run()
          // Loop over the registered files and see which have changed.
          // Uses the Modifed DateTimeStamp to determine if there was a change.
          // Use a copy of the list in case listener wants to alter the
          // list within its fileChanged method.
            try
                Collection files = new ArrayList (hmFiles.keySet());
                for (Iterator i = files.iterator(); i.hasNext(); )
                    File file = (File) i.next();
                    long lastModifiedTime = ((Long) hmFiles.get (file)).longValue();
                    long newModifiedTime  = file.exists() ? file.lastModified() : -1;
                    //      Check if file has changed
                    if (newModifiedTime != lastModifiedTime)
                        //      Register new modified time
                        hmFiles.put(file, new Long (newModifiedTime));
                        // Notify listeners
                        for (Iterator j = colListeners.iterator(); j.hasNext(); )
                            WeakReference reference = (WeakReference) j.next();
                            FileListener listener = (FileListener) reference.get();
                            // Remove from list if the back-end object has been GC'd
                            if (listener == null)
                                j.remove();
                            else
                                listener.fileChanged (file);
            catch(Exception ex)
                 m_odLaunch.logError(OdIntegrationConstants.ERROR_LEVEL_MIDLEVEL, ex);
         }

    Yes, I guess you are right, I don't care what time each file came, as long as I have both I can being to unzip and process and delete the .DONE.
    The code itself was based on if a filechanged then do work.... I could just take this out. Thanks!
    * This is the main entry point when there is a change to the modified date/time
    *  of the monitor directory
    * @param file directory we are monitoring
         public void fileChanged (File file)
              StringBuffer sbMessage;
              try
                   sbMessage = new StringBuffer();
                   //Make sure this is a Directory
                   if(file.isDirectory())
                        //Return list of files with extension we are looking for
                        File[] arFiles = file.listFiles((FilenameFilter)new FileSuffixMonitor(m_odLauncher));
                        for(int i=0;i < arFiles.length;i++)
                             sbMessage.append("Found file association to move-" );
                             sbMessage.append(arFiles.toString());
                             m_odLauncher.logInstance(sbMessage.toString());
                             processMoveFile(arFiles[i]);
              catch(Exception ex)
              sbMessage = null;

  • How do you vary the Date/Time stamp format in File Adapters

    In the receiver channel of the File Adapter where you specify the 'File Name Scheme', you do have the option of specifying a 'File Construction Mode' of 'Add Time Stamp'.  How can you specify a different Date/Time stamp format ( eg MM/DD/YY vs YYYYMMDD vs MMDDYY, etc. ) without changing the Date/Time stamp for the entire SAP system?  Also, can you control where the Date/Time stamp appears in the filename?

    Hi,
    There are many threads discussing the same issue. Go thro the following:
    Dynamic file name (Date) in Receiver File Adapter
    Receiver File Adapter - TimeStamp
    Bhavesh's reply in above thread:
    You can use Adapter Specific Identifiers and then change the file name in the mapping. Append the tiem stamp in the format that you want and so on.
    Just use this code in an UDF,
    DynamicConfiguration conf = (DynamicConfiguration) container.getTransformationParameters().get(StreamTransformationConstants.DYNAMIC_CONFIGURATION);
    DynamicConfigurationKey key = DynamicConfigurationKey.create("http://sap.com/xi/XI/System/File","FileName");
    String SourceFileName = conf.get(key);
    java.text.SimpleDateFormat dateformat = new java.text.SimpleDateFormat( "yyyyMMdd" );
    dateformat.format( new java.util.Date() );
    String newfilename=SourceFileName+dateformat;
    // change to new file name
    conf.put(key, newfilename);
    return "";
    Regards,
    P.Venkat

  • Save the file and give date & time stamp

    1. Reading the Excel file from the selection screen as a parameter.
    2. Using F.M. ALSM_EXCEL_TO_INTERNAL_TABLE reading Excel file into
        Internal table.
    3. Implementing the Business Logic.
    4. Move output to Final Internal table.
    5. Final internal table should generate a Flat file. By using GUI_DOWNLOAD.
    6. That flat file should be saved with the name and location given in the Excel.
    7. When ever I run the program output file will generate in the same location but with date and time stamp. Because I’m running the program for range of employees say initially I run for 1 – 10,000 employees next 10,001- 20,000 like that.
    Whenever I run for 2nd time it will overwrite the previous output, that’s the reason I’m using date and time stamp.
    Eg:
    PERSONAL Numbers              Name                                         Location
    00000001                 xxxxx-24.04.2007-10.30          C:\        
    00000002                 xxxxx-24.04.2007-10.35
    00000003                 xxxxx-25.04.2007-10.40
    00000004                                  xxxxx-25.04.2007-10.30
    Can any one help me how to save the file and give date & time stamp through hardcode?
    please help me in this issue.

    I am not clear with your problem. Based on the understanding of your question,
    there  can be two cases.
    1- U want to insert time stamp in the output file.
    2- Time stamp is already there, u just have to solve the overwriting issue.
    If your question goes with option 2, You can make use of import parameters
    <b>CONFIRM_OVERWRITE</b> : Which will ask for confirmation before overwriting.
    <b>APPEND</b> : which you can choose either to append the data to the existing file or overwrite it.
    Please inform if the issue is not resolved.
    Message was edited by:
            BINU RAJ BINU

  • Error messages when sending date-time stamp to Oracle Database

      I have a complex application that communicates with an Oracle database.  One of the table values that gets written to the table is a date-time stamp.  Until recently, the user only required a date, and this was never an error. (The format String used was %d-%b-%Y)  Now they need a time-stamp as well, so I attempted to edit the format string input of the format date/time string function to include the time. I have tried numerous format strings, each of which returns an error on execution.  Depending on which format I use, I get one of 3 different error messages.  The really odd thing is that both the date and time always get stored in Oracle without any problem (regardless of what date-time I use, as long as I include the date and any part of a time stamp - I get the entire timestamp even if I only include %I for the hour).  The only issue is that LabVIEW generates an ODBC error if I try to include the time to the date-time stamp.  In other words, teh date/time stamp writes to the Oracle database, but an ODBC error occurs every time.  I've included a word doc with screen captures of the format strings used, the resultant date/time stamps written to Oracle and the error messages generated within LabVIEW. Any advice would be most appreciated.
    Attachments:
    Summary of ODBC Error messages related to date-time stamp.doc ‏65 KB

    Oracle has a standard date format: 12-Mar-2009 that it accepts as a string, but if you want more than that, you need to use the todate() function. I used this string going into the standard LabVIEW ''Format date/time sting vi' 
    to_date('%d-%b-%Y %H:%M:%S', 'DD-MON-YYYY HH24:MIS') to create the value needed for Oracle.
    Then I use standard format string to create SQL: insert into mytable (mydate) values(%s) and select * from my table where mydate = %s using the string above for %s.
    I think you can also define a global format for all time strings but I haven't bothered figuring that out.

  • Formatted Search - Date Time Stamps

    Hi,
    We are trying to use a Date & Time Stamp for two udf's of which I will then calculate the difference in a report. I have a couple of issues. Ideally the user would enter the Start field (udf1), click Shift-F2 and that udf would be populated with a Date/Time Stamp like: 07/12/09 14:30:00 or 07/12/09 02:30PM. The user would also do the same thing for the End field (udf), so I end up with two udf's that both hold a Date/Time Stamp described above.
    1 - It looks like I will either need two udf's each for both stamps, one for the Date (date field type) and one for the Time (hour field type)...or I will need to use an alphanumeric field type to hold the whole timestamp. When using the hour field type I still have some issues.
         and
    2 - I can't seem to get the right sql (sbo query) function to return the date/time stamp and / or I can't cast it or format it the way I would like.
    -If the udf is date field, I can use the GetDate function, but it doesn't seem to get the time with it or the field isn't big enough or formatted properly.
    -If the udf is an alphanumeric field, I cast the GetDate function as nvarchar and it returns the date/time stamp, but it is an alpha field and the date is Jul 21 2009  4:41PM. I don't like the Jul 21 2009 formatting
    -If I use two fields, one for date (date type) and one for time (hours type), the date is formatted the way I like, but the hours field doesn't display the AM or PM and my formatted search doesn't return military time (14:00 instead of 2:00PM), so I can't tell if 2:00 is morning or afternoon.
    So I guess my questions are pretty general...Am I using the correct field types? Any suggestions on what to use? Are there any other ways to format this data? Not all date functions or casts (time, smalldatetime) work in the sbo query so I am looking for options. Any suggestions on what functions or cast to use?
    Thanks

    Hi,
    As you already aware, within B1 you may not treat datetime field easily.  For one of your request: I don't like the Jul 21 2009 formatting.  You could use function such as
    Select CONVERT(nvarchar(30), GETDATE(),106)
    to change it to 21 Jul 2009.
    Thanks,
    Gordon

  • Maintain Date/Time Stamp in Export as XML

    Hello,
    I've create a report which has a field as mm/dd/yyyy HH:mm.
    When I export as .TXT .CSV, Excel ect it maintains the format; however when I export as XML I loose the formate and it exports as mm/dd/yyyy 12:00:00
    The below in anyother format or in BusinessObjects would be 09/04/2007  10:38.
    <COLUMN INDEX="6" ID="4" TYPE="Date" FORMAT="m/d/yyyy  hh:mm:ss  AM/PM">Actual Start (Date & Time)</COLUMN>
    <CELL INDEX="6">9/4/2007 12:00:00 AM</CELL>
    Any thoughts?
    As well is it possible to customize tags of the exported XML so it is more of a XML document then a spreadsheet.

    Thank you!
    For the issue with the Date/Time stamp is this a bug in older versions? I am using BusinessObjects 6.1; the only time it does this is when exported as XML
    Cheers,
    Tim
    Edited by: Tim Whitehead on Jul 13, 2008 7:17 PM

  • How to print date & time stamp on photos?

    How to print date & time stamp on photos?

    Three methods:
    File>process multiple files>labels. Be sure to uncheck "same as source", or the originals will be overwritten. It is best to work on duplicate files, esp. while learning.
    Use the horizontal or vertical type tool to add the information manually to each picture file
    If the same information is to be applied to several pictures, e.g. a copyright notice, use  of a brush made in PSE is very efficient

  • The export file from a calc script - naming and date/time stamp

    Here is a simple calc script to export data.
    2 questions:
    1. Is there an easy way to add a date/time stamp on the name of the data file so that it does not overwrite the older ones every time?
    2. I tried to specify the path so that it write to another server. "\\mfldappp011\E:\Exp_AW.txt". It's not working. How should I specify the path ?
    Fix (@Relative("Yeartotal",0),"Actual","Working",&ActualYear);
    Dataexport "file" "," "C:\Exp_AW.txt" "#MI";
    EndFix;
    Edited by: user9959627 on Sep 7, 2012 11:25 AM

    Probably easiest to call the maxl script from a command line script, then rename the exported file to include the tme stamp and copy/move it to a location.
    Cheers
    John
    http://john-goodwin.blogspot.com/

  • How do I to get the date/time stamp back on my texts in ioS7?

    I've looked and looked to find an option and I can't seem to locate one.  Does anyone know how to put the date/time stamp back...?  It does appear in, but not consistently.

    Swipe right to left and they will appear as you need them.

  • Need to add date/time stamp to file name without time change creating new files

    We have setup our application to save data once a trigger event occurs. We also need the date/time stamp as part of the file name. We used Format Date/Time String and concatenated it into the file name. It all works good, but as the time changes (seconds, minutes, etc.) it causes the Write to File to create a new file with the new filename. Is there a way to create the file and save/latch/buffer the time in the file name so that it doesn't create a new file for every second?
    I've attached a shot of the relevant part of our VI. It's all in a big while loop. The data save is in a case/switch so that when it is triggered it starts saving. (The for loop is to split the data up
    into 4 different files). Like I said, it all works except new files are created every second as the time changes instead of just putting it all in one file with the initial time in the file name.
    Attachments:
    TimeInFileNameQuestion.jpg ‏46 KB

    I need a loop in order to use a shift register. I cannot stop the outer while loop (because it would stop the hardware from collecting data), and I cannot add loops inside which bogs down the processor to where the app stops. I've attached a simpler version of my VI which illustrates the problem. While the button is pressed (the trigger) it should save the data (in this case just cycle numbers) into one file with the initial date/time. But, you can see that it creates 1 file/second. I tried using shift registers, but without adding extra loops I can't see how to do it. Thanks
    Attachments:
    FileNameTest.vi ‏29 KB

  • How to add date/time stamp to PDF in Acrobat 9 Pro?

    Hello,
    I'd like to add a date/time stamp to a PDF so that when I print the document, the current date/time will be printed as well.  Is it possible to do this?  I found the following posting (http://forums.adobe.com/thread/502915), but am not able to get it to work for me.  I don't really know anything about using Javascript.  Any help would be much appreciated.
    Thanks!

    Not sure it will work, but you can try using the app.hideMenuItem() method. See reference here.

Maybe you are looking for