Quantcast
Channel: Adobe Community : All Content - ColdFusion
Viewing all articles
Browse latest Browse all 5979

I've an SQL Statement Which works in Access, but not in Coldfusion

$
0
0

I've an SQL Statement Which works in MS Access 2010, but not in Coldfusion 7.  It's a way to achieve a display of most recent prices for my services, from a table of prices, which includethe date of each new price for each service; there are many services.  I have 2 tables.  the first table lists the services, one record for each service.  The 2nd table lists multiple instances of many of the services from the first table, each instance being a new price.  I do this to keep track of my price history.  The webpage throws an error, stating that: A CFML variable name cannot end with a "." character. SELECT SH1.rpr_srvc_hst_dt, rpr_srvcs.[rpr_srvc], SH1.[rpr_srvc_hst_amt_] FROM rpr_srvc_hst AS SH1 INNER JOIN rpr_srvcs ON SH1.[rpr_srvc_hst_srvc_] = rpr_srvcs.[rpr_srvcID] WHERE (((SH1.[rpr_srvc_hst_dt])=(SELECT MAX(rpr_srvc_hst_dt)     FROM rpr_srvc_hst AS SH2     WHERE SH2.[rpr_srvc_hst_srvc_] = SH1.[rpr_srvc_hst_srvc_]))); and the code on the page body:

#rpr_srvc##NumberFormat(SH1.[rpr_srvc_hst_amt_],'0.00')##DateFormat(SH1.rpr_srvc_hst_dt,'M/D/YY')#

Viewing all articles
Browse latest Browse all 5979

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>