|
-
Oct 5th, 2005, 01:01 PM
#1
Thread Starter
Lively Member
SQL copy data from column
hello there,
how is it possible that i can copy data from an entire column (A) into another column (B), within the same table.
i am doing this because i have difficulties in renaming columns.
thank you very much.
note: MS Access 03 VBA
Astro.
-
Oct 5th, 2005, 01:53 PM
#2
Re: SQL copy data from column
With SQL?
Two calls..
VB Code:
CurrentDb.Execute "ALTER TABLE tablename ADD COLUMN NewField type NULL"
CurrentDb.Execute "UPDATE tablename SET NewField=OldField"
Where type in the first SQL represents the field type that you are creating...
For more info try ALTER TABLE - SQL Command
Although this relates more to SQL Server it is possible to do this as a Hidden SQL option on Access
Danny
Never Think Impossible
If you find my answer helpful then please add to my reputation
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules
|
Click Here to Expand Forum to Full Width
|