This is not about the syntax in writing sql, rather the coding techniques.

In a typical sql statement column names and table names are required. Two possible way to write the statement would be by hardcoding the names in the statement text or by using constanst....

Code:
SELECT thisColumn, thatColumn FROM myTable WHERE anotherColumn = something
OR

Code:
Const THIS_COLUMN = "thisColumn"
Const THAT_COLUMN = "thatColumn"
Const MY_TABLE = "myTable"
Const ANOTHER_COLUMN = "anotherColumn"
SelectStatement = string.format("SELECT {0}, {1} FROM {2} WHERE {3} = something",THIS_COLUMN, THAT_COLUMN, MY_TABLE, ANOTHER_COLUMN)
I'm fairly very young when it comes to database programming, and am curious about how YOU handle specifying the names in the sql statements. I don't see that either method is not correct, but one way (or another) may have its benefits. What say you?

Again, this is not a post about how something gets done, or how to do something, I'm just curious about popular methods is all.
thanks

kevin