Home > Software engineering > [for] SQL statement appears at least one parameter is not specified value error
[for] SQL statement appears at least one parameter is not specified value error
Time:09-17
Purpose is through the ACCESS of data in a library to find the temperature of 340 physical parameters and output to the work table Sub for physical parameters () Dim CNN As New Connection, RST As you, FLD As Field Dim strSq1 As String, I, As Long As strConn String StrSq1="SELECT * FROM [CO278] WHERE [Temperature]='340'" StrConn="Provider=Microsoft. ACE. The OLEDB. 12.0. Data Source=C: \ Users \ DELL \ Documents \ CO2 MDB "CNN. The ConnectionString=strConn CNN. Open The Set RST=CNN. The Execute (strSq1) With Worksheets (" sheet1 ") I=1 For Each FLD In RST. Fields Cells (1, I)=FLD. Name Next J=1 EOF the Do While Not RST.I=1 J=j + 1 For Each FLD In RST. Fields Cells (j, I)=FLD. Value I=I + 1 Next RST. MoveNext Loop End With RST. Close CNN. Close The Set of RST=Nothing The Set of CNN=Nothing End Sub I don't know the problem there
CodePudding user response:
Are you on both sides of the asterisk lack of space?