LinkBack Thread Tools Search this Thread Display Modes
Prev Previous Post   Next Post Next
  #1   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 43
Default Excel 2000 VBA recordset manipulation

Hi all!

I hope this one is pretty simple. I have created a recordset as defined by
the code below. How do I populate the appended field with the WeekNumber
function as indicated by the last line of the code?

Thanks in advance!

cheers,
Matt.
----------------
strSQL = "SELECT ProDate, SUM(ScrapQuantity) AS ScrapQuantity " _
& "FROM qryWeeklyStartupScrap " _
& "WHERE [Machine #] <= 14 " _
& "GROUP BY ProDate"

rsWeeklyScrap.CursorType = adOpenDynamic
rsWeeklyScrap.CursorLocation = adUseClient
rsWeeklyScrap.Source = strSQL
rsWeeklyScrap.ActiveConnection = connDB
rsWeeklyScrap.Open

rsWeeklyScrap.Fields.Append "WeekNum", adInteger

strSQL = "UPDATE rsWeeklyScrap SET WeekNum = WeekNumber(ProDate)"



 
Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules

Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On


Similar Threads
Thread Thread Starter Forum Replies Last Post
Excel Manipulation Baffled Excel Discussion (Misc queries) 16 July 30th 07 12:34 PM
Data Manipulation - Excel 2000 sandralong2 via OfficeKB.com Excel Discussion (Misc queries) 2 November 9th 06 10:30 PM
Excel Time Manipulation BFiedler Excel Discussion (Misc queries) 0 September 15th 05 01:15 AM
Recordset Opening Excel File Seth[_3_] Excel Programming 0 August 1st 03 01:52 PM
open range (within workbook) as ado recordset - excel vba S. Daum Excel Programming 0 July 25th 03 04:45 PM


All times are GMT +1. The time now is 08:11 AM.

Powered by vBulletin® Copyright ©2000 - 2024, Jelsoft Enterprises Ltd.
Copyright ©2004-2024 ExcelBanter.
The comments are property of their posters.
 

About Us

"It's about Microsoft Excel"