Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations gkittelson on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Replace values - simple question 1

Status
Not open for further replies.

bergis

Technical User
Jun 21, 2001
42
GB
Hi, If I change values in a column in a query with selected records, will the values in the table also change for these records(and yes, I want it to)
tia
regards
Kjell
 
yes. why don't you try it.

there may be an instance where the query is based on two or more tables where you cannot update, ie the query is read-only
 
Sorry, the answer is NO! :-(

A SELECT query selects records. An UPDATE query will be required to change or update the data. You can update multiple columns and multiple rows in one query. You can do conversions, arithmetic operations, and other manipulations in the update query.

UPDATE tbl SET col1=99, col2="abc", col3=col3+5, col4=date()
WHERE colA=22 Terry

"I shall try to correct errors when shown to be errors, and I shall adopt new views so fast as they shall appear to be true views." - Abraham Lincoln
 
Well I'm sorry too tlbroadbent, but if you create a SELECT query in Microsoft access, then there is an instance where
you can modify the underlying data.

Query
------
SELECT Field1, Field2, Field3 FROM Table1

open the datasheet view of the query and modify it!

what about forms? What happens when you set the control source of a form to be a SELECT query?

Can you add records to the underlying table?
I think so.

|-I
 
muchos gracias tlbroadbent.

Reflecting, I see that the dates are the same, and that possibly you were saying no to the original question, and not my answer.

paul.
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top