Railo 4.0.3.006 Error (database)
Message You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near 'AND G.gid=P.galleryid AND p.exclude = 0
and P.pid=V.pid' at line 3
SQL

SELECT P.*,g.*,V.field_value as galleryname, P.description as DE
FROM ws5c60h8k_ngg_pictures as P,ws5c60h8k_ngg_gallery as G, ws5c60h8k_nggcf_field_values as V
where P.pid = AND G.gid=P.galleryid AND p.exclude = 0
and P.pid=V.pid
DatabaseName MySQL
DatabaseVersion 5.1.39-community-log
DriverName MySQL-AB JDBC Driver
DriverVersion mysql-connector-java-5.0.8 ( Revision: ${svn.Revision} )
Datasource blog_seo
Stacktrace The Error Occurred in
D:\HostingSpaces\linxcorp\siennapacific.com\wwwroot\app\patch-gallery.cfm: line 64
62: SELECT P.*,g.*,V.field_value as galleryname, P.description as DE
63: FROM ws5c60h8k_ngg_pictures as P,ws5c60h8k_ngg_gallery as G, ws5c60h8k_nggcf_field_values as V
64: where P.pid = #arguments.pid# AND G.gid=P.galleryid AND p.exclude = 0
65: and P.pid=V.pid
66: </cfquery>

called fromD:\HostingSpaces\linxcorp\siennapacific.com\wwwroot\app\patch-gallery.cfm: line 8
Java Stacktrace You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near 'AND G.gid=P.galleryid AND p.exclude = 0
and P.pid=V.pid' at line 3
   at com.mysql.jdbc.SQLError.createSQLException(SQLError.java:936):936
   at com.mysql.jdbc.MysqlIO.checkErrorPacket(MysqlIO.java:2985):2985
   at com.mysql.jdbc.MysqlIO.sendCommand(MysqlIO.java:1631):1631
   at com.mysql.jdbc.MysqlIO.sqlQueryDirect(MysqlIO.java:1723):1723
   at com.mysql.jdbc.Connection.execSQL(Connection.java:3277):3277
   at com.mysql.jdbc.Connection.execSQL(Connection.java:3206):3206
   at com.mysql.jdbc.Statement.execute(Statement.java:727):727
   at railo.runtime.type.util.QueryUtil.execute(QueryUtil.java:204):204
   at railo.runtime.type.QueryImpl.<init>(QueryImpl.java:222):222
   at railo.runtime.tag.Query.executeDatasoure(Query.java:627):627
   at railo.runtime.tag.Query.doEndTag(Query.java:475):475
   at app.patch_gallery_cfm270$cf.udfCall(D:\HostingSpaces\linxcorp\siennapacific.com\wwwroot\app\patch-gallery.cfm:64):64
   at railo.runtime.type.UDFImpl.implementation(UDFImpl.java:103):103
   at railo.runtime.type.UDFImpl._call(UDFImpl.java:371):371
   at railo.runtime.type.UDFImpl.call(UDFImpl.java:284):284
   at railo.runtime.type.scope.UndefinedImpl.call(UndefinedImpl.java:775):775
   at railo.runtime.util.VariableUtilImpl.callFunctionWithoutNamedValues(VariableUtilImpl.java:723):723
   at railo.runtime.PageContextImpl.getFunction(PageContextImpl.java:1507):1507
   at app.patch_gallery_cfm270$cf.call(D:\HostingSpaces\linxcorp\siennapacific.com\wwwroot\app\patch-gallery.cfm:8):8
   at railo.runtime.PageContextImpl.doInclude(PageContextImpl.java:802):802
   at railo.runtime.PageContextImpl.doInclude(PageContextImpl.java:754):754
   at railo.runtime.listener.ClassicAppListener._onRequest(ClassicAppListener.java:36):36
   at railo.runtime.listener.MixedAppListener.onRequest(MixedAppListener.java:19):19
   at railo.runtime.PageContextImpl.execute(PageContextImpl.java:2256):2256
   at railo.runtime.PageContextImpl.execute(PageContextImpl.java:2223):2223
   at railo.runtime.engine.CFMLEngineImpl.serviceCFML(CFMLEngineImpl.java:315):315
   at railo.loader.servlet.CFMLServlet.service(CFMLServlet.java:29):29
   at javax.servlet.http.HttpServlet.service(HttpServlet.java:728):728
   at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:305):305
   at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:210):210
   at org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:222):222
   at org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:123):123
   at org.apache.catalina.authenticator.AuthenticatorBase.invoke(AuthenticatorBase.java:472):472
   at org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:171):171
   at org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:99):99
   at org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:118):118
   at org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:407):407
   at org.apache.coyote.ajp.AjpProcessor.process(AjpProcessor.java:200):200
   at org.apache.coyote.AbstractProtocol$AbstractConnectionHandler.process(AbstractProtocol.java:589):589
   at org.apache.tomcat.util.net.JIoEndpoint$SocketProcessor.run(JIoEndpoint.java:310):310
   at java.util.concurrent.ThreadPoolExecutor.runWorker(Unknown Source):-1
   at java.util.concurrent.ThreadPoolExecutor$Worker.run(Unknown Source):-1
   at java.lang.Thread.run(Unknown Source):-1