Continue the query despite invalid date in a view

Hi ,
SQL :
select id , mydate from myview
where mydate >= sysdate - 1
Error : ORA-01858 , a non-numeric character was found where a numeric was expected
i am trying to find the record that is showing this invalid date
else will have to do a manual search
or write a procedure to find the record
but Is it possible to continue the view despite there's a invalid date ?
with a status column "VALID_DATE" that show Y - for valid date and N - for invalid date ?
Please advise
tks & rgds

Hi,
Connected to Oracle Database 10g Express Edition Release 10.2.0.1.0
Connected as hr
SQL> CREATE TABLE T(COL VARCHAR2(10));
Table created
SQL> INSERT INTO T(COL) VALUES ('12/02/2009');
1 row inserted
SQL> INSERT INTO T(COL) VALUES ('22/02/2009');
1 row inserted
SQL> INSERT INTO T(COL) VALUES ('99/02/2009');
1 row inserted
SQL> COMMIT;
Commit complete
SQL> SET SERVEROUTPUT ON
SQL> DECLARE
  2     v_date DATE;
  3     v_mask VARCHAR2(10) := 'DD/MM/YYYY';
  4  BEGIN
  5     FOR REG IN (SELECT COL FROM T) LOOP
  6        BEGIN
  7           v_date := to_date(REG.COL,
  8                             V_MASK);
  9        EXCEPTION
10           WHEN OTHERS THEN
11              DBMS_OUTPUT.put_line('WRONG RECORD ' || REG.COL);
12        END;
13     END LOOP;
14  END;
15  /
WRONG RECORD 99/02/2009
PL/SQL procedure successfully completedRegards,

Similar Messages

  • Error Message - "could not complete your request because the preset contains invalid data"

    I am trying to open a file, and every time I do it comes up with the following error message:
    "Could not complete your request because the preset contains invalid data"
    I am using Photoshop CS4 on a Macbook Pro running Snow Leopard 10.6.2.
    I have tried:
    - restarting my mac
    - opening different files created at different times
    - deleting photoshop from my app folder and the app support folder from my /username/library/application support/adobe/ folder and copied them back from a Time Machine backup from a few days ago.
    I was using Photoshop all day today with absolutely no problems. I have searched Google and this forum and have come up short. No one has this exact error anywhere.
    Any help? Thanks so much in advance!
    Pat Dryburgh

    The one thing you didn't do is reset your Photoshop preferences.
    Most likely the preferences got corrupted, and reference a corrupt preset.

  • WebPart is raising the following error "Invalid data has been used to update the list item.The field you are trying to update may be read only"

    I have created a farm solution and then i deploy it to SharePoint server, the code looks as follow, and i use it to update a page info values (as the current page values represents old info):-
    [ToolboxItemAttribute(false)]
    public partial class VisualWebPart1 : WebPart
    // Uncomment the following SecurityPermission attribute only when doing Performance Profiling using
    // the Instrumentation method, and then remove the SecurityPermission attribute when the code is ready
    // for production. Because the SecurityPermission attribute bypasses the security check for callers of
    // your constructor, it's not recommended for production purposes.
    // [System.Security.Permissions.SecurityPermission(System.Security.Permissions.SecurityAction.Assert, UnmanagedCode = true)]
    public VisualWebPart1()
    protected override void OnInit(EventArgs e)
    base.OnInit(e);
    InitializeControl();
    using (SPSite site = new SPSite(SPContext.Current.Site.Url))
    using (SPWeb web = site.OpenWeb())
    SPList list = web.Lists["Pages"];
    web.AllowUnsafeUpdates = true;
    foreach (SPListItem items in list.Items)
    items["Author"] = "SharePoint";
    items["Created"] = "01/08/2014 01:44 PM";
    items.Update();
    list.Update();
    web.AllowUnsafeUpdates = false;
    protected void Page_Load(object sender, EventArgs e)
    but when i try adding this web part to a page i got the following error:-
    Invalid data has been used to update the list item.The field you are trying to update may be read only
    so can anyone advice?

    i only changed lines bitween 
    web.AllowUnsafeUpdates = true;
    and
    web.AllowUnsafeUpdates = false;
    and other parts of code remains without change
    so it will updates all pages in current web
    yaşamak bir eylemdir

  • Is there a way to make the query key reference date equal to a date of IC

    Hi gurus
    Is there a way to make the query key reference date equal to a date in the InfoCube. For example, I want to see the attributes for characteristic material based on the sales date of the transaction?
    Thanks
    Siva

    Sivakumar,
    Key date applicable to entire query for time dependent attributes and heirarchies.
    You can create a user entry variable and use it for query key date. So can choose at input screen. and also you can populate default value using user exit(eg: current date).
    Hope it Helps
    Srini

  • Handling invalid Dates In query for Invalid dates in date column.

    Hi,
    I have a date column in my table. This column has corrupted data so the when i use any
    to_timestamp function or any other date calcualtions my query breaks with the error:
    ORA-01843: not a valid month.
    I am aware the data is the issue.
    But i want to handle this scenario by putting nulls in the output when ever an invalid date is encountered.
    I have done some research and found the custom function is_date() on net.
    But i am not suppose to create any new function but handle it with in my query.
    Help is appreciated to handle this scenario.

    Prasath wrote:
    Try this!!
    With Tab As(Select '12/01/2009' txt From dual)
    SELECT Decode(Length(Replace(Translate( txt
    , '0123456789/'
    , Null
    , to_date(txt,'mm/dd/yyyy')
    , NULL) As Validation_date
    FROM tab;
    Ok ...
    SQL> With Tab As(Select '12/01/2009' txt From dual)
      2      SELECT Decode(Length(Replace(Translate( txt
      3                                            , '0123456789/'
      4                                            , '#')
      5                                  ,'#'))
      6                   , Null
      7                   , to_date(txt,'mm/dd/yyyy')
      8                   , NULL) As Validation_date
      9       FROM tab;
    VALIDATIO
    01-DEC-09Not sure what that proves, especially in relation to the OP's problem.

  • Select query to read data from a view

    Hi friends,
    We have been using a query to read data from a custom view which used to work perfectly. Now the program sits at that select query forever. We are able to extract same data from se16. Not sure what could be the problem.
    Thanks in advance.

    Dev
    Have a look at the Table Index for the tables involved in the View... I think there is some change in the Indexes.. (Add / Remove / Change)
    Thanks
    Amol Lohade

  • How to edit PSA and continue the load with corrected data from PSA.

    Hi,
    Can you guide me on how to edit data in PSA and then continue a load?
    i.e. if you can provide me with the steps on how to fix a load problem if a load fails. The load fails and Monitor shows red, so how do I fix them in the PSA and then allow the load continue with the corrected data into the data target.
    I will appreciate the details steps involved.
    Thanks

    Hi
    First select that request then turn to Red and delete the Request , delete the qeruest then system allow to edit the psa data ,selete psa then selet packet then selet record double click modify the data, dont forget after completing save the data. after competing modification then select psa right click select- start update immediatly......
    thanks
    ram

  • Please let me know how to write the Query to fetch data from tables

    Hi Folks,
    Please let me know how to get the data from  different tables using the functionality SQ03,SQ02  and SQ01 .
    Helpful answers will points awarded.
    Regards,
    Ram.

    Dear Ram,
    Please find the below link which gives in detail with screen shots.
    [SAP Query|http://media.techtarget.com/searchSAP/downloads/Teach_yourself_SAP_C20.pdf#search=%22CREATE%20REPORT%20USING%20SQVI%20%2C%20SAP%22]
    Thanks
    Murtuza

  • DP forecast not released to SNP - error "Invalid Data Status"

    Hello,
    When DP forecast was released to SNP, one material - Location went into error. The error is "Invalid Data Status"
    Release to DP to SNP  is thru background job, and it check the material status (only material with active status is considered for release).
    But for the above error, the material is active.
    What could be the possible reason for this error & how can it be  resolved.
    Thanks in advance.

    Hi Datta,
    In consistency match, there are multiple objects. Since DP is new to me, I am not aware of the objects that should be selected. Can you tell me which objects should I select for this and what will be the outcome of this.
    Also can you please explain me why do we execute his transaction?
    Thanks in advance.

  • How to build dynamic query strings in the query using DB adapter 'Pure SQL'

    Dear Forum,
    I am building an application which will access DB to fetch some result set. The query involves retrieving data from multiple tables(nearly 10 tables). So I have created a DB adapter using 'execute pure sql' option. With this query works fine, but my inputs parameters will vary. So I need to make my query dynamic to append the query strings at runtime depending on the inputs.
    For example I have 3 input variables - input1,input2 and input3 (in my request xsd) which are used in the pure sql query. Now if I get a 4th input parameter input4 in the request, I need to append this to query string as 'AND input4=[some value]' at runtime. Otherwise my query should have only 3 parameters. Please suggest how this can be achieved.
    Regards,
    Satya.

    This is a strange requirement, depending on the columns you have and what are optional in them, one way is to have separate operations and each opeartion will have different inputs and for each operation , a different DB Adapter is called. But this way, it results in more number of operations for the service as well as more number of references in the composite. Even if you pass the column inputs to the SQL procedure, it will result in a large number of if-else cases..
    Thanks,
    N

  • Query problem, no data exist

    Dear Experts,
    My user would like to combine data from FBl3N (field BUDAT, amount in document currency, amount in local currency , reference document) with data taken from Billing (VF03- FKDAT, BUDAT, VBELN, CHARG, MATNR, ARKTX).
    I have created a query with the following join table:
    1. VBRP (FKIMG, MATNR, WERKS, CHARG, PRCTR)
    2. VBRK (FKDAT, VBELN, BUDAT).
    3. BSIS (XBLNR, WRBTR, DMBTR)
    Join condition : BSIK&VBRP (BUKRS, GJAHR), VBRP & VBRK (VBELN).
    While executed the query ( SQ01), u2018no data existu2019 message is appear.
    Did I made a wrong join table and condition?
    Kindly advice me.
    Thank you.

    HI
    Please check the joining conditions
    Thanks & Regards
    Phaneendra

  • Flash IDE, Haxe & OpenFL - Invalid Data Swf Error #2136

    We've recently run into a show stopping issue and can't seem to find any one else on the net who has the same problem (although there have been similar ones).
    We're currently developing a game using Haxe and OpenFL. We use FlashDevelop to code the game and the official FlashIDE (CS6) to create UI/menus which is then hooked up via code in FlashDevelop. A few weeks ago the FlashIDE crashed while the FLA was being worked on. Nothing appeared to be wrong as the file opened normally, however, after building our game in FlashDevelop we received the following message "Invalid Data Swf Error #2136". Since then we've done a handful of things that will seem to fix it temporarily, but as of now, none of those solutions work. At this point we think its some sort of flash limit or an issue with OpenFL, Haxe, and FlashIDE (or some combination of).
    I'd like to note that we've noticed some weird behavior - if we removed any clip the error disappears and if we add it back, the error returns.
    Here's what we've tried:
    recreating movie clips that were created after the crash
    converting the FLA into a archive and repairing it with WinRAR
    splitting the FLA into two files
    copying the library into a new FLA file
    Any ideas on how to fix this would be greatly appreciated!

    If you found a specific clip that caused it to build or fail I'd say it's a possibility. However you mentioned in the OP that you took 'any' clip out and it works but put it back and it breaks. This really seems like a limit. Limits should be openly documented however.
    Perhaps you should take a large bitmap and a complex vector and drop them in 2 different symbols. Then duplicate these symbols until you have more symbols than you currently have. Internally they will all point to the same graphics so it won't be a heavy file. Try exporting that with OpenFL and see if it's a library reference limit.
    I'm sure you get what I'm getting at. If limits arent documented, you may need to stress test the libraries, languages and frameworks yourself using simple self made tests.

  • ERROR: Invalid data pump job state; one of: DEFINING or EXECUTING.

    Hi all.
    I'm using Oracle 10g (10.2.0.3) I had some scheduled jobs for export the DB with datapump. Some days ago they began to fail with the message:
    ERROR: Invalid data pump job state; one of: DEFINING or EXECUTING.
    Wait a few moments and check the log file (if one was used) for more details.
    The EM says that I can't monitor the job because there's no master tables. How can I find the log?
    I also founded in the bdump that exceptions occurred:
    *** 2008-08-22 09:04:54.671
    *** ACTION NAME:(EXPORT_ITATRD_DIARIO) 2008-08-22 09:04:54.671
    *** MODULE NAME:(Data Pump Master) 2008-08-22 09:04:54.671
    *** SERVICE NAME:(SYS$USERS) 2008-08-22 09:04:54.671
    *** SESSION ID:(132.3726) 2008-08-22 09:04:54.671
    kswsdlaqsub: unexpected exception err=604, err2=24010
    kswsdlaqsub: unexpected exception err=604, err2=24010
    * kjdrpkey2hv: called with pkey 114178, options x8
    * kjdrpkey2hv: called with pkey 114176, options x8
    * kjdrpkey2hv: called with pkey 114177, options x8
    Some help would be appreciated.
    Thanks.

    Delete any uncompleted or failed jobs and try again.

  • Error invalid date using  delete_filter_exp  in Ikm knowledege module netez

    i created the a,b,final-r-interfaces in ORACLE DATA INTIGRATER(ODI).pkg level these three interfaces are executed successfully in developement.
    when i executed the final-that r-interface alone in development then it shows the error (i.e.invalid date)
    Note i am using the delete_filter_exp in Ikm knowledege module netezza control append i am using this conditon in this delete_filter_exp in Ikm knowledege module netezza control append (HIST_CREATION_DATE>= TO_DATE(substr('#D_abc_vb_O_LINES_HISTORY_RK',1,19) ,'MM/DD/YYYY HH24:MI:SS') AND SOURCE_ID=3)
    I am getting the error as .invalid date.
    Regards,
    Venkat

    hi,
    the data types like typ_s_ressource are defined.
    they are declared in the include LZTPGTOP.
    The declaration of typ_s_ressource is:
    types: begin of typ_s_ressource,
            perno type hrsobid-sobid,
            org_unit type objid,
            position type hrsobid-sobid,
            leadpos type c,
           end of typ_s_ressource.
    If u have any questions, you can ask me, but try to provide a solution.
    Thanks,
    Srinivas.

  • Invalid Data Status while loading data in planning book

    Hi,
    Recently i got the error message "Invalid Data Status - Error reading  data - planning book cannot be processed further ". I was able to resolve that issue by running program /SAPAPO/TS_LCM_CONS_CHECK with options Repair and check Livecache anchor. Now Here is my question, i want to know why does the livecache anchor error occurred. What steps can i take in future to avoid this error?
    Regards
    Kartik

    Kartik,
    I couldn't say.  In all the years I have been using SCM, I have never been able to prevent all such errors from occurring, I have only been able to solve certain problems only under certain specific instances.  Usually, the 'solvable; problems I have seen are a result of poorly written enhancments or custom programs.
    One might speculate that the reason SAP provides these repair programs (yes, there are MANY inconsistency-repair type programs) because they believe that such errors are inevitable.
    Maybe you would be better served by just running such programs periocically in batch, as recommended by SAP.
    http://service.sap.com/~sapidb/011000358700000955412003E
    Best Regards,
    DB49

Maybe you are looking for

  • Verizon Wirless 4GLTE for Tarboro, North Carolina Edgecombe and Rocky Mount NC Nash/Edgecombe

    Hello Verizon Wireless! Could you please tell me when the release date for 4GLTE for Tarboro and Rocky Mount which is in Edgecombe and Nash County in North Carolina? Because, 4GLTE has service in Pitt County which is the next county from us which is

  • Error while registering SMS portlet

    Hi, portal version 9.0.4.0.99 I am getting the following error while registering SMS portlet using the external application SMSExternalApp. SOAP: Caught SOAPException (SOAP-ENV:Client): For input string: "3782 " [java.lang.NumberFormatException] Ille

  • Problem viewing videos - Problema visualizzazione video

    Hello A few days ago I decided to start trying Adobe Premiere CS5, honestly I never used this program, even earlier versions. Just coming to my problem: I imported a video format: mov size: 1280 x 720 codecs: H.264, AAC Color Profile: HD (1-1-1) Chan

  • Depreciation on Retirement

    Dear All I have purchased an Asset on 10.04.2008 for Rs. 3,00,000. Now i want to Retire/Sell it on 26.09.2008 for Rs. 2,50,000. How to calculate depreciation for the 26 days. What is the process? Please advice. Thanks and Regards Kanwaljit

  • Drag & drop from explorer into my application

    Hi folks, I want to drag files or folders from Windows explorer into a tree structure of my LabVIEW application. I did not find any solution or example (and I was not able to install the G-Toolbox, which is mentioned in some old forum boards). Does a