Hi Larry, When using <cfstoredproc />, you need a <cfprocparam /> to specify _ALL_ parameters passed to and from the Stored procedure!!
So need to check your CF code where you are calling the Stored Proc. Later, Niall. -----Original Message----- From: Larry Juncker [mailto:[EMAIL PROTECTED] Sent: 17 September 2008 12:51 To: CF-Talk Subject: Error converting data type varchar to int. I keep getting an error that appears to be in my <cfprocresult as follows..... Any quick help would be greatly appreciated.... I hope that I have included enough information for some help. Thanks in advance TABLE SCHEMA - [dbo].[tbl_Schol] scholid int Unchecked name varchar(50) Checked schol_type_id int Checked scholarships_uid int Checked academic_uid int Checked tablename varchar(50) Checked Student_UID int Checked TABLE DATA - [dbo].[tbl_Schol] 1 Baseball 14 14 14 Baseball 1 2 Football 3 3 1 Football 3 3 Football 3 1 1 Football 4 4 Football 3 7 1 Football 7 5 Football 3 5 1 Football 5 6 Football 3 8 1 Football 8 7 Football 3 8 1 Football 10 8 Football 0 0 0 Football 11 9 Football 0 0 0 Football 12 NULL NULL NULL NULL NULL NULL NULL STORED PROCEDURE - [dbo].[sp_Schol_ins] set ANSI_NULLS ON set QUOTED_IDENTIFIER ON GO -- ============================================= -- Author: Larry Juncker -- Create date: 2008-09-15 -- Description: This SP will insert a new scolarship record into the Athlete table -- ============================================= ALTER PROCEDURE [dbo].[sp_Schol_ins] -- Add the parameters for the stored procedure here --<@Param1, sysname, @p1> <Datatype_For_Param1, , int> = <Default_Value_For_Param1, , 0>, @name varchar(50) = NULL, @schol_type_id int = NULL, @scholarships_uid int = NULL, @academic_uid int = NULL, @tablename varchar(50) = NULL, @Student_UID int = NULL AS BEGIN -- SET NOCOUNT ON added to prevent extra result sets from -- interfering with SELECT statements. SET NOCOUNT ON; -- Insert statements for procedure here --SELECT <@Param1, sysname, @p1>, <@Param2, sysname, @p2> INSERT INTO [dbo].[tbl_Schol] ([name], [schol_type_id], [scholarships_uid], [academic_uid], [tablename], [Student_UID]) VALUES (@name, @schol_type_id, @scholarships_uid, @academic_uid, @tablename, @Student_UID) SELECT TOP 1 * FROM [dbo].[tbl_Schol] ORDER BY ScholID DESC RETURN END COLD FUSION CODE <cftransaction> <cfstoredproc procedure="sp_schol_ins" datasource="profilesandgo"> <cfprocparam type="In" cfsqltype="CF_SQL_INTEGER" dbVarName="Student_UID" value="#Form.Student_UID#" null="No"> <cfprocparam type="In" cfsqltype="CF_SQL_VARCHAR" dbVarName="TableName" value="#FORM.Sport#" null="No"> <cfprocparam type="In" cfsqltype="CF_SQL_VARCHAR" dbVarName="Name" value="#FORM.Sport#" null="No"> <cfprocresult name="InsertSchol" resultset="1"> </cfstoredproc> </cftransaction> COLD FUSION ERROR The web site you are accessing has experienced an unexpected error. Please contact the website administrator. The following information is meant for the website developer for debugging purposes. Error Occurred While Processing Request Error Executing Database Query. [Macromedia][SQLServer JDBC Driver][SQLServer]Error converting data type varchar to int. The error occurred in C:\Inetpub\wwwroot\statsandgo\members\Student\Sports\form2action.cfm: line 56 54 : <cfprocparam type="In" cfsqltype="CF_SQL_VARCHAR" dbVarName="Name" value="#FORM.Sport#" null="No"> 55 : 56 : <cfprocresult name="InsertSchol" resultset="1"> 57 : </cfstoredproc> 58 : </cftransaction> ---------------------------------------------------------------------------- ---- SQLSTATE HY000 SQL {call sp_schol_ins( (param 1) , (param 2) , (param 3) )} VENDORERRORCODE 8114 DATASOURCE profilesandgo Resources: Check the ColdFusion documentation to verify that you are using the correct syntax. Search the Knowledge Base to find a solution to your problem. Browser Mozilla/4.0 (compatible; MSIE 7.0; Windows NT 5.1; .NET CLR 2.0.50727; .NET CLR 1.1.4322; .NET CLR 3.0.04506.648; .NET CLR 3.5.21022) w:PACBHO60 Remote Address 74.33.132.212 Referrer http://www.statsandgo.com/members/student/sports/form2.cfm Date/Time 17-Sep-08 06:41 AM Stack Trace (click to expand) at cfform2action2ecfm1601602585.runPage(C:\Inetpub\wwwroot\statsandgo\members\S tudent\Sports\form2action.cfm:56) at cfform2action2ecfm1601602585.runPage(C:\Inetpub\wwwroot\statsandgo\members\S tudent\Sports\form2action.cfm:56) java.sql.SQLException: [Macromedia][SQLServer JDBC Driver][SQLServer]Error converting data type varchar to int. at macromedia.jdbc.base.BaseExceptions.createException(Unknown Source) at macromedia.jdbc.base.BaseExceptions.getException(Unknown Source) at macromedia.jdbc.sqlserver.tds.TDSRequest.processErrorToken(Unknown Source) at macromedia.jdbc.sqlserver.tds.TDSRequest.processReplyToken(Unknown Source) at macromedia.jdbc.sqlserver.tds.TDSRPCRequest.processReplyToken(Unknown Source) at macromedia.jdbc.sqlserver.tds.TDSRequest.processReply(Unknown Source) at macromedia.jdbc.sqlserver.SQLServerImplStatement.getNextResultType(Unknown Source) at macromedia.jdbc.base.BaseStatement.commonTransitionToState(Unknown Source) at macromedia.jdbc.base.BaseStatement.postImplExecute(Unknown Source) at macromedia.jdbc.base.BasePreparedStatement.postImplExecute(Unknown Source) at macromedia.jdbc.base.BaseStatement.commonExecute(Unknown Source) at macromedia.jdbc.base.BaseStatement.executeInternal(Unknown Source) at macromedia.jdbc.base.BasePreparedStatement.execute(Unknown Source) at macromedia.jdbc.base.BasePreparedStatementPoolable.execute(Unknown Source) at coldfusion.server.j2ee.sql.JRunPreparedStatement.execute(JRunPreparedStateme nt.java:89) at coldfusion.sql.Executive.executeCall(Executive.java:860) at coldfusion.sql.Executive.executeCall(Executive.java:775) at coldfusion.sql.Executive.executeCall(Executive.java:726) at coldfusion.sql.SqlImpl.executeCall(SqlImpl.java:445) at coldfusion.tagext.sql.StoredProcTag.executeQuery(StoredProcTag.java:272) at coldfusion.tagext.sql.StoredProcTag.doEndTag(StoredProcTag.java:225) at cfform2action2ecfm1601602585.runPage(C:\Inetpub\wwwroot\statsandgo\members\S tudent\Sports\form2action.cfm:56) at coldfusion.runtime.CfJspPage.invoke(CfJspPage.java:192) at coldfusion.tagext.lang.IncludeTag.doStartTag(IncludeTag.java:366) at coldfusion.filter.CfincludeFilter.invoke(CfincludeFilter.java:65) at coldfusion.filter.ApplicationFilter.invoke(ApplicationFilter.java:279) at coldfusion.filter.RequestMonitorFilter.invoke(RequestMonitorFilter.java:48) at coldfusion.filter.MonitoringFilter.invoke(MonitoringFilter.java:40) at coldfusion.filter.PathFilter.invoke(PathFilter.java:86) at coldfusion.filter.ExceptionFilter.invoke(ExceptionFilter.java:70) at coldfusion.filter.BrowserDebugFilter.invoke(BrowserDebugFilter.java:74) at coldfusion.filter.ClientScopePersistenceFilter.invoke(ClientScopePersistence Filter.java:28) at coldfusion.filter.BrowserFilter.invoke(BrowserFilter.java:38) at coldfusion.filter.NoCacheFilter.invoke(NoCacheFilter.java:46) at coldfusion.filter.GlobalsFilter.invoke(GlobalsFilter.java:38) at coldfusion.filter.DatasourceFilter.invoke(DatasourceFilter.java:22) at coldfusion.filter.RequestThrottleFilter.invoke(RequestThrottleFilter.java:12 6) at coldfusion.CfmServlet.service(CfmServlet.java:175) at coldfusion.bootstrap.BootstrapServlet.service(BootstrapServlet.java:89) at jrun.servlet.FilterChain.doFilter(FilterChain.java:86) at coldfusion.monitor.event.MonitoringServletFilter.doFilter(MonitoringServletF ilter.java:42) at coldfusion.bootstrap.BootstrapFilter.doFilter(BootstrapFilter.java:46) at jrun.servlet.FilterChain.doFilter(FilterChain.java:94) at jrun.servlet.FilterChain.service(FilterChain.java:101) at jrun.servlet.ServletInvoker.invoke(ServletInvoker.java:106) at jrun.servlet.JRunInvokerChain.invokeNext(JRunInvokerChain.java:42) at jrun.servlet.JRunRequestDispatcher.invoke(JRunRequestDispatcher.java:284) at jrun.servlet.ServletEngineService.dispatch(ServletEngineService.java:543) at jrun.servlet.jrpp.JRunProxyService.invokeRunnable(JRunProxyService.java:203) at jrunx.scheduler.ThreadPool$DownstreamMetrics.invokeRunnable(ThreadPool.java: 320) at jrunx.scheduler.ThreadPool$ThreadThrottle.invokeRunnable(ThreadPool.java:428 ) at jrunx.scheduler.ThreadPool$UpstreamMetrics.invokeRunnable(ThreadPool.java:26 6) at jrunx.scheduler.WorkerThread.run(WorkerThread.java:66) ---------------------------------------------------------------------------- ---- Debugging Information ColdFusion Server Standard 8,0,0,176276 Template /members/student/sports/form2action.cfm Time Stamp 17-Sep-08 06:41 AM Locale English (US) User Agent Mozilla/4.0 (compatible; MSIE 7.0; Windows NT 5.1; .NET CLR 2.0.50727; .NET CLR 1.1.4322; .NET CLR 3.0.04506.648; .NET CLR 3.5.21022) w:PACBHO60 Remote IP 74.33.132.212 Host Name 74.33.132.212 FORM FIELDS Form Fields: COACH_UID=0 CONTINUE=Continue DB_I_ASSISTS= DB_I_BLOCKED_FIELD_GOALS= DB_I_BLOCKED_PASSES= DB_I_BLOCKED_PUNTS= DB_I_COMPLETIONS= DB_I_DEFENSIVE_INTERCEPTIONS= DB_I_FIELD_GOALS_ATTEMPTED= DB_I_FIELD_GOALS_MADE= DB_I_FUMBLES= DB_I_FUMBLES_CAUSED= DB_I_FUMBLES_RECOVERED= DB_I_GAMES_PLAYED=45 DB_I_GAMES_STARTED=50 DB_I_INTERCEPTIONS= DB_I_KILLS_INSIDE_20= DB_I_LONGEST_FIELD_GOAL= DB_I_LONGEST_PUNT= DB_I_PASSING_ATTEMPTS= DB_I_PUNTS= DB_I_RECEIVING_TD= DB_I_RECEIVING_YARDS= DB_I_RECEPTIONS= DB_I_RUSHES= DB_I_RUSHES_ON_PASSER= DB_I_RUSHING_TD= DB_I_RUSHING_YARDS= DB_I_SACKS= DB_I_TACKLES= DB_I_TACKLES_FOR_LOSS= DB_I_TD_PASSES= DB_I_THROWING_YARDS= DB_I_TOTAL_POINTS_SCORED= DB_N_AVERAGE_PER_PUNT= DB_N_COMPLETION_PERCENTAGE= DB_N_EXTRA_POINT_PERCENTAGE= DB_N_FIELD_GOAL_PERCENTAGE= DB_N_KICK_OFF_RETURN_AVERAGE= DB_N_PUNT_RETURN_AVERAGE= DB_N_YARDS_PER_CARRY= DB_T_GRADE=SR DB_T_PRIMARY_POSITION=Wide Receiver PROCESSFORM=Y SPORT=Football STUDENT_UID=12 ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~| Adobe® ColdFusion® 8 software 8 is the most important and dramatic release to date Get the Free Trial http://ad.doubleclick.net/clk;203748912;27390454;j Archive: http://www.houseoffusion.com/groups/CF-Talk/message.cfm/messageid:312660 Subscription: http://www.houseoffusion.com/groups/CF-Talk/subscribe.cfm Unsubscribe: http://www.houseoffusion.com/cf_lists/unsubscribe.cfm?user=89.70.4

