I
iain
Does anyone know if it is possible to add two values together within an SQL
statement so that the total is inserted into the field in the table?
For example a counter in a For/Next Loop to a variable called Index.
Private Sub FileCount(Name as string, Index as long, Quantity as Integer)
Dim mySQL as String
Dim n as Integer
For n=0 to Quantity - 1
mySQL = "INSERT INTO myTable VALUES(Name, Index + n)"
Next n
End Sub
statement so that the total is inserted into the field in the table?
For example a counter in a For/Next Loop to a variable called Index.
Private Sub FileCount(Name as string, Index as long, Quantity as Integer)
Dim mySQL as String
Dim n as Integer
For n=0 to Quantity - 1
mySQL = "INSERT INTO myTable VALUES(Name, Index + n)"
Next n
End Sub