Tuesday, March 13, 2012

FRM-40301: Query caused no records to be retrieved fix

Step 1
Check if your data block query is correct. To do so, navigate to Help --> Diagnostics --> Examine on the toolbar. When prompted enter your database password. Check you last query using the SYSTEM block.



If your query retrieves correct data then go to below debugging steps else fix your query.

Step 2:
Debugging
  1. Check the length of fields used in data block. If a non-database/database item is defined in the block and value passed exceeding its maximum length defined then query fails.
    Eg: Customer_Name defined max. length as 30 chars where as query populates more than 30 characters.

     
  2.  Check if block has non database fields but set database item to yes.
  3.  Check if all the required fields are populated else set required property to no.
  4.  Check if initialization of form is done set-org-context-in-oracle-apps-11i/R12.

Hopefully above debugging steps would resolve the error.

5 comments:

  1. Thanks a lot !! It really helped after struggling for nearly 2 days on this issue. In my case, it was the maximum character issue.

    ReplyDelete
  2. GHULAM YASSEN,
    Thanks you sir so much, it help me 100%.

    ReplyDelete
  3. Thank you so much, It really solved my issue.

    ReplyDelete
  4. Hi, In my case, records are getting retrieved with Operations user (in Oracle Apps) but when I create my own user, then query is not retrieving any output. Would really appreciate any help in this. I also checked profile options. They are all same in both Operation user and the one which I created.

    ReplyDelete
  5. Hi, I am facing issue on execute_query. sometime it populate data and sometime not for same record on same form. I have verified the last query and each time execute_query create right select statement. Could you please suggest, what is the possible cause of this issue?

    ReplyDelete