Hi
i'm trying to connect to a table valued function on sql (2005) but keep getting the following error:
argument are of the wrong type, are out of acceptable range, or in conflict with one another
here's the code
is there another way i should be doing this?
Thanks
i'm trying to connect to a table valued function on sql (2005) but keep getting the following error:
argument are of the wrong type, are out of acceptable range, or in conflict with one another
here's the code
Code:
Dim cnn As ADODB.Connection
Dim rst As ADODB.Recordset
Set cnn = New ADODB.Connection
cnn.ConnectionString = "DSN=mydsn;UID=myuser;PWD=mypw;"
cnn.Open
Dim myValue As String
myValue = "123456"
rst.Open "select * from [dbo].[tvf_ASN_bodyShop_header] ('" & myValue & "')", cnn.Connection, adOpenKeyset, adLockReadOnly
is there another way i should be doing this?
Thanks