General discussion


MS Access

By ashishab ·
I would like to updete fields in existing Access table. I would like to add fields in that table

This conversation is currently closed to new comments.

Thread display: Collapse - | Expand +

All Comments

Collapse -


by Tony Hopkinson In reply to MS Access

Update as in change the data, from access, open the table and type,

From SQl
Update MyTable Set MyField1 = 'Value',MyField2 = 123.8 Where MyKey = 1

To change the structure of a table
From access, pick the the table and select design,

from SQL

Alter table MyTable
add MyNewColumn int not null

Suggest you run thru a couple of tutorials mate, wanting to do this and not knowing how, suggests you need to reverse things a little.

For instance before you restructure your tables you might want to back them up.

Collapse -

basic code

by ashishab In reply to Hmm

Is there away using access basic check if the field exist and if not then add to the table. I know how to add from gesign mode


Collapse -

I guess...

by onbliss In reply to basic code are talking about adding a field programmatically, right?

If yes, you would be using ADO/ADOX to do it. Before adding just check if the column exists. Here is a link that might start you:

Note it is ASP code, you should be able to get an idea on how to it in Access using VBA.

Collapse -

post a question to technical q & a

by Tony Hopkinson In reply to basic code

how to check for and add fields programatically in vba with access. Not something I know off the top of my head as I try to steer clear of both.
Google it, you'll probably get several answers as well.

Related Discussions

Related Forums