[x]
Posted via EE Mobile

Search, ask, and monitor your questions on the go with EE Mobile. Visit Experts Exchange from your mobile device and never be out of touch again.

Question
[x]
Attachment Details
[x]
The Solution Rating System

With so many solutions, how can you tell which solutions are most likely to help you and which ones are not? To provide you with a tool to use, we rate our solutions based on various elements that most accurately determine if a solution is a quality solution. To explain what factors affect the solution rating, here are the elements we take into consideration when formulating our solution rating.

  • The Grade of the Solution
  • The Zone Rank of the Expert Providing the Solution
  • The Number of Author and Expert Comments
  • The Number of Experts Contributing
  • The Feedback of the Community

Your Input Matters
Because of the way the system is set up, the most important variable in this equation is you. As a member of Experts Exchange, you are able to cast your vote on the quality of the solutions in regard to how complete, accurate, helpful and easy to understand each solution is. When you provide your feedback, each rating is adjusted accordingly. So, if you see a solution that has a poor rating that you think is a good solution, let us know by rating it. As you do, the rating will be adjusted and will become more accurate for other members of our site.

If you have any suggestions that you would like to make for our rating system, please ask a question in the Suggestions Zone of Community Support.

Thank you!

6.6

COLDFUSION  - Syntax error in INSERT INTO statement

Asked by jameskane in Web Development, Microsoft Access Database, ColdFusion Application Server

Hi, just successfully completed a form and associated action page for a database - I am having a problem in getting the second one to work. The error reported is "Syntax error in INSERT INTO statement". I have chedked this out for half a day now and its driving me crazy !! The code in this new action page is exactly the same as the previous one which worked !

Would someone just run their eye over the attached action_form_activities.cfm page and tell me tell me the stupid mistake I am making. I am am also including the error message from Coldfusion.

Please excuse asking for such basic help - but I'm desperate !!

james
1:
2:
3:
4:
5:
6:
7:
8:
9:
10:
11:
12:
13:
14:
15:
16:
17:
18:
19:
20:
21:
22:
23:
24:
25:
26:
27:
28:
29:
30:
31:
32:
33:
34:
35:
36:
37:
38:
39:
40:
41:
42:
43:
44:
45:
46:
47:
48:
49:
50:
51:
52:
53:
54:
55:
56:
57:
58:
59:
60:
61:
62:
63:
64:
65:
66:
67:
68:
69:
70:
71:
72:
73:
74:
75:
76:
77:
78:
79:
80:
81:
82:
83:
84:
85:
86:
87:
88:
89:
90:
91:
92:
93:
94:
95:
96:
97:
98:
99:
100:
101:
PAGE
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
hello this is me
 
<!-- <cfset CurrentPage=GetFileFromPath(GetTemplatePath())> -->
<!--- <cfif IsDefined("FORM.MM_InsertRecord") AND FORM.MM_InsertRecord EQ "activities"> --->
  <cfquery datasource="office">
  INSERT INTO activities (courseNumber, activity, teacher, day, hour, tariffs12, tariffs36, notes) VALUES ( 
  
  '#courseNumber#', 
  '#activity#',
  '#teacher#',
  '#day#', 
  '#hour#',
  '#tariffs12#',
  '#tariffs36#',
  '#notes#'
  
 
  
   )
  
  </cfquery>
 
  
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
<title>Untitled Document</title>
Your courses have been updated
</head>
 
<body>
</body>
</html>
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
ERROR MESSAGE
 
 Error Executing Database Query.
Syntax error in INSERT INTO statement.
 
The error occurred in C:\CFusionMX7\wwwroot\CFIDE\Office\action_form_activities.cfm: line 17
 
15 :   '#tariffs12#',
16 :   '#tariffs36#',
17 :   '#notes#'
18 :   
19 :  
 
SQL 	   INSERT INTO activities (courseNumber, activity, teacher, day, hour, tariffs12, tariffs36, notes) VALUES ( '1', 'Drawing and Painting', 'Jean Claude Delpech', 'mercredi', '09h30 - 12h30', '117', '234', 'QSDF QD FQ' )
DATASOURCE 	  office
VENDORERRORCODE 	  3092
SQLSTATE 	  &nbsp;
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/5.0 (Windows; U; Windows NT 5.1; en-GB; rv:1.9.0.4) Gecko/2008102920 Firefox/3.0.4
Remote Address   	127.0.0.1
Referrer   	http://localhost:8500/cfide/office/form_activities.cfm
Date/Time   	21-Nov-08 09:01 AM
Stack Trace
at cfaction_form_activities2ecfm87390207.runPage(C:\CFusionMX7\wwwroot\CFIDE\Office\action_form_activities.cfm:17) at cfaction_form_activities2ecfm87390207.runPage(C:\CFusionMX7\wwwroot\CFIDE\Office\action_form_activities.cfm:17)
 
com.inzoom.adojni.ComException: Syntax error in INSERT INTO statement. in Microsoft JET Database Engine code=3092 Type=1
	at com.inzoom.ado.Command.jniExecute(Native Method)
	at com.inzoom.ado.Command.execute(Command.java:40)
	at com.inzoom.jdbcado.Statement.exec(Statement.java:34)
	at com.inzoom.jdbcado.Statement.execute(Statement.java:107)
	at coldfusion.server.j2ee.sql.JRunStatement.execute(JRunStatement.java:212)
	at coldfusion.sql.Executive.executeQuery(Executive.java:719)
	at coldfusion.sql.Executive.executeQuery(Executive.java:652)
	at coldfusion.sql.Executive.executeQuery(Executive.java:613)
	at coldfusion.sql.SqlImpl.execute(SqlImpl.java:236)
	at coldfusion.tagext.sql.QueryTag.doEndTag(QueryTag.java:499)
	at cfaction_form_activities2ecfm87390207.runPage(C:\CFusionMX7\wwwroot\CFIDE\Office\action_form_activities.cfm:17)
	at coldfusion.runtime.CfJspPage.invoke(CfJspPage.java:152)
	at coldfusion.tagext.lang.IncludeTag.doStartTag(IncludeTag.java:349)
	at coldfusion.filter.CfincludeFilter.invoke(CfincludeFilter.java:65)
	at coldfusion.filter.ApplicationFilter.invoke(ApplicationFilter.java:210)
	at coldfusion.filter.RequestMonitorFilter.invoke(RequestMonitorFilter.java:51)
	at coldfusion.filter.PathFilter.invoke(PathFilter.java:86)
	at coldfusion.filter.LicenseFilter.invoke(LicenseFilter.java:27)
	at coldfusion.filter.ExceptionFilter.invoke(ExceptionFilter.java:69)
	at coldfusion.filter.ClientScopePersistenceFilter.invoke(ClientScopePersistenceFilter.java:28)
	at coldfusion.filter.BrowserFilter.invoke(BrowserFilter.java:38)
	at coldfusion.filter.GlobalsFilter.invoke(GlobalsFilter.java:38)
	at coldfusion.filter.DatasourceFilter.invoke(DatasourceFilter.java:22)
	at coldfusion.filter.RequestThrottleFilter.invoke(RequestThrottleFilter.java:115)
	at coldfusion.CfmServlet.service(CfmServlet.java:107)
	at coldfusion.bootstrap.BootstrapServlet.service(BootstrapServlet.java:78)
	at jrun.servlet.ServletInvoker.invoke(ServletInvoker.java:91)
	at jrun.servlet.JRunInvokerChain.invokeNext(JRunInvokerChain.java:42)
	at jrun.servlet.JRunRequestDispatcher.invoke(JRunRequestDispatcher.java:257)
	at jrun.servlet.ServletEngineService.dispatch(ServletEngineService.java:541)
	at jrun.servlet.http.WebService.invokeRunnable(WebService.java:172)
	at jrunx.scheduler.ThreadPool$DownstreamMetrics.invokeRunnable(ThreadPool.java:318)
	at jrunx.scheduler.ThreadPool$ThreadThrottle.invokeRunnable(ThreadPool.java:426)
	at jrunx.scheduler.ThreadPool$UpstreamMetrics.invokeRunnable(ThreadPool.java:264)
	at jrunx.scheduler.WorkerThread.run(WorkerThread.java:66)
[+][-]11/21/08 12:33 AM, ID: 23011207Expert Comment

At Experts Exchange, members can ask their questions to thousands of technology professionals, also known as Experts. Experts compete and collaborate to answer those questions by leaving comments like this one.

Start your 30-day free trial to view this Expert Comment or ask the Experts your question.

 
[+][-]11/21/08 12:47 AM, ID: 23011240Author Comment

Often, when Experts are collaborating with members who have asked questions, they will request additional information about the problem. Askers respond with an author comment like this one.

Start your 30-day free trial to view this Author Comment or ask the Experts your question.

 
[+][-]11/21/08 12:47 AM, ID: 23011241Expert Comment

At Experts Exchange, members can ask their questions to thousands of technology professionals, also known as Experts. Experts compete and collaborate to answer those questions by leaving comments like this one.

Start your 30-day free trial to view this Expert Comment or ask the Experts your question.

 
[+][-]11/21/08 01:24 AM, ID: 23011377Author Comment

Often, when Experts are collaborating with members who have asked questions, they will request additional information about the problem. Askers respond with an author comment like this one.

Start your 30-day free trial to view this Author Comment or ask the Experts your question.

 
[+][-]11/21/08 01:29 AM, ID: 23011401Expert Comment

At Experts Exchange, members can ask their questions to thousands of technology professionals, also known as Experts. Experts compete and collaborate to answer those questions by leaving comments like this one.

Start your 30-day free trial to view this Expert Comment or ask the Experts your question.

 
[+][-]11/21/08 01:32 AM, ID: 23011413Author Comment

Often, when Experts are collaborating with members who have asked questions, they will request additional information about the problem. Askers respond with an author comment like this one.

Start your 30-day free trial to view this Author Comment or ask the Experts your question.

 
[+][-]11/21/08 06:04 AM, ID: 23012848Expert Comment

At Experts Exchange, members can ask their questions to thousands of technology professionals, also known as Experts. Experts compete and collaborate to answer those questions by leaving comments like this one.

Start your 30-day free trial to view this Expert Comment or ask the Experts your question.

 
[+][-]11/21/08 07:13 AM, ID: 23013557Accepted Solution

View this solution now by starting your 30-day free trial. Setting up your free trial is quick, easy, and secure. We will return you to this solution, unlocked, when you're done.

About this solution

Zones: Web Development, Microsoft Access Database, ColdFusion Application Server
Sign Up Now!
Solution Provided By: jameskane
Participating Experts: 4
Solution Grade: A
 
[+][-]11/21/08 12:18 PM, ID: 23016597Expert Comment

At Experts Exchange, members can ask their questions to thousands of technology professionals, also known as Experts. Experts compete and collaborate to answer those questions by leaving comments like this one.

Start your 30-day free trial to view this Expert Comment or ask the Experts your question.

 
[+][-]11/21/08 02:22 PM, ID: 23017688Author Comment

Often, when Experts are collaborating with members who have asked questions, they will request additional information about the problem. Askers respond with an author comment like this one.

Start your 30-day free trial to view this Author Comment or ask the Experts your question.

 
[+][-]01/01/09 03:14 PM, ID: 23276748Administrative Comment

Experts Exchange has a courteous staff of administrators who help members get the most out of the website by means of administrative comments like this one.

Start your 30-day free trial to view this Administrative Comment or ask the Experts your question.

 
 
Loading Advertisement...
20091021-EE-VQP-81 - Hierarchy / EE_QW_3_20080625