Multi select query (ADO) - Rookie!

  • Thread starter Thread starter Atlas
  • Start date Start date
A

Atlas

Is it possible to send multiple select statements in one batch to the
server?
Example:

fGRs.ActiveConnection = globalCn

strSQL = " SELECT SUM(A) AS sumA FROM
" & _
" SELECT SUM(B) AS sumB FROM
"


fGRs.Source = strSQL
fGRs.Open
txtBoxA = fGRs!sumA
txtBoxB = fGRs!sumB



Thanks
 
Is it possible to send multiple select statements
in one batch to the server?
Example:
fGRs.ActiveConnection = globalCn
strSQL = " SELECT SUM(A) AS sumA FROM
" & _
" SELECT SUM(B) AS sumB FROM
"
fGRs.Source = strSQL
fGRs.Open
txtBoxA = fGRs!sumA
txtBoxB = fGRs!sumB


SELECT SUM(A) as sumA, SUM(B) as sumB FROM

should do what you want -- there's no need for multiple SELECTs.

Larry Linson
Microsoft Access MVP
 
Back
Top