Sitemap

Amicuk Programming Answers

AM Validation Exception - Deadline looming - Please help!

-0001-11-30   Views:0

Advertisement

Gurus, I am trying to perform validation in AM against data already existing in underlying table. Since my EOImpl is utilizing API calls for insert/update/delete with OAPlsqlEntityImpl ... I cannot enforce uniqueness in EO attributes. Therefore, I am

Gurus,
I am trying to perform validation in AM against data already existing in underlying table. Since my EOImpl is utilizing API calls for insert/update/delete with OAPlsqlEntityImpl ... I cannot enforce uniqueness in EO attributes. Therefore, I am performing validation in AM and need to throw an exception message when duplication occurs.
I have documented my code and Null Pointer Exception message. The bolded code in PFR represents line "307" which is reference in the Null Pointer Exception. Any help would be greatly appreciated and rewarded.
Thanks!
PFR code:
public void processFormRequest(OAPageContext pageContext, OAWebBean webBean)
super.processFormRequest(pageContext, webBean);
OAApplicationModule am = pageContext.getApplicationModule(webBean);
// Pressing the "Apply" button means the transaction should be validated
// and committed.
if (pageContext.getParameter("Apply") != null)
OAViewObject vo = (OAViewObject)am.findViewObject("DesigFullVO1");
String DesignatorCode = (String)vo.getCurrentRow().getAttribute("DispCode");
*Serializable[] params = { DesignatorCode };*
am.invokeMethod("ValDesig",params);
am.invokeMethod("apply");
MessageToken[] tokens = { new MessageToken("DESIGNATOR",DesignatorCode)};
OAException confirmMessage = new OAException("AK", "SPL_CREATE_DESIGNATOR_W", tokens, OAException.CONFIRMATION, null);
OADialogPage dialogPage = new OADialogPage(OAException.CONFIRMATION,
confirmMessage,
null,
APPLICATION_JSP + "?page=/designator/oracle/apps/spl/hdrdef/webui/DesigSearchPG",
null);
dialogPage.setReusePageLayout(true);
pageContext.releaseRootApplicationModule();
pageContext.redirectToDialogPage(dialogPage);
pageContext.putDialogMessage(confirmMessage);
VO query:
select disp_code DISP_CODE
from spldat.spl_dispositions
AM code:
public void ValDesig(String dispCode)
DesigValidationVOImpl vo = getDesigValidationVO1();
DesigValidationVORowImpl Row = null;
String a = "disp_code = '"+dispCode+"'";
vo.setWhereClauseParams(null);
vo.setWhereClause(a);
vo.executeQuery();
String l_desig = Row.getDispCode();
if (l_desig != null)
*MessageToken[] errTokens = { new MessageToken("OBJECT_NAME", "DesigValidationVO1")};*
throw new OAException("AK", "FWK_TBX_OBJECT_NOT_FOUND", errTokens);
} // end ValDesig()
NullPointerException
oracle.apps.fnd.framework.OAException: java.lang.NullPointerException
     at oracle.apps.fnd.framework.OAException.wrapperException(OAException.java:891)
     at oracle.apps.fnd.framework.OAException.wrapperException(OAException.java:865)
     at oracle.apps.fnd.framework.OAException.wrapperInvocationTargetException(OAException.java:988)
     at oracle.apps.fnd.framework.server.OAUtility.invokeMethod(OAUtility.java:211)
     at oracle.apps.fnd.framework.server.OAUtility.invokeMethod(OAUtility.java:153)
     at oracle.apps.fnd.framework.server.OAApplicationModuleImpl.invokeMethod(OAApplicationModuleImpl.java:749)
     at designator.oracle.apps.spl.hdrdef.webui.DesigCreateCO.processFormRequest(DesigCreateCO.java:307)
     at oracle.apps.fnd.framework.webui.OAWebBeanHelper.processFormRequest(OAWebBeanHelper.java:804)
     at oracle.apps.fnd.framework.webui.OAWebBeanContainerHelper.processFormRequest(OAWebBeanContainerHelper.java:363)
     at oracle.apps.fnd.framework.webui.OAPageLayoutHelper.processFormRequest(OAPageLayoutHelper.java:1156)
     at oracle.apps.fnd.framework.webui.beans.layout.OAPageLayoutBean.processFormRequest(OAPageLayoutBean.java:1579)
     at oracle.apps.fnd.framework.webui.OAWebBeanHelper.processFormRequestChildren(OAWebBeanHelper.java:1000)
     at oracle.apps.fnd.framework.webui.OAWebBeanHelper.processFormRequestChildren(OAWebBeanHelper.java:966)

The replay answer
Advertisement
I'm getting a compilation error against the following code for the bolded line:
What is the best way to fix this type mismatch? I need to make sure that the result assigned to l_desig is the value returned from the VO.
AM Code:
public void ValDesig(String dispCode)
DesigValidationVOImpl vo = getDesigValidationVO1();
if (vo == null)
MessageToken[] errTokens = { new MessageToken("OBJECT_NAME", "DesigValidationVO1")};
throw new OAException("AK", "FWK_TBX_OBJECT_NOT_FOUND", errTokens);
String a = "disp_code = '"+dispCode;
vo.setWhereClauseParams(null);
vo.setWhereClause(a);
vo.executeQuery();
Row DesigValidationRow = getDesigValidationVO1().first();
String l_desig  = DesigValidationRow.getAttribute("DispCode");
if (l_desig != null)
MessageToken[] errTokens = { new MessageToken("OBJECT_NAME", "DesigValidationVO1")};
throw new OAException("AK", "FWK_TBX_OBJECT_NOT_FOUND", errTokens);
} // end ValDesig()
Error:
incompatible types; found java.lang.Object; required: java.lang.String
Edited by: sreese on Dec 1, 2010 11:04 AM

Go to See the other 7 answers

AM Validation Exception - Deadline looming - Please help!

Category:DefaultRelease time:-0001-11-30Views:130

Gurus, I am trying to perform validation in AM against data already existing in underlying table. Since my EOImpl is utilizing API calls for insert/update/delete with OAPlsqlEntityImpl ... I cannot enforce uniqueness in EO attributes. Therefore, I am[More]

MEGA memory leak!! cannot use PS ideas please?! deadline looming!!

Category:DefaultRelease time:2015-10-11Views:130

Hello PS community!! I'm running PS 5.5 on a Macbook pro Retina version 10.7.5 Despite having more than 30gb free on my disk, as soon as I open my file (Doc 199.1M/655.6M) within 1 minute, all 30gb is consumed leaving just 10MB and I cannot work anym[More]

Error opening .indd files with CS6 AND CC - deadline looming, what is the fix?

Category:DefaultRelease time:-0001-11-30Views:130

I just got a new Macbook Pro and upgraded to CS6 two weeks ago. I was having problems opening files: So I asked IT to upgrade me to CC. Guess what? Still get the error message. I was editing this file yesterday without issue. My deadline is now. WTH[More]

Help With Buttons Please. Deadline Looming

Category:DefaultRelease time:2015-10-11Views:130

Hi everyone, I am having a major brain block today. My problem is simple... and I cannot fix it. too tired. I have a menu the has NO overlays. Just a simple graphic that I made a button on top using the Apple Square Red Shape that comes with DVDSP. I[More]

PLEASE Help ASAP - deadline looming

Category:DefaultRelease time:2015-10-11Views:130

Hi - I appreciate any specific help on this problem. I've developed a Flash Drag & Drop game for kids to dress a character properly for winter snow sports (skiing, snowboarding, xc & snowshoe) -- I've got everything working beautifully except for[More]

DEADLINE LOOMING - HELP - Loading with array

Category:DefaultRelease time:2015-10-11Views:130

I am able to test and view an external txt file and activate links via my desktop. But when I upload the file(s), to view online, I am unable to view the text in the swf. I checked all the permissions and tested on 3 separate servers. I also used a c[More]

Linked fields not working correctly- PLEASE HELP DEADLINE LOOMING!

Category:DefaultRelease time:2015-10-11Views:130

I have two tables. The first is called Orders and contains a autonumber field named ID. This field is linked to a field named OrderID in another table named ProductOrders. I am using a submission form with a cfinclude to submit to both tables. There[More]

PDF's become bloated, deadline looms

Category:DefaultRelease time:-0001-11-30Views:130

Hi all, I'm trying to do something that's never been a problem in the past, as recently as a few months back. I have a file created in FastTrack Schedule that's a mere 900 kb, 25 pages with some colors, but in a layout that does not show the timeline[More]

HELP!! Deadline Looming

Category:DefaultRelease time:-0001-11-30Views:130

I created a slideshow on iphoto.  Everything is done and looked good on the playback.  Then I burned it to a DVD and it played fine on the laptop but when I put it on my tv, a handful (not all) of the photos either became too large or were cut off. [More]

Help! Compressor 1.2.1...Deadline Looms!

Category:DefaultRelease time:-0001-11-30Views:130

I have a movie created in FCP HD 4, exporting it into Compressor and using presets for MPEG2 60min High Quality. The footage is "8mm movie footage" ...using this compressor setting with De-Interlace(even) and due I suppose t all the motion in th[More]

Exporting to DV Camera and Audio is 1 second off! HELP!!! Deadline Looming!

Category:DefaultRelease time:-0001-11-30Views:130

Hello. I am working on a video project for my brother's wedding on Friday. I have the video completed and all I need to do is export it to my DV Camera (Canon GL1). However, whenever I try to export from iMovie (HD 6) the audio is always a second or[More]

Hot
Hello I have to read some HR infotypes that are provided with the logical database PNPCE. Fort his i have written a report that will use my logical database and get some information. What i need,are some new input parameters on the screen that are ad [More]
my grandaughters ipod is disabled.  Its not registered to my MAC but I've tried connecting it and pressing down the two side buttons and opening itunes. It just tells me "iTunes could not connect to the iPod touch "alison's iPod" because it [More]
using fire wire to my macbk pro how do i clone it from my imac so it is identical everything, dah thus cloneSince no one has answered, I’ll jump in. I don’t know how to do this with FireWire but I can say how to migrate the data with a disk.  When yo [More]
Hi hope you can help. i have multiple images that are not square and i need to make them square. i do not want to crop or loose any detail from the images. how can i square up images without cropping. This is not a straight edge issue the pictures we [More]
Hi, I purchased this back in August of 2013. I just had to buy a new computer and need to download again. I have a serial number and order number but I am not seeing anywhere to download this an re-install in  y order history. Please advise. thanks.i [More]
I had two iphones and i am needing to put the back ups all on the same phone. How do i do this?You cannot.Read other 2 answers [More]
Hi to all, i am having a problem regarding org. det. in IC win client i am creating a service complaint it was detemining a different org other than the ogr. det. given in Trans. type. what may be the reason and it was not detrminig prcicing procedur [More]
I have a new Airport Extreme 802.11n running firmware version 7.4.1 and Airport Utility 5.4.1. I bought this from the Apple store at apple.com in mid-March 2009. I would like to set up a guest network but can not find where to do it... I have reset t [More]
Is there any way to SAVE the values (i.e. as a Orange Filter, Red Filter, etc.) the way it was before? My B&W dialog is constantly coming-up with default values (39%, 11%, 0%). Adjusting the values and saving it as a default set still results in thes [More]
I posted a question earlier and no replies!!! I'm trying to download my tunes from my purchased songs in iTunes! It shows as they are down loading but they are not appearing in my music. Can anyone tell me why and if I'm doing something wrong. It's d [More]