Public Function getLastSupplierBypID(StoreID As Integer, pID As Long) As Recordset
'根据StoreID和pID找商品最近入库的供应商
Dim rs As New ADODB.Recordset
rs.CursorLocation = adUseClient
Dim strSQL As String
strSQL = "select Top 1 f.SupplyID, s.SupplyName, d.FeedPrice " & _
"from form f, formdetail d, Supply s " & _
"Where f.fID = d.fID And f.SupplyID = s.SupplyID " & _
"and f.storeid =" & StoreID & " and f.formtypeid=3 and d.pid=" & pID & _
" order by f.UpdateDate DESC "
rs.Open strSQL, conn
Set getLastSupplierBypID = rs //这句表示什么?返回什么?内容是什么?End Function
'根据StoreID和pID找商品最近入库的供应商
Dim rs As New ADODB.Recordset
rs.CursorLocation = adUseClient
Dim strSQL As String
strSQL = "select Top 1 f.SupplyID, s.SupplyName, d.FeedPrice " & _
"from form f, formdetail d, Supply s " & _
"Where f.fID = d.fID And f.SupplyID = s.SupplyID " & _
"and f.storeid =" & StoreID & " and f.formtypeid=3 and d.pid=" & pID & _
" order by f.UpdateDate DESC "
rs.Open strSQL, conn
Set getLastSupplierBypID = rs //这句表示什么?返回什么?内容是什么?End Function
解决方案 »
- MSFlexGrid单元格背景为什么我设成0,它显示白色的呢?
- 任务管理器
- 程序要用VB导入Excel数据,当Excel文件无密码时可正常导入,但有密码保护时,应如何让用户自行输入密码再进行导入?
- 我在frame控件里面加了个Lable控件,可是看不见Lable控件上的字,怎么回事?急!!!在线等!!!
- 紧急求助!!!!!需要一个平面式的DTPicker!!!请高手们帮帮忙!!!
- 哪儿能找到VB的控件例子?
- 求一SQL语句
- vb 如何动态调用 object library
- 关于小数点的问题
- 用WINGATE做代理服务器,主机可以连上OICQ,客户机可以上网,无法连上OICQ?????????
- 谁给解释一下多线程是怎么回事,以及怎么实现?
- 在线等待,怪问题,急问题,小问题!!!
vb中说,对象赋值要用set来完成。