Exception StartupServletContextListener for myFaces 1.2 Tomcat 6.0
I am facing following exception at tomcat 6 and myfaces 1.2
SEVERE: Exception sending context initialized event to listener instance of class org.apache.myfaces.webapp.StartupServletContextListener
and when accessed at browser at shows 404 error code for unavailability
kindly have a look over following error/environment details -
Environment
Toomcat - 6.0.18.0
Jdk - 1.5
MyFaces - 1.2.7
Tomcat default server/lib directory
annotations-api.jar
catalina-ant.jar
catalina-ha.jar
catalina-tribes.jar
catalina.jar
el-api.jar
jasper-el.jar
jasper-jdt.jar
jasper.jar
jsp-api.jar
servlet-api.jar
tomcat-coyote.jar
tomcat-dbcp.jar
tomcat-i18n-es.jar
tomcat-i18n-fr.jar
tomcat-i18n-ja.jar
Project lib directory
commons-beanutils-1.7.0.jar
commons-codec-1.3.jar
commons-collections-3.2.jar
commons-digester-1.8.jar
commons-discovery-0.4.jar
commons-el-1.0.jar
commons-logging-1.1.1.jar
jstl-1.2.jar
log4j-1.2.8.jar
myfaces-api-1.2.7.jar
myfaces-impl-1.2.7.jar
tomahawk-1.1.3.jar
Web.xml
<?xml version="1.0" encoding="UTF-8"?>
<web-app version="2.5" xmlns="http://java.sun.com/xml/ns/javaee" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://java.sun.com/xml/ns/javaee http://java.sun.com/xml/ns/javaee/web-app_2_5.xsd">
<servlet>
<servlet-name>Faces Servlet</servlet-name>
<servlet-class>javax.faces.webapp.FacesServlet</servlet-class>
<load-on-startup>1</load-on-startup>
</servlet>
<servlet-mapping>
<servlet-name>Faces Servlet</servlet-name>
<url-pattern>*.faces</url-pattern>
</servlet-mapping>
<session-config>
<session-timeout>
30
</session-timeout>
</session-config>
<welcome-file-list>
<welcome-file>jsp/index.jsp</welcome-file>
</welcome-file-list>
</web-app>
Tomcat Log -
Sep 9, 2009 11:32:01 AM org.apache.catalina.core.StandardContext listenerStart
SEVERE: Exception sending context initialized event to listener instance of class org.apache.myfaces.webapp.StartupServletContextListener
java.lang.NoSuchMethodError: javax.servlet.jsp.JspFactory.getJspApplicationContext(Ljavax/servlet/ServletContext;)Ljavax/servlet/jsp/JspApplicationContext;
at org.apache.myfaces.webapp.Jsp21FacesInitializer.initContainerIntegration(Jsp21FacesInitializer.java:61)
at org.apache.myfaces.webapp.AbstractFacesInitializer.initFaces(AbstractFacesInitializer.java:88)
at org.apache.myfaces.webapp.StartupServletContextListener.contextInitialized(StartupServletContextListener.java:72)
at org.apache.catalina.core.StandardContext.listenerStart(StandardContext.java:3843)
at org.apache.catalina.core.StandardContext.start(StandardContext.java:4342)
at org.apache.catalina.core.ContainerBase.addChildInternal(ContainerBase.java:791)
at org.apache.catalina.core.ContainerBase.addChild(ContainerBase.java:771)
at org.apache.catalina.core.StandardHost.addChild(StandardHost.java:525)
at org.apache.catalina.startup.HostConfig.deployDirectory(HostConfig.java:926)
at org.apache.catalina.startup.HostConfig.deployDirectories(HostConfig.java:889)
at org.apache.catalina.startup.HostConfig.deployApps(HostConfig.java:492)
at org.apache.catalina.startup.HostConfig.start(HostConfig.java:1149)
at org.apache.catalina.startup.HostConfig.lifecycleEvent(HostConfig.java:311)
at org.apache.catalina.util.LifecycleSupport.fireLifecycleEvent(LifecycleSupport.java:117)
at org.apache.catalina.core.ContainerBase.start(ContainerBase.java:1053)
at org.apache.catalina.core.StandardHost.start(StandardHost.java:719)
at org.apache.catalina.core.ContainerBase.start(ContainerBase.java:1045)
at org.apache.catalina.core.StandardEngine.start(StandardEngine.java:443)
at org.apache.catalina.core.StandardService.start(StandardService.java:516)
at org.apache.catalina.core.StandardServer.start(StandardServer.java:710)
at org.apache.catalina.startup.Catalina.start(Catalina.java:578)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
at java.lang.reflect.Method.invoke(Method.java:585)
at org.apache.catalina.startup.Bootstrap.start(Bootstrap.java:288)
at org.apache.catalina.startup.Bootstrap.main(Bootstrap.java:413)
Sep 9, 2009 11:32:02 AM org.apache.catalina.core.ApplicationContext log
INFO: ContextListener: contextInitialized()
Sep 9, 2009 11:32:02 AM org.apache.catalina.core.ApplicationContext log
INFO: SessionListener: contextInitialized()
Tomcat Console
APPSW;C:\Program Files\Microsoft SQL Server\80\Tools\BINN;C:\Program Files\Commo
n Files\Teleca Shared;D:\Microsoft SQL Server2008\100\Tools\Binn\VSShell\Common7
\IDE\;D:\Microsoft SQL Server2008\100\Tools\Binn\;D:\Microsoft SQL Server2008\10
0\DTS\Binn\;C:\Program Files\Microsoft Visual Studio 9.0\Common7\IDE\PrivateAsse
mblies\;C:\WINDOWS\system32\WindowsPowerShell\v1.0;C:\Program Files\CVSNT\
Sep 9, 2009 11:32:00 AM org.apache.coyote.http11.Http11Protocol init
INFO: Initializing Coyote HTTP/1.1 on http-9191
Sep 9, 2009 11:32:00 AM org.apache.catalina.startup.Catalina load
INFO: Initialization processed in 797 ms
Sep 9, 2009 11:32:00 AM org.apache.catalina.core.StandardService start
INFO: Starting service Catalina
Sep 9, 2009 11:32:00 AM org.apache.catalina.core.StandardEngine start
INFO: Starting Servlet Engine: Apache Tomcat/6.0.18
Sep 9, 2009 11:32:01 AM org.apache.catalina.core.StandardContext start
SEVERE: Error listenerStart
Sep 9, 2009 11:32:01 AM org.apache.catalina.core.StandardContext start
SEVERE: Context [MyJsfProj] startup failed due to previous errors
Sep 9, 2009 11:32:02 AM org.apache.coyote.http11.Http11Protocol start
INFO: Starting Coyote HTTP/1.1 on http-9191
Sep 9, 2009 11:32:02 AM org.apache.jk.common.ChannelSocket init
INFO: JK: ajp13 listening on /0.0.0.0:8009
Sep 9, 2009 11:32:02 AM org.apache.jk.server.JkMain start
INFO: Jk running ID=0 time=0/46 config=null
Sep 9, 2009 11:32:02 AM org.apache.catalina.startup.Catalina start
INFO: Server startup in 2749 ms
------------------------------------------------------------------------------------------------------------------------------------------------------------------------
Thanx for reply
i got some R&D in some one of my colleagues with same application war, it was there then working.
at that end also Tomcat & Jdk were same.
at the last i found that some time before, there was a Tomcat 5 window installed server at my machine.
I had removed that properly and checked the CLASSPATH & PATH before facing my myFaces 1.2 problem.
next with some guesses i installed again Tomcat 6 window installer, and now myfaces 1.2 listener problem resolved.
i guess earlier it was taking some association with past Tomcat 5.
now can you advices me some tips to overcome this kind of tomcat environment related problems in future,
also i want to run same with Tomcat 6 Bin installed server also.
Similar Messages
-
Need a way to disable "Exception" button for "Block Pop-up windows" in Tools-> Options -> Content tab. I want to be able to do this for Locking Down Firefox preferences.
== User Agent ==
Mozilla/4.0 (compatible; MSIE 8.0; Windows NT 6.1; Win64; x64; Trident/4.0; .NET CLR 2.0.50727; SLCC2; .NET CLR 3.5.30729; .NET CLR 3.0.30729; Media Center PC 6.0)That button doesn't have a pref associated with it, so you can't disable that button with a pref on the about:config page or a lockPref call.
That only leaves the choice to remove that button with code in userChrome.css
<pre><nowiki>#popupPolicyButton {display:none!important;}</nowiki></pre>
See http://kb.mozillazine.org/Editing_configuration#How_to_edit_configuration_files -
The initial exception that caused the request to fail, was:
com.sap.tc.useragent.UserAgentServiceException: Syntax Error in number '$4' of User-Agent Number Element ID 'engineVersion'.
at com.sap.tc.useragent.ElementTypeNumber.createElement(ElementTypeNumber.java:34)
at com.sap.tc.useragent.UserAgentElement.createElement(UserAgentElement.java:34)
at com.sap.tc.useragent.UserAgentElement.copy(UserAgentElement.java:71)
at com.sap.tc.useragent.UserAgentTemplate.instantiate(UserAgentTemplate.java:45)
at com.sap.tc.useragent.detection.RegExpDetector.detectUserAgent(RegExpDetector.java:33)
... 62 more
See full exception chain for details.
Failed to process request. Please contact your system administrator.
While processing the current request, an exception occured which could not be handled by the application or the framework.
If the information contained on this page doesn't help you to find and correct the cause of the problem, please contact your system administrator. To facilitate analysis of the problem, keep a copy of this error page. Hint: Most browsers allow to select all content, copy it and then paste it into an empty document (e.g. email or simple text file).
For further information about the Web Dynpro error page, error analysis and a description of well-known error situations, see SAP note 1113811.
Correction Hints
Exception could be caused by the development component: com.sap.tc.useragent.interface
Note: The above hints are only a guess. They are automatically derived from the exception that occurred and therefore can't be guaranteed to address the original problem in all cases.
System Environment
Client
Web Dynpro Client Type AJAX Client
User agent Mozilla/5.0 (Android; Mobile; rv:24.0) Gecko/24.0 Firefox/24.0
Client Type ff
Client Type Profile nn7
ActiveX disabled
Java Applets enabled
Accessibility mode disabled
Inline CSS n/a
Validate by rendering true
Server
Web Dynpro Runtime vendor: 'sap.com', name: 'tc/wd/webdynpro', scV: 'sap.com', scN: 'WD-RUNTIME', location: 'SAP AG', counter: '7.3005.20130111125833.0000', R: '7.30', SP: '5', PL: '20', change number: '255333', codeline: NW730CORE_05_REL
J2EE Engine 7.30.3710.270166.20130816104554
System ID (SID) FP1
Server Node ID |13769650|137696|Server 00 01_137696|ciFP1/10.72.16.58|SERVER|RUNNING
Java VM SAP Java Server VM, version:6.1.038 19.1-b02, vendor: SAP AG
Operating system Linux, version: 2.6.32-220.el6.x86_64, architecture: amd64
Application
Java EE Application (deployable object) sap.com/pb
Web Dynpro Application PageBuilder
Request URI /webdynpro/resources/sap.com/pb/PageBuilder
Version vendor: 'sap.com', name: 'pb', scV: 'sap.com', scN: 'EP-RUNTIME', location: 'SAP AG', counter: '7.3005.20111228115104.0000', R: '7.30', SP: '5', PL: '4', change number: '160458'
Session & Other
Session Locale en_GB
Session Timezone India Standard Time
Time of Failure Sun Oct 27 09:59:27 IST 2013 (Java Time: 1382848167814)
Session User ClientUser(id=USER.PRIVATE_DATASOURCE.un:CC172020, name=CC172020)
Http Session Id 978BAO1ZCsh8JZ7REyIA575jsir4QQGyG9IA_SAP
Client Window Id WID1382848129974
Application Session Id CrXVdgZ0571vfwcUljh9Bw--Q4*zmQ0kblXVHMfCG18ZBg--
Web Dynpro Code Generation Infos
sap.com/pb
WD web module webdynpro/resources/sap.com/pb: SapDictionaryGenerationCore 7.3005.20111228114942.0000 (release=NW730CORE_05_REL, buildtime=2011-12-28T16:24:28+0000, changelist=159000, host=pwdfm257, is-central=true)
WD web module webdynpro/resources/sap.com/pb: SapDictionaryGenerationTemplates 7.3005.20111228114942.0000 (release=NW730CORE_05_REL, buildtime=2011-12-28T16:24:57+0000, changelist=159000, host=pwdfm257, is-central=true)
WD web module webdynpro/resources/sap.com/pb: SapGenerationFrameworkCore 7.3005.20111228114942.0000 (release=NW730CORE_05_REL, buildtime=2011-12-28T16:14:41+0000,
WD web module webdynpro/resources/sap.com/pb: SapMetamodelCommon 7.3005.20111228114942.0000 (release=NW730CORE_05_REL, buildtime=2011-12-28T16:17:37+0000, changelist=159372, host=pwdfm257, is-central=true)
WD web module webdynpro/resources/sap.com/pb: SapMetamodelCore 7.3005.20111228114942.0000 (release=NW730CORE_05_REL, buildtime=2011-12-28T16:15:03+0000, changelist=159372, host=pwdfm257, is-central=true)
WD web module webdynpro/resources/sap.com/pb: SapMetamodelDictionary 7.3005.20111228114942.0000 (release=NW730CORE_05_REL, buildtime=2011-12-28T16:20:22+0000, changelist=159002, host=pwdfm257, is-central=true)
WD web module webdynpro/resources/sap.com/pb: SapMetamodelWebDynpro 7.3005.20111228114942.0000 (release=NW730CORE_05_REL, buildtime=2011-12-28T16:25:40+0000, changelist=159462, host=pwdfm257, is-central=true)
WD web module webdynpro/resources/sap.com/pb: SapWebDynproGenerationCore 7.3005.20111228114942.0000 (release=NW730CORE_05_REL, buildtime=2011-12-28T16:37:46+0000, changelist=159461, host=pwdfm257, is-central=true)
WD web module webdynpro/resources/sap.com/pb: SapWebDynproGenerationTemplates 7.3005.20111228114942.0000 (release=NW730CORE_05_REL, buildtime=2011-12-28T16:37:55+0000, changelist=159461, host=pwdfm257, is-central=true)
WD web module webdynpro/resources/sap.com/pb: SapWebDynproRuntimeGen 7.3005.20111228114942.0000 (release=NW730CORE_05_REL, buildtime=2011-12-28T16:35:55+0000, changelist=159464, host=pwdfm257, is-central=true)
sap.com/pb_api
WD (release=NW730CORE_05_REL, buildtime=2011-12-28T16:24:57+0000, changelist=159000, host=pwdfm257, is-central=true)
WD web module webdynpro/resources/sap.com/pb_api: SapGenerationFrameworkCore 7.3005.20111228114942.0000 (release=NW730CORE_05_REL, buildtime=2011-12-28T16:14:41+0000, changelist=159048, host=pwdfm257, is-central=true)
WD web module webdynpro/resources/sap.com/pb_api: SapIdeWebDynproCheckLayer 7.3005.20111228114942.0000 (release=NW730CORE_05_REL, buildtime=2011-12-28T16:37:31+0000, changelist=159461, host=pwdfm257, is-central=true)
WD web module webdynpro/resources/sap.com/pb_api: SapMetamodelCommon 7.3005.20111228114942.0000 (release=NW730CORE_05_REL, buildtime=2011-12-28T16:17:37+0000, changelist=159372, host=pwdfm257, is-central=true)
WD web module webdynpro/resources/sap.com/pb_api: SapMetamodelCore 7.3005.20111228114942.0000 (release=NW730CORE_05_REL, buildtime=2011-12-28T16:15:03+0000, changelist=159372, host=pwdfm257, is-central=true)
WD web module webdynpro/resources/sap.com/pb_api: SapMetamodelDictionary 7.3005.20111228114942.0000 (release=NW730CORE_05_REL, buildtime=2011-12-28T16:20:22+0000, changelist=159002, host=pwdfm257, is-central=true)
WD web module webdynpro/resources/sap.com/pb_api: SapMetamodelWebDynpro 7.3005.20111228114942.0000 (release=NW730CORE_05_REL, buildtime=2011-12-28T16:25:40+0000, changelist=159462, host=pwdfm257, is-central=true)
WD web module webdynpro/resources/sap.com/pb_api: SapWebDynproGenerationCore 7.3005.20111228114942.0000 (release=NW730CORE_05_REL, buildtime=2011-12-28T16:37:46+0000, changelist=159461, host=pwdfm257, is-central=true)
WD web module webdynpro/resources/sap.com/pb_api: SapWebDynproGenerationTemplates 7.3005.20111228114942.0000 (release=NW730CORE_05_REL, buildtime=2011-12-28T16:37:55+0000, changelist=159461, host=pwdfm257, is-central=true)
WD web module webdynpro/resources/sap.com/pb_api: SapWebDynproRuntimeGen 7.3005.20111228114942.0000 (release=NW730CORE_05_REL, buildtime=2011-12-28T16:35:55+0000, changelist=159464, host=pwdfm257, is-central=true)
sap.com/tc~wd~api
WD web module webdynpro/resources/sap.com/tc~wd~api: SapDictionaryGenerationCore 7.3005.20130109144853.0000 (release=NW730CORE_05_REL, buildtime=2013-01-11T17:27:04+0000, changelist=159000, host=pwdfm257, is-central=true)
WD web module webdynpro/resources/sap.com/tc~wd~api: SapDictionaryGenerationTemplates 7.3005.20130109144853.0000 (release=NW730CORE_05_REL, buildtime=2013-01-11T17:27:18+0000, changelist=159000, host=pwdfm257, is-central=true)
WD web module webdynpro/resources/sap.com/tc~wd~api: SapGenerationFrameworkCore 7.3005.20130109144853.0000 (release=NW730CORE_05_REL, buildtime=2013-01-11T17:05:47+0000, changelist=159048, host=pwdfm257, is-central=true)
WD web module webdynpro/resources/sap.com/tc~wd~api: SapIdeWebDynproCheckLayer 7.3005.20130109144853.0000 (release=NW730CORE_05_REL, buildtime=2013-01-11T17:39:20+0000, changelist=180142, host=pwdfm257, is-central=true)
WD web module webdynpro/resources/sap.com/tc~wd~api: SapMetamodelCommon 7.3005.20130109144853.0000 (release=NW730CORE_05_REL, buildtime=2013-01-11T17:10:50+0000, changelist=159372, host=pwdfm257, is-central=true)
WD web module webdynpro/resources/sap.com/tc~wd~api: SapMetamodelCore 7.3005.20130109144853.0000 (release=NW730CORE_05_REL, buildtime=2013-01-11T17:07:26+0000, changelist=159372, host=pwdfm257, is-central=true)
WD web module webdynpro/resources/sap.com/tc~wd~api: SapMetamodelDictionary 7.3005.20130109144853.0000 (release=NW730CORE_05_REL, buildtime=2013-01-11T17:22:41+0000, changelist=210375, host=pwdfm257, is-central=true)
WD web module webdynpro/resources/sap.com/tc~wd~api: SapMetamodelWebDynpro 7.3005.20130109144853.0000 (release=NW730CORE_05_REL, buildtime=2013-01-11T17:27:36+0000, changelist=159462, host=pwdfm257, is-central=true)
WD web module webdynpro/resources/sap.com/tc~wd~api: SapWebDynproGenerationCore 7.3005.20130109144853.0000 (release=NW730CORE_05_REL, buildtime=2013-01-11T17:39:36+0000, changelist=180142, host=pwdfm257, is-central=true)
WD web module webdynpro/resources/sap.com/tc~wd~api: SapWebDynproGenerationTemplates 7.3005.20130109144853.0000 (release=NW730CORE_05_REL, buildtime=2013-01-11T17:39:43+0000, changelist=180142, host=pwdfm257, is-central=true)
WD web module webdynpro/resources/sap.com/tc~wd~api: SapWebDynproRuntimeGen 7.3005.20130109144853.0000 (release=NW730CORE_05_REL, buildtime=2013-01-11T17:37:00+0000, changelist=223591, host=pwdfm257, is-central=true)Oh man it looks like a problem with the web server.
Its an error that happens on SAP, even my dad reported an error like this to me but i wasn't able to solve it.
What i find is that its an error with browser incompatibility,
Check this http://scn.sap.com/message/10338540 -
How to create a single login for multiple apps on tomcat server?
Hello,
I am running the most recent versions of apache and tomcat on several dells with XP pro.
When I login to an app I have created, a session variable is set, but when I browse to one of the other apps on the same computer, it does not recognize that the session variable has been set and I have to login again.
Can somebody please suggest how, or where I can find docs, to configure tomcat to pass the session variables to other apps?
Thank you very much.
Or, can anybody suggest the most effective strategy for creating single-logon functionality for multiple apps with tomcat and apache running on one computer? and with tomcat and apache running on multiple computers? (i.e., each computer has tomcat and apache integrated).
The database is Oracle 10g running on each computer.
Thank you again.A good place to start is http://www.javaworld.com/javaworld/javatips/jw-javatip34.html
Also, do a search in this forum on HttpURLConnection. That class allows you to use POST method to send form data to a web server.
"Hidden" variables are only hidden in HTML. The HTTP that gets POSTed to the web server doesn't distinguish between hidden and not hidden. That is, the content you would write to the HttpURLConnection.getOutputStream() would be something like:
hidden=1&submit=ok(Of course, the variable names would depend on what the web server was expecting from the form.)
Also, be sure to set the Content-Type request parameter to "application/x-www-form-urlencoded" -
Exception handling for all the insert statements in the proc
CREATE PROCEDURE TEST (
@IncrStartDate DATE
,@IncrEndDate DATE
,@SourceRowCount INT OUTPUT
,@TargetRowCount INT OUTPUT
,@ErrorNumber INT OUTPUT
,@ErrorMessage VARCHAR(4000) OUTPUT
,@InsertCase INT --INSERT CASE INPUT
WITH
EXEC AS CALLER AS
BEGIN --Main Begin
SET NOCOUNT ON
BEGIN TRY
DECLARE @SuccessNumber INT = 0
,@SuccessMessage VARCHAR(100) = 'SUCCESS'
,@BenchMarkLoadFlag CHAR(1)
,@BenchmarkFlow INT
,@MonthYearStart DATE
,@MonthYearEnd DATE
,@StartDate DATE
,@EndDate DATE
/* Setting the default values of output parameters to 0.*/
SET @SourceRowCount = 0
SET @TargetRowCount = 0
/*Setting the Start and end date for looping */
SET @MonthYearStart = @IncrStartDate;
SET @MonthYearEnd = @IncrEndDate;
/* Setting the @InsertCase will ensure case wise insertion as this sp will load data in different tables
@InsertCase =0 means data will be inserted in the target TAB1
@InsertCase =1 means data will be inserted in the target TAB2
@InsertCase =2 means data will be inserted in the target TAB3
@InsertCase =3 means data will be inserted in the target TAB4
@InsertCase =4 means data will be inserted in the target TAB5
@InsertCase =5 means data will be inserted in the target TAB6
if @InsertCase =0
WHILE (@MonthYearStart <= @MonthYearEnd)
BEGIN
SET @StartDate = @MonthYearStart;
SET @EndDate = @MonthYearEnd;
/* Delete from target where date range given from input parameter*/
DELETE FROM TAB1
WHERE [MONTH] BETWEEN MONTH(@StartDate) AND MONTH(@EndDate)
AND [YEAR] BETWEEN year(@StartDate) and year(@EndDate)
/*Insert data in target-TAB1 */
BEGIN TRANSACTION
INSERT INTO TAB1
A,B,C
SELECT
A,BC
FROM XYZ
COMMIT TRANSACTION
SET @MonthYearStart = DATEADD(MONTH, 1, @MonthYearStart)
SELECT @TargetRowCount = @TargetRowCount + @@ROWCOUNT;
END -- End of whileloop
END TRY
BEGIN CATCH
IF @@TRANCOUNT>0
ROLLBACK TRANSACTION
SELECT @ErrorNumber = ERROR_NUMBER() ,@ErrorMessage = ERROR_MESSAGE();
END CATCH
END--End of Main Begin
I have the above proc inserting data based on parameters where in @InsertCase is used for case wise execution.
I have written the whole proc with exception handling using try catch block.
I have just added one insert statement here for 1 case now I need to add further insert cases
INSERT INTO TAB4
A,B,C
SELECT
A,BC
FROM XYZ
INSERT INTO TAB3
A,B,C
SELECT
A,BC
FROM XYZ
INSERT INTO TAB2
A,B,C
SELECT
A,BC
FROM XYZ
I will be using following to insert further insert statements
if @InsertCase =1
I just needed to know where will be my next insert statement should be fitting int his code so that i cover exception handling for all the code
MudassarHi Erland & Mudassar, I have attempted to recreate Mudassar's original problem..here is my TABLE script;
USE [MSDNTSQL]
GO
/****** Object: Table [dbo].[TAB1] Script Date: 2/5/2014 7:47:48 AM ******/
SET ANSI_NULLS ON
GO
SET QUOTED_IDENTIFIER ON
GO
CREATE TABLE [dbo].[TAB1](
[COL1] [nvarchar](1) NULL,
[COL2] [nvarchar](1) NULL,
[COL3] [nvarchar](1) NULL,
[START_MONTH] [int] NULL,
[END_MONTH] [int] NULL,
[START_YEAR] [int] NULL,
[END_YEAR] [int] NULL
) ON [PRIMARY]
GO
Then here is a CREATE script for the SPROC..;
USE [MSDNTSQL]
GO
/****** Object: StoredProcedure [dbo].[TryCatchTransactions1] Script Date: 2/5/2014 7:51:33 AM ******/
SET ANSI_NULLS ON
GO
SET QUOTED_IDENTIFIER ON
GO
CREATE PROCEDURE [dbo].[TryCatchTransactions1] (
@IncrStartDate DATE
,@IncrEndDate DATE
,@SourceRowCount INT OUTPUT
,@TargetRowCount INT OUTPUT
,@ErrorNumber INT OUTPUT
,@ErrorMessage VARCHAR(4000) OUTPUT
,@InsertCase INT --INSERT CASE INPUT
WITH
EXEC AS CALLER AS
BEGIN --Main Begin
SET NOCOUNT ON
BEGIN TRY
DECLARE @SuccessNumber INT = 0
,@SuccessMessage VARCHAR(100) = 'SUCCESS'
,@BenchMarkLoadFlag CHAR(1)
,@BenchmarkFlow INT
,@MonthYearStart DATE
,@MonthYearEnd DATE
,@StartDate DATE
,@EndDate DATE
/* Setting the default values of output parameters to 0.*/
SET @SourceRowCount = 0
SET @TargetRowCount = 0
/*Setting the Start and end date for looping */
SET @MonthYearStart = @IncrStartDate;
SET @MonthYearEnd = @IncrEndDate;
/* Setting the @InsertCase will ensure case wise insertion as this sp will load data in different tables
@InsertCase =0 means data will be inserted in the target TAB1
@InsertCase =1 means data will be inserted in the target TAB2
@InsertCase =2 means data will be inserted in the target TAB3
@InsertCase =3 means data will be inserted in the target TAB4
@InsertCase =4 means data will be inserted in the target TAB5
@InsertCase =5 means data will be inserted in the target TAB6
IF @InsertCase =0
WHILE (@MonthYearStart <= @MonthYearEnd)
BEGIN
SET @StartDate = @MonthYearStart;
SET @EndDate = @MonthYearEnd;
/* Delete from target where date range given from input parameter*/
DELETE FROM TAB1
WHERE START_MONTH BETWEEN MONTH(@StartDate) AND MONTH(@EndDate)
AND START_YEAR BETWEEN year(@StartDate) and YEAR(@EndDate)
/*Insert data in target-TAB1 */
BEGIN TRANSACTION
INSERT INTO TAB1 (COL1,COL2,COL3)
VALUES ('Z','X','Y')
SELECT COL1, COL2, COL3
FROM TAB1
COMMIT TRANSACTION
SET @MonthYearStart = DATEADD(MONTH, 1, @MonthYearStart)
SELECT @TargetRowCount = @TargetRowCount + @@ROWCOUNT;
END -- End of whileloop
END TRY
BEGIN CATCH
IF @@TRANCOUNT > 0
ROLLBACK TRANSACTION
SELECT @ErrorNumber = ERROR_NUMBER() ,@ErrorMessage = ERROR_MESSAGE();
END CATCH
PRINT @SUCCESSMESSAGE
END--End of Main Begin
GO
I am just trying to help --danny rosales
UML, then code -
Which is better for servers, Apache or Tomcat?
Which is better for servers, Apache or Tomcat?
For some reason that link I gave you isn't working right now, but it was today, weird. I would get Tomcat simple because sun uses it in its examples and recommends it. Here's sun's link then, it's probably more useful anyway. http://java.sun.com/products/jsp/
-
I've installed bootcamp 4.0 on my iMac 27. Everything works superb, but for playing need for speed run or battlefield 3 I need catalyst driver 11.7 or higher. How can I update my graphics? Is there a possibility except waiting for a new bootcamp version?
But how do you install the drivers if Bootcamp is running interference?
Bottom line, I'ev tried to install three different versions of updated ATI driver sover the last few momnths and on each and every occassion have ended up with the original Bootcamp driver. A number of current games are unplayable on a Mac running Bootcamp as a result.
And if I can't run the software I want, then Bootcamp is as useless as boobs on a bull. -
MRP Type V1 - Does it create Exception Message for "Reschedule-in"?
Hello Experts,
We are using MRP Type V1 (Which has the Manual Re-Order Planning + External Requirements). However we are facing and issue with the Rescheduling part. Scenario is as following:
Material ROP is - 5000
Open Pur Ord is - 5000 (due in 01 June'09) based on the Std Lead time of the Material
Stok on hand is - 0
At this point a Sales Order is entered for 1000 pcs
After MRP Run, we expect an Exception Message for the Purchase Order to have "Reschedule-in". But, instead, system creates a PReq for 1000 pcs and the required date is NOT the Sales Order required Date but based on the Std Lead Time of the Material.
I have set the Material Lead time - 60 Days
I have set the Reschedule horizon - 0 Days ( I even tried with different Days but NO use)
However, when I change the MRP Type to PD, system generates a "Reschedule-in" Exception Message for the Purchase Order.
How can I get the "Reschedule-in" Exception Message for the Purchase Order with the MRP Type V1?
Thanks for your help in Advance!Anil,
Reorder point/External MRP performs net requirements calculation (within replenishment lead time). If the existing firmed supply elements minus the existing requirements bring the projected stock below ROP, it will propose an order that will bring the projected stock back to reorder point. The proposal will generally come at replenishment lead time.
In the normal business cycle, your sales order would confirm to lead time, and you now have a confirmed sales requirement at lead time, plus a new purchase req to bring the stock back to the reorder point. The scenario you have described is working exactly as it is designed. Consumption based MRP will not normally try to reschedule supply elements to match requirements inside of lead time.
Rescheduling horizon generally is counted from the end of lead time. It won't help you here.
I guess if you insist on having a reschedule message, you could change your lead time to 0 days. Not a wise move in my opinion. You then have locked yourself in your choices of types of Sales order availability checks into one that ignores lead time. You also have to find a way to let your buyers/planners know what the 'real' lead time is when they place their orders on the vendors.
I don't know why you are using a consumption-based planning type (reorder point). It sounds like your business requirements are that you actually need to be using a demand-type planning method (eg, your supply elements are driven by your demand, not by a reorder point/desired stock level). If PD works the way you want, why aren't you using it?
Regards,
DB49 -
Exception Handling for many bean objects of a container class in a JSP page
Hello,
I have on container bean class. In this container class, there are several others class objects and the getter methods to get these objects out to the JSP pages.
I have one JSP page which will use different objects in the container class object through the getter methods of the container class.
My question is how to implement the exception handler for all the objects in the container so that the JSP page can handle all exceptions if occurrs in any object in the container?
Please give me some suggestions. Thanks
TuThanks for your reply.
Since the container is the accessor class, I have no other super class for this container class, I think I will try the try catch block in the getter methods. -
Exception Message for Lower Level
Hi everyone...
I get this message:
"Exception Message for Lower Level"
after of one MD02, for my FERT Material.
This FERT material has 2 lower levels, for a couple HALBs material in the next level and other HALB material into the level 3.
I don't get the requeriments for the HALBs materials, when I select the Order Report for the PlOrd.
This 3 materials are produced since level 3 up to level 1 into the same plant, therefore I need to see the requeriment of the Level 3 to produce and then, use it for the Level 2 and till the Level 1., but I'm recieving this message.
Thanks in advance.
OPHi,
Not quite understandable ur query
can u re-phrase it, anyways
as per my understanding
u are not getting plan orders for (HALB'S)
just check the stock for that HALB'S &
just execute CS11, CS12 for that header material & check
whether BOM is getting exploded or not (upto all levels)
Regards
kumar -
Once in a while i get the error
Event ID 6463
The timer service encountered an exception checking for the upgrade mode registry key. Requested registry access is not allowed.
This also happens when i restart the timer service.
I already cleared the SharePoint cache (xml's) but no success with that.
Environment is
SharePoint 2013 SP1 + CU Dec 2014This is a brand new SP13 with SP1 installation after binaries installation i also installed Dec 2014 CU and then created the SP farm.
The Apppool/Timer account is member of WSS_ADMIN_WPG.
Issue can be reproduced with restarting SharePoint Timer Service.
Hereby the Process Monitor output. Hence i filtered it on NOT SUCCESS and Path contains the word UPGRADE
11:37:57,4244851 OWSTIMER.EXE
6272 RegQueryValue
HKLM\SOFTWARE\Microsoft\Shared Tools\Web Server Extensions\15.0\WSS\UpgradeLogLevelOverride
NAME NOT FOUND Length: 144
11:37:57,6632057 OWSTIMER.EXE
6272 RegOpenKey
HKLM\SOFTWARE\Microsoft\Fusion\PublisherPolicy\Default\v4.0_policy.15.0.Microsoft.Office.Access.Services.Moss.Upgrade__71e9bce111e9429c
NAME NOT FOUND Desired Access: Read
11:37:57,6632889 OWSTIMER.EXE
6272 RegOpenKey
HKLM\SOFTWARE\Microsoft\Fusion\PublisherPolicy\Default\policy.15.0.Microsoft.Office.Access.Services.Moss.Upgrade__71e9bce111e9429c
NAME NOT FOUND Desired Access: Read
11:37:57,7140763 OWSTIMER.EXE
6272 RegOpenKey
HKLM\SOFTWARE\Microsoft\Fusion\PublisherPolicy\Default\v4.0_policy.15.0.Microsoft.PerformancePoint.Scorecards.Upgrade__71e9bce111e9429c
NAME NOT FOUND Desired Access: Read
11:37:57,7141089 OWSTIMER.EXE
6272 RegOpenKey
HKLM\SOFTWARE\Microsoft\Fusion\PublisherPolicy\Default\policy.15.0.Microsoft.PerformancePoint.Scorecards.Upgrade__71e9bce111e9429c
NAME NOT FOUND Desired Access: Read
11:37:57,7313089 OWSTIMER.EXE
6272 RegOpenKey
HKLM\SOFTWARE\Microsoft\Fusion\PublisherPolicy\Default\v4.0_policy.15.0.Microsoft.SharePoint.Portal.Upgrade__71e9bce111e9429c
NAME NOT FOUND Desired Access: Read
11:37:57,7313403 OWSTIMER.EXE
6272 RegOpenKey
HKLM\SOFTWARE\Microsoft\Fusion\PublisherPolicy\Default\policy.15.0.Microsoft.SharePoint.Portal.Upgrade__71e9bce111e9429c
NAME NOT FOUND Desired Access: Read
11:37:59,2026527 OWSTIMER.EXE
6272 RegQueryValue
HKLM\SOFTWARE\Microsoft\Shared Tools\Web Server Extensions\15.0\WSS\MS_InternalUse_Only_UpgradeableVersion
NAME NOT FOUND Length: 144
11:37:59,2109400 OWSTIMER.EXE
6272 RegQueryValue
HKLM\SOFTWARE\Microsoft\Shared Tools\Web Server Extensions\15.0\WSS\MS_InternalUse_Only_UpgradeableVersion
NAME NOT FOUND Length: 144
11:38:05,3534303 OWSTIMER.EXE
6272 RegQueryValue
HKLM\SOFTWARE\Microsoft\Shared Tools\Web Server Extensions\15.0\WSS\MS_InternalUse_Only_UpgradeableVersion
NAME NOT FOUND Length: 144
11:38:05,3537846 OWSTIMER.EXE
6272 RegQueryValue
HKLM\SOFTWARE\Microsoft\Shared Tools\Web Server Extensions\15.0\WSS\MS_InternalUse_Only_UpgradeableVersion
NAME NOT FOUND Length: 144
11:38:05,3594290 OWSTIMER.EXE
6272 RegQueryValue
HKLM\SOFTWARE\Microsoft\Shared Tools\Web Server Extensions\15.0\WSS\MS_InternalUse_Only_UpgradeableVersion
NAME NOT FOUND Length: 144
11:38:05,3597316 OWSTIMER.EXE
6272 RegQueryValue
HKLM\SOFTWARE\Microsoft\Shared Tools\Web Server Extensions\15.0\WSS\MS_InternalUse_Only_UpgradeableVersion
NAME NOT FOUND Length: 144
11:38:05,3653094 OWSTIMER.EXE
6272 RegQueryValue
HKLM\SOFTWARE\Microsoft\Shared Tools\Web Server Extensions\15.0\WSS\MS_InternalUse_Only_UpgradeableVersion
NAME NOT FOUND Length: 144
11:38:05,3656118 OWSTIMER.EXE
6272 RegQueryValue
HKLM\SOFTWARE\Microsoft\Shared Tools\Web Server Extensions\15.0\WSS\MS_InternalUse_Only_UpgradeableVersion
NAME NOT FOUND Length: 144 -
Exception handling for ProjectService methods in a new 2006 DI API
Normally for other objects the Add() method returns error code and calling the GetLastError you get the description.
AddProject(Project) method of ProjectService returns ProjectParams object.
So the question is where to get the error code or what is the correct exception handling for that new methods in 2006 SDK.
Thanks for any help.
TomasHi all,
I have a sceranio :
I created the text field, text box, com bobox .etc, on new form or exist form.
When I want to bind data into UDO, i use "DataBind.setBound"
ex:"oEdit.DataBind.SetBound(True, "@SM_OMOR", "U_Room")"
Can i bind the data to exist table on B1?
ex: oEdit.DataBind.setBound(True, "OHEM", "firstName")
Plz guid !
Rgds ! -
List of BO executable that need to be put in exception list for the block s
Hi,
I am trying to configure the BO server to send automated emails from the server on failure of any report or program.
I know the BO side configuration details and done it successfully using SMTP email facility with BO.
But my McAfee administrator is facing problem with configuring McAfee to allow email to be send from BO server.
She need the list of BO executable that need to be put in exception list for the block sending email.
I also tested my BO configuration by stopping McAfee antivirus services and its working fine.
Thanks
NinadThe easiest way to do this is going to be to go to the Central Configuration Manager (CCM). For each "server" listed, go to the properties and look at the Command - this will show you the name of the executable for that server. Each of these needs to be in the exception list.
-Dell -
May I use Exception Handling for validation ?
Hello All,
Can any one know about that may i use exception handling for validation in my report program.
Please if its possible then give me some Example...
Thanks.Hi Niraj,
Exception is not at all raised or handled in the given example.
There are so many document available in the SCN regarding OO ABAP you can read that.
As far as validation of a field ( Selection screen ) of course we can do that but I don't see any advantage more over it will make your code unnecessarily complex.
Regards
Bikas -
No Exception Defined for System Errors
hi,
I am capturing system messages through an Exception error handler in the block step of Integration Processes.
Its a IDOC -> XI -> HTTP Receiver scenario.
When i execute the scenario, i see an error in the workflow in the Block Step. It shows an Error which says "No Exception Defined for System Errors", though i have a Exception Branch in the Block step.
Any clues why i am not able to capture the Exception errors and send it through email.
Its failing at the Block step.
More details on the scenario:
1. Start
2. Receive Step - Asynch - IDOC
3. Block Step - with Exception name as "TimeOut"
3.1 Exception Branch with exception handler as "Timeout"
3.1.1 - Transform Step - to transform a Exception message(with just one field) to "Error" message (with 5 fields)
3.1.2 - Send Step - send the "Error" message through email
3.2 Deadline branch set to 1 minute
3.3 Switch step
3.3.1 Transformation step - to transform the IDOC to XML
3.3.2 Send step - Synch - request xml and response xml defined in this step
4. Switch Step
4.1 - Transform step - transforms the idoc and xml response to the actual error
4.2 - Send Step - sends the actual error to the email message using MAIL adapter.
Any tips would be grateful.
Thanks,
TirumalStefan -
In step 3.3.2
I did find the property exceptions and assigned the exception branch in the block and ran the scenario, now i get an error saying that : "Exception Timeout Occurred."
I went through the Technical Details of the workflow and the error displayed there is "Exception 'Timeout' caught and transferred to the exception handler'.
In step 3.1.1
I get an error saying "No Payload found'.
Does this mean its not able to capture the message text.
Thanks in advance,
Tirumal
Maybe you are looking for
-
Can I use the speakers on my Thunderbolt as well as my Computer at the same time?
I am trying to use the speakers on my iMac as well as the speakers on the Thunderbolt display. Any one know a way to accomplish this?
-
Macbook pro facetime wont connect
Recently purchased a 13" Macbook pro but can't connect on face time. When I make a call (I am currently in the US - my friend is in the UK) it says 'connecting' but then rings out and says my friend is unavailable. When my friend calls me, I accept,
-
Output only with "black frame"??
Hi there, I am editing rendered animations from cinema4d, which are in the format 768x480 (image on the right). I´ve been trying everything to export them in exactly that format in QT. I can´t find any export option to get a movie with a screen that
-
How to change default properties when uploading role
Hi, all. Our env. is like the following. EP 6.0 SP9 patch1 J2EE SP9 Windows 2003 MS SQL Server When we upload a role from R/3 to EP, role is correctly uploaded but the problem is the following default behavior. - default property of entryPoi
-
Cursor doesn't focus to the newly created row.
I am using JDeveloper 11.1.1.4 . Whenever I create a new row in adf table, the cursor doesn't focus to the new row.It always focuses to the last row which clicked before adding the new row.