Advice on how to reuse old MS Access query in MySQL
Hi!
I'm reviving an application from nearly 20 years ago. In going through the CFML, I find that I created several queries within the Access database that I used at the time, and I used them, programatically, like tables.
I have little knowledge about stored procedures, but my guess is that if I used the old query to create a stored procedure in the MySQL database, I could access it through my CFML the same way I did previously. That is, treating it like a table within CFML queries. I'd like to use the following code (calling AllRecordsUnion) in my new site without modification:
<CFQUERY DATASOURCE="county" NAME="list_links_county">
SELECT Links.APPROVE, Links.TYPE_DESC, Links.MAIN_NBR, Links.BEFOR, Links.LINK, Links.LINK_DISPL, Links.AFTER, Links.DESCRIP, Links.MUSIC, Links.SLOW, Links.ADDED, Links.LINK_DISPL, AllRecordsUnion.CNTY_NAME, AllRecordsUnion.LINK_RECORD
FROM Links INNER JOIN AllRecordsUnion ON Links.RECORD = AllRecordsUnion.LINK_RECORD
ORDER BY AllRecordsUnion.CNTY_NAME, Links.LINK_DISPL;
</cfquery>
I would just try this right now, but I'm quite a ways from having an appliation that I could use to test it. The original was built in FuseBox, and I'm sorting through a redesign. At this point, I just want to get the database squared away.
Thanks!
John
