How to Use a Variable in an SQL String in the Base Form's Data Tab [closed]
I have a Base form where the "content type = sql command" under the data tab. The code below uses the global variable intStoryNUM. However, it does not work. Can a variable be used? If so, how would the code below get corrected. (Note: Base is the front-end, MySQL is the back-end.)
SELECT "tblLinkedList"."LinkStoryNUM", "tblLinkedList"."LinkAuthorNUM", "tblAuthorList"."AuthorIDNUM", "tblAuthorList"."AuthorLast" FROM "TEST_sfmags"."tblLinkedList" "tblLinkedList", "TEST_sfmags"."tblAuthorList" "tblAuthorList" WHERE "tblLinkedList"."LinkAuthorNUM" = "tblAuthorList"."AuthorIDNUM" AND "tblLinkedList"."LinkStoryNUM" = '" + intStoryNUM + "'