help convert the date please

I have 3 possible length Dates stored in a field of VARCHAR2 type, I'm trying to convert that to a friend:

We are looking for this as a Date or a numeric field, or both in the end (this is what is needed)

YYYYMMDD 20110829

what I have is these different type of length on the ground:

8

13/07/13

9

30/06/2012

10

13/10/2011

Can someone help me convert this field is number: 20120512 or Date YYYYMMDD? the two examples would help too:-) learning

You can use the below to find the problem dates to your table. SELECT must of course be updated with your table/column names

CREATE OR REPLACE FUNCTION dateconvert(p_chardate  VARCHAR2)
RETURN VARCHAR2
AS
  v_date  DATE;
BEGIN
  v_date := TO_DATE(p_chardate, 'MM/DD/RR');

  RETURN 'OK';
EXCEPTION
  WHEN OTHERS THEN
    RETURN   p_chardate;
END;

SELECT datecol
FROM   datetable
WHERE dateconvert(datecol) != 'OK';

Tags: Database

Similar Questions

  • My watch clock: 2012,03,2012 at 20:10. How to get back the Date please.

    My watch clock: 2012,03,2012 at 20:10.  How to get back the Date please.

    http://www.ehow.com/how_2052285_change-time-date-Windows-XP.html

    http://support.Microsoft.com/kb/307938

    UTC/GMT is 20:12 on Friday, February 24, 2012

  • How to convert the date in milliseconds?

    Hi all

    Can I know how to convert the date in milliseconds?

    My current datetime like this Formate

    QDateTime::currentDateTime (m:System.NET.SocketAddress.ToString ("MMMM dd, yyyy HH"))

    Seconds since January 1, 1970

    http://Qt-project.org/doc/Qt-4.8/QDateTime.html#toTime_t

    Sinds milliseconds January 1, 1970

    http://Qt-project.org/doc/Qt-4.8/QDateTime.html#toMSecsSinceEpoch

  • Need help with the data storage store, local array and network connections

    Need help with my ESXi 4.1 installation

    My hardware:

    I built a server with an Asus P6T whitebox, i7 920, 12 Gig RAM, NIC, Intel Pro1000 PT Quad, 3ware 9650SE-12ML with 8 1.5 TB SATA green in a raid 6 array gives me about 8 + TB with a spare drive all housed within a NORCO RPC-4220 4U Rackmount Server chassis.  I also have a 500 GB SATA drive which will hold the ESXi and virtual machines.

    The network includes a firewall, Netgear Prosafe FVS336G, GS724Tv of Netgear ProSafe 24 port Gigabit Managed Switch on a dhcp cable modem internet service provider.

    I also have 2 old NetGear SC101T NAS disks (4to) I want to connect to the system how some - at a later date have... data on them and want to transfer to the new storage array. I always looking into the question of whether they will work with ESXi 4.1, or I might have to only access it through Windows XP.

    My Situation:

    I have already installed ESXi 4.1 and vsphere client with no problems and it is connected to a dhcp cable internet service.  I've set up host via a dynamic DNS service name give me a static hostname on the internet.  I installed three machines to virtual OS successfully at the moment and now want to first start by creating a multimedia storage server which will use some of this new 8 TB array, then separate data storage for use with a web server small overhead storage and a backup.  It is a domestic installation.

    Help with the data store and network:

    I was doing some reading, because I'm new to this, and it looks like I'll probably want to set up my table via ESXi as a nfs disk format.  Now, the data store is usually in another physical box from what I understand, but I put my readers and ESXi all in the same box.  I'm not sure that the best way to put in place with grouped network cards, but I want to make this work.

    I understand that in ESXi 4.1 using iSCSi LUN must be less than 2 TB, but nfs - I should be able to add a bigger partition then 2 TB (for my multimedia) in nfs, right? or should I still add it separately as a separate 2 TB drives and then extend them to get the biggest space.

    Any suggestions or direct resources showing examples on how to actually add some parts of the table as data warehouses separate nfs.  I know that to go to the configuration tab, and then select Add to storage, and then select nfs. I have not my picture, but it's here that I don't know what to do because ESXi 4.1 system already has an address, should I put the same thing to the new data store array also (will it work?), and what should I use for the name of the folder and the store of data... just do something to the top.  I thought to later install Openfiler (for a multimedia storage using this table server) as a virtual machine, use the table with esxi so that I can access the same storage space with widows and linux-based systems.

    I also know I have to find a way to better use my quad nic card... put in place of virtual switches, grouping, etc HELP?

    Any direction, assistance, similar facilities to sample, suggestions or resources that would help would be great. I did a lot of hunting, but still a little confused on how to best to put in place.

    You must think of VMDK files of large databases with records of random size guest go read some data (a DLL or an INI file), maybe write some data back, then go read other data. Some files are tiny, but certain DLLs are several megabytes. It's random i/o all and heavy on the search time. IO Opsys is small random operations that are often sequential (go read data, write data, go read other data,...) so that deadlines are critical to the overall performance. That's why people say OPS are / s of reference and forget the MBs flow. The only time where you bulk transfers are when you read media (ISO files).

    Well, now forget all this. Actually the disk activity will depend on the specific applications (database? mail server? machines compiler?), but the above is true for boots, and whenever applications are idle. You should see the profile to know.

    RAID 10 is faster (and often more reliable) than RAID 5 or RAID-6 except in certain specific cases. In General RAID 10 is ideal for many random writes, since the calculation of parity for RAID-5 and - 6 adds to the overall latency between command and response - latency is cumulative if a little slow here and a little slow it adds up to a lot of overall slow synchronous especially with e/s on a network. OTOH RAID-5 and -6 can produce faster readings due to the number of heads, so you can use it for virtual machines that transfer bulk. Test. You may find that you need several different types subdashboards for best results.

    You said 3ware, they have some good grades on their site, but don't believe it. With my 9650 that I found myself with only a couple of their recommendations-, I put the (simple) table for allocation size 256 k, nr_requests at 2 x the queue_depth and use the planner date limit. I had the habit for the Ext4 file system formatted with stride and stripe-width synced to the table and used the options large_files with fewer inodes (do not use the huge_files option unless you plan to have single VMDK files in the terabyte range). Use a cache of great reading in advance.

    Virtual machines use VMDK files in all cases except raw iSCSI LUN that they treat native disks. VMDK is easier to manage - you can make a backup by copying the file, you can move it to a PC and load it into another flavour of VMware, etc. There could be some features iSCSI to your San as a transparent migration but nothing for me. NFS has less chatter of Protocol if latency lower times to complete an operation. NFS is good to read and write a block of data, that's all it boils down to.

    UPS is good, but it won't help if something inside the machine explodes (UPS does nothing if the PC power supply goes down). If the RAID card has an option for a battery backup module, so it can contain some writings in memory and may end up the disk i/o after replacing the power supply. 3ware also limits the types of caching available if help is not installed, and you get just the right numbers with the module.

  • Synchronization between two databases with only 2% of the data; Please help me

    Hi all

    I have two oracle databases in 2 different servers PROD and TEST instances. the two databases are in gr 10 2 in linux servers.

    My PROD database contains about 300 GB of data and is dedicated for production area.
    My Test database is dedicated to Spanish test for PROD database. (small server in terms of space and RAM comparing to PROD db)
    I would like to synchronize every week TEST db with PROD db with only 2% of the data and all the structures
    Could someone tell me, if you use a datapump export I can import only 2% of the amount of data and the structures ot theere is another way to do it?
    Thank you very much

    best regards,
    W

    I'm not really sure what you're talking about. There is no option, expdp and impdp x % of the data, is that? And if Oracle can sovle repositories inetegrity (PK, FK), it cannot be assumed which tables are lookup table (to be entirely exported) and can not assume the logical data integrity.

    Nicolas.

  • convert the data-> layer mask vertex position position

    I have 2 videos (A; (B) whose corresponding value of markers, I need to distort the video so the position of the markers would correspond to the position of the corresponding markers in video B.

    The markers are easy to spot, but I can only request data followed the anchor layer,

    while I can use for the distortion (Reshape, revision deform or Morph) the tools work with masks.

    I need a way to convert the caterpillars position data to control individual mask points.

    Someone knows or can write this script?

    much help appreciated

    Yes, as David said, with local Tracker2Mask mode, you can move individual points mask with track points of the tracker item AE.

    See this tutorial:

    Tracker2Mask - advanced functions and local change mask | mamoworld

    My MaskTrackerPlus not help not in this particular case, since he cannot move together masks, but individual vertices not independently.

  • Need help with the date of Validation Urgent

    Hello

    We need help in the Validation Date.

    We have 2 fields of Date on the form the Start Date, End Date

    The requirement is: End Date (cannot be more than 30 years as of the start date).

    I wrote after the script on the exit eventof the End Date . But the problem is its calculation of 30 years from the current Date not from the Start Date

    var

    tDate = util.scand (' mm/dd/yyyy', new Date());

    var

    M = tDate.getMonth ();

    var

    D = tDate.getDate ();

    var

    Y = tDate.getFullYear ();

    var

    SRes = util.printd("yyyy-mm-dd", new Date((Y+30), M,D) );

    App.Alert (SRes)

    If

    (SRes < = this.rawValue)

    {

    App.Alert ("cannot be greater than 30 years from the start date")

    () xfa.host.setFocus

    ce );

    }

    can someone help me please

    Kind regards

    Jay

    Hello

    You need to get the LCD field javascript and calculate & compare with the future date in date javascript.

    Try the following script.

    var sDate = StartDate.rawValue;
    var wkStartDate = util.scand ("yyyy-mm-dd", sDate);

    nYear var = wkStartDate.getFullYear ();
    nMonth var = wkStartDate.getMonth ();
    nJour var = wkStartDate.getDate ();

    var wkFutureDate = new Date (+ 30 nYear, nMonth, nJour);

    sDate = EndDate.rawValue;
    var wkEndDate = util.scand ("yyyy-mm-dd", sDate);

    If (wkEndDate.getTime () > wkFutureDate.getTime ()) {}
    xfa.host.messageBox ("cannot be more than 30 years from the start date");
    xfa.host.setFocus (this);
    }

  • Convert the data to uppercase (upper/lower case text

    I have data in the field as
    ABERCHROBIE FITCH - like this

    I want to change all the data in the field, as
    Aberchrombie Fitch - first letter should b in the capital and all the remaining letters should be in small.


    Ex:
    FITCH-> Fitch
    Concat (Upper (Left(columname,1)), LOWER (SUBSTRING (columnname OF 2 for LENGTH (columname)))

    ABERCHORMBIE FITCH Aberchrombie - Fitch
    ?

    AMERICAN EAGLE-> American Eagle
    ?
    ....

    can someone help me change the first letter to the capital and the remaining letters to small

    Published by: user12255470 on October 18, 2010 18:49

    user12255470,

    under fx, apply the formula: LOWER (your column)---> the result which is "abercrombie fitch.
    now go to "Properties of the column" and select "additional formatting" options > check "Use CSS Custom Style" & put the style according to

    text-transform: capitalize;

    If the answer points please :-)

    -bifacts
    http://www.obinotes.com

  • How to convert the Dates of entry into ReminderInfo in observed activity!

    Hello

    We read the Date and time of the reminder of the user via the form. We want to link this entry date and time with ReminderInfo data type to set

    Reminders in activity Task Assign.

    Please find the ppt for more information.

    Please help us in this regard.

    Thank you

    Praveen

    Drag a SetValue component and add assignments (see the screenshot to the assignment)

    Repeat the same thing for hours and minutes

    Nith

  • Touch iPhone 5s does not not needing help for the data on it.

    iPhone 5 s (iOS 9) I have blue and red lines on the screen and the touch does not work at all, but the phone still works as usual outside the lines and contactless (voice on don't work/Siri as other items said worked, I do not have wifi for Siri). What I want is the data on the phone, I have a macbook pro (OS X 10.11) a fix would be better, but all I need is the data. I have icloud activated, but it was defective on my phone so don't know if I had a full backup and would like to know how to check. I have a form of computer backup about 2 months ago, but wanted all the pictures and data since then.

    At the back for up to my pc, I need is to unlock my phone, so any help will be appreciated.

    Thank you

    If connect to iTunes and perform a full backup

    And also connect on iCloud & see you backup recently

  • When I start the machine, continuous hard drive work for almost 1/2 hour, meanwhile if I open a program, the machine runs very slowly. Help solve the problem please

    I have wndow XP Home edition service pack 3 installed on my lap top. When I start the computer the hard drive continues to work for almost 1/2 hour; Meanwhile, if I open IE, or any program, the machine runs very slowly and I just can not open the program up until the drive hard light is off. Please help solve the problem

    How much RAM you have on your system? (Right click on "My Computer"-> properties)

    As a general rule, Windows XP does not work well if you have less than 1 GB or more of RAM.  What usually happens is that your RAM capacity is exceeded leading to overflow on virtual memory (the drive) to compensate for the need of RAM in the computer.  This causes your system to beat on your hard drive and slow down your system.

    If this is your problem, the options are to increase the RAM on your system or decrease the non-essential programs that launch at startup on your computer using a tool like Autoruns.

    HTH,
    JW

  • Convert the date in milliseconds

    Hello

    I am trying to write a function to create an event on the calendar

    the function takes at the beginning of the year, month, day and time. Also the end time

    EventList eventList = (EventList) PIM.getInstance () .openPIMList (PIM. EVENT_LIST, PIM. WRITE_ONLY);
    Event e = eventList.createEvent ();
    e.addString (Event.SUMMARY, PIMItem.ATTR_NONE, "The Gym");
    e.addString (Event.LOCATION, PIMItem.ATTR_NONE, "Gym");

    dates back to January 1, 1970
    e.addDate (Event.START, PIMItem.ATTR_NONE, startDate);
    e.addDate (Event.END, PIMItem.ATTR_NONE, endDate);

    I'm stuck trying to figure out how to convert, say, an entry 2013 (year), 3 (months), 7 (day) in millisecond so that I can

    Put it in the field hiring date

    Thank you

    2 options:

    (1) use a Calednar object, use the methods of 'set' associated with it to set the year, month, day, etc. (not to mention the January is month 0) and then get the Date in that and then the time from the Date.

    (2) format your date so that it is acceptable to HttpDateParser and the race that against your date string.

  • Convert the date of "MON/dd/yy" format to "LUN/yy '.

    I know there is probably a load of questions already on it, but I can't find a simple simple explanation with examples on how to change the date format "MON/DD/YY" in month/year format "LUN/YY '.

    Can someone help with a useful answer, thank you

    woof777 wrote:
    I know there is probably a load of questions already on it, but I can't find a simple simple explanation with examples on how to change the date format "MON/DD/YY" in month/year format "LUN/YY '.

    Can someone help with a useful answer, thank you

    The DATE data type have No. format, & can be presented with TO_CHAR sort

    SQL> select to_char(sysdate, 'MON/YY') from dual;
    
    TO_CHAR(SYSDATE
    ---------------
    AUG/12
    
  • convert the data that are not text

    create table x as
    (line_1 varchar2(10))
    INSERT INTO x  VALUES ('001165899', '0506', 'ZIP1003', 'ABC', 'xyz')
    It is the source table, it transforms (to meet the requirements of the company) to another table where column line_1 is converted to a data type of number, and all the data in the column of line_1 which is the text are converted to-1.

    user628919 wrote:
    How the hyphen may be replaced for the data where it grows in different places within the data.

    The solution needs to keep other rules - convert to_number, text-1 column, ignore nulls (see below)-, more remove the hyphen of digital data.

    to_number(regexp_replace(line_1, '.*\D.*', '-1'))
    

    As Vivek L, complete with a convenient link for documentation, said "replace should work.

    to_number(regexp_replace(replace(line_1, '-'), '.*\D.*', '-1'))
    

    John

  • tool to convert the data to a script

    I have a list of posts with the following data
    EmpNo, name, date of birth
    12345, kala, August 25, 1960
    23456, anugraha, 05-mar-1991
    34567, marie agegee, July 1, 1984

    I want to send this data to another area where the staffing table exists with the same structure.
    That's why I need script like the following file

    Insert in the values of staff (12345, "kala", August 25, 1960 "");
    Insert in the values of staff (23456, 'anugraha','05 - mar - 1991 "");
    Insert in the values of staff (34567, "marie agegee", July 1, 1984 ');

    I can run this script to load data into this new personal table under different domain.

    Transaction every day, I want to create this script file and store it in different domain.

    Y at - it a facility to convert my data as above the script file instead of write procedures using cursors.

    In Oracle SQL Developer, you can right-click on a table and export data as INSERT queries, among other formats.

    Thank you

    -Scott-

    http://sumnertechnologies.com/
    http://spendolini.blogspot.com/

Maybe you are looking for

  • Need to restore disk for Portege M200 tablet pc

    Dear all, I need a copy of the disk original restoration for a Portege M200 Tablet pc.Just found out that Toshiba does not sell these disc more. (?!)Too old... I'm in trouble! Can someone help me please? Anyone got one? I tried ebay but without succe

  • Secuencial copy job on ix2?

    Hello Is it possible to program an ix2 copy tasks so that they execute in sequence? Currently, I copy several jobs scheduled to run every day at pre-defined but hours does the ammout of information to copy can vary the time required for backup, so I

  • Drive D and some files are written in blue.

    When I open my computer and drive C and D icons appear that drive D is written in blue also in my document, that some files are also written in blue why is this. considers that Stephen.

  • I get an error of binding of the program trying to reopen the Windows Vista Games.

    From: BrianWhen you try to open a standard game installed, IE solitaire, chess, mahjong, I get the message error "file doesn't have a program that are associated with...". "" Under turn Windows features on and outside ', I have uninstalled/reinstalle

  • How to speed up programs?

    Hello, I already know how to speed up my computer in general, but how do I get my computer to spend all / most of his power on a program? The priority of the program work? It seems like him. Any response is great, thanks :)