½Ð±Ð¦U¦ì¥ý¶i2Ó°ÝÃD
1.·í°õ¦æ¦¹µ{¦¡·|µo¥Í"°õ¦æ¶¥¬q¿ù»~'3704':·íª«¥óÃö³¬®É,¤£¤¹³\¾Þ§@",½Ð°Ýn¦p¦ó×¥¿
2.¨Ï¥ÎBlade(¼ÆÈ)°µ¿z¿ï,¥i¿z¿ï¥X·Qnªº¸ê®Æ,¦ý§ï¥Îentrydate(¤é´Á)¿z¿ï,µ{¦¡§ï¬°~FROM CFData where entrydate>2012/12/1,«oµLªk¿z¿ï¥X·Qnªº¸ê®Æ
½Ð°Ý¬O§_n¥t¥~«Å§i°Ñ¼Æ±ø¥ó
Sub aa()
Dim cnn As New ADODB.Connection
Dim rst As New ADODB.Recordset
cnn.Open "provider=Microsoft.jet.OLEDB.4.0;data source=" & ThisWorkbook.Path & "/Motion.mdb"
Sql = "SELECT entrydate,blade INTO [Excel 8.0;DATABASE=c:\test1.XLS].[main] FROM CFData where blade =1"
[a2].CopyFromRecordset cnn.Execute(Sql) -->·|µo¥Í°õ¦æ¶¥¬q¿ù»~'3704':·íª«¥óÃö³¬®É,¤£¤¹³\¾Þ§@ cnn.Close
cnn.Close
Set cnn = Nothing
End Sub
¨Ï¥ÎBlade=1¥i±NBlade¬°1ªº¸ê®Æ¿z¿ï¥X¨Ó