G
Guest
I have copied VB function code from the internet. I need the return value of
this function to be part of the SELECT statement in a SQL statement. But,
I'm not sure about the proper syntax. That is my question. For those of you
familiar with SOUNDEX that's what the function is called. This is what I
need my SQL statement to look like:
strSQL = "INSERT INTO [Number] ( Occupation ) " & _
"SELECT Table1.occupation " & _ '<----- here is where I need "SOUNDEX(
occupation )"
"FROM Table1 " & _
"GROUP BY Table1.occupation; "
CurrentDb.Execute strSQL, dbFailOnError
So, do I put the call for the function inside the double-quotes? Do I tack
it onto the end with an "&" after the "SELECT Table1.occupation "? Help is
greatly appreciated!
this function to be part of the SELECT statement in a SQL statement. But,
I'm not sure about the proper syntax. That is my question. For those of you
familiar with SOUNDEX that's what the function is called. This is what I
need my SQL statement to look like:
strSQL = "INSERT INTO [Number] ( Occupation ) " & _
"SELECT Table1.occupation " & _ '<----- here is where I need "SOUNDEX(
occupation )"
"FROM Table1 " & _
"GROUP BY Table1.occupation; "
CurrentDb.Execute strSQL, dbFailOnError
So, do I put the call for the function inside the double-quotes? Do I tack
it onto the end with an "&" after the "SELECT Table1.occupation "? Help is
greatly appreciated!