TechRangerBrad Posted April 2, 2009 Posted April 2, 2009 Hey, Not sure if this is the right forum or not, but I was curious if anyone has put together a "dynamic" SQL statement using a global. In other words something like, SELECT * FROM teachers WHERE teacherid=^(gAccountID) I know my syntax is not correct, but I am too lazy to get to open the DB to find the correct syntax. Thanks for any help. B
LaRetta Posted April 2, 2009 Posted April 2, 2009 (edited) if anyone has put together a "dynamic" SQL statement using a global. Yes. You need to create a calculation using the global within the SQL statement. You will need to wrap the entire thing in quotes and also remember to escape out any quotes inside it that are required. So it would look something like: "SELECT * FROM "TEACHERS" WHERE TEACHERID = " & gAccountID Then map your query manually in your script-step using this language (without the quotes and insert a manual number instead of gAccountID). After it is mapped, change your import to point to the calculation instead. Edited April 2, 2009 by Guest
Recommended Posts
This topic is 5714 days old. Please don't post here. Open a new topic instead.
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now