hi hemant
i got the sum of the column but not getting STDDEV and VARIANCE function result.it gives error on the function STDDEV. here is my code
=============== =============== =============== =========
Option Explicit
Dim cnn As ADODB.Connectio n
Dim rst As ADODB.Recordset
Dim strCnn As String
Dim lngCount As Long
Dim strID As String
Dim sSQL As String
Dim booRecordAdded As Boolean
Private Sub Form_Load()
' Open a connection.
Set cnn = New ADODB.Connectio n
strCnn = "Provider=Micro soft.Jet.OLEDB. 4.0;Data source=D:\AA\A. mdb;Persist Security Info=False"
cnn.Open strCnn
Set rst = New ADODB.Recordset
rst.CursorType = adOpenKeyset
rst.LockType = adLockOptimisti c
sSQL = "select STDDEV(WindSpee d) as lngCount from Weather "
rst.Open sSQL, cnn
Text1.Text = rst.Fields!lngC ount
End Sub
i got the sum of the column but not getting STDDEV and VARIANCE function result.it gives error on the function STDDEV. here is my code
=============== =============== =============== =========
Option Explicit
Dim cnn As ADODB.Connectio n
Dim rst As ADODB.Recordset
Dim strCnn As String
Dim lngCount As Long
Dim strID As String
Dim sSQL As String
Dim booRecordAdded As Boolean
Private Sub Form_Load()
' Open a connection.
Set cnn = New ADODB.Connectio n
strCnn = "Provider=Micro soft.Jet.OLEDB. 4.0;Data source=D:\AA\A. mdb;Persist Security Info=False"
cnn.Open strCnn
Set rst = New ADODB.Recordset
rst.CursorType = adOpenKeyset
rst.LockType = adLockOptimisti c
sSQL = "select STDDEV(WindSpee d) as lngCount from Weather "
rst.Open sSQL, cnn
Text1.Text = rst.Fields!lngC ount
End Sub
Comment