Home |
Search |
Today's Posts |
|
#1
![]()
Posted to microsoft.public.excel.programming
|
|||
|
|||
![]()
Hi All,
I am using UPDATE query from Excel to Access. I have 1000 rows with unique IDS ( same IDS in Access Database Table) I need to UPDATE for 1000 IDS status. Right now I am using like this. I want to know is there any better option to do this ?? For R = 4 To 1000 ID = Trim(Cells(R, "A").Value) STS = Trim(Cells(R, "F").Value) SQL = "UPDATE TRACKER SET TRACKER.STATUS = '" & STS & "'" SQL = SQL & " WHERE ID = '" & ID & "'" rs.Open SQL, db, adOpenDynamic, adLockOptimistic, adCmdText Next R |
#2
![]()
Posted to microsoft.public.excel.programming
|
|||
|
|||
![]()
You would be best to post this in:
comp.databeses.ms-access They are more atuned to Access related issues even though it is connected to Excel. HTH |
#3
![]()
Posted to microsoft.public.excel.programming
|
|||
|
|||
![]()
It depends on your set up and how your app works. But an option that
also have is: - in the Access create a linked table (linked to the excel) - create an update query that would update the other access table with the values from the linked table - the join would be the IDs that you mention. On Jan 13, 11:29*pm, "fi.or.jp.de" wrote: Hi All, I am using UPDATE query from Excel to Access. I have 1000 rows with unique IDS ( same IDS in Access Database Table) I need to UPDATE for 1000 IDS status. Right now I am using like this. I want to know is there any better option to do this ?? For R = 4 To 1000 ID = Trim(Cells(R, "A").Value) STS = Trim(Cells(R, "F").Value) SQL = "UPDATE TRACKER SET TRACKER.STATUS = '" & STS & "'" SQL = SQL & " WHERE ID = '" & ID & "'" rs.Open SQL, db, adOpenDynamic, adLockOptimistic, adCmdText Next R |
Reply |
Thread Tools | Search this Thread |
Display Modes | |
|
|
![]() |
||||
Thread | Forum | |||
UPDATE Query | Excel Worksheet Functions | |||
update DB via MS Query from WS | Excel Discussion (Misc queries) | |||
Update Query | New Users to Excel | |||
Update Web Query | Excel Discussion (Misc queries) | |||
After Query Update | Excel Programming |