Welcome to SPN

Register and Join the most happening forum of Sikh community & intellectuals from around the world.

Sign Up Now!
  1.   Become a Supporter    ::   Make a Contribution   
    Target (Recurring Monthly): $200 :: Achieved: $98

update query in access 2000

Discussion in 'Information Technology' started by Pat, Jul 28, 2006.

  1. Pat

    Pat
    Expand Collapse
    Guest

    how do I run and update query?
     
  2. Loading...

    Similar Threads Forum Date
    Self Update On The Gurdwara Blogs Apr 3, 2017
    Sikh News BREAKING: Young Sikh Shot Dead In Jalalabad, Afghanistan . - Sikh24 News & Updates Breaking News Oct 2, 2016
    update Blogs Oct 16, 2015
    Update Wikipedia enteries on Sikh Socio-Political Topics Breaking News Jul 19, 2015
    Pacific Oil slicks spotted in search for missing Malaysia Airlines plane (Live updates) Breaking News Mar 8, 2014

  3. Joseph Meehan

    Joseph Meehan
    Expand Collapse
    Guest

    Pat wrote:
    > how do I run and update query?


    Normally you click on the "!" button at the top of the page. How are
    you trying to run it?

    --
    Joseph Meehan

    Dia duit
     
  4. strive4peace

    strive4peace
    Expand Collapse
    Guest

    Re: update query in access 2000 -- UPDATE SQL, to make Update Query

    Hi Pat,

    here is how the SQL is structured for an update query:

    ~~~~~~~~~~~ UPDATE SQL ~~~~~~~~~~~
    An Update Query first identifies the tables that are used

    UPDATE table1 INNER JOIN table2 ON table1.keyfield =
    table2.keyfield

    Then identifies what to change

    SET table1.fieldtochange = expression

    Then, if you have criteria...

    WHERE table.strField = 'somevalue'
    AND table.numField = 99
    AND table.dateField = #1/1/06#

    '~~~~~~~~~~~~~~~~~~~~~~~~~~~~`

    if you want to use the query design view to make an update query, here
    is a simple example:

    ~~~~~~~~~~~ Update Query ~~~~~~~~~~~

    make a new query based on the table you want to change

    change the query type from a Select Query to an Update Query
    from the menu bar --> Query, Update

    for instance, lets say you are storing just the mailbox name and want to
    add to it so it is a fully qualified email address

    field --> EmailAddress
    UpdateTo --> TRIM([EmailAddress]) & "@anywhere.com"
    Criteria --> not like "*@*"

    then, RUN (!) your query

    & specifies that a literal string will be added to the end of all your
    email addresses that have no "@" in them

    TRIM will chop off leading and trailing spaces from your data

    not like "*@*"
    means that only fields not already containing the @ symbol will be replaced

    Don't forget to type the square brackets in the UpdateTo cell... Access
    likes to put quotes around undelimited fieldnames -- then ALL your email
    addresses would change to "EmailAddress@anywhere.com"

    naturally, back up your database before running any action queries on it


    '~~~~~~~~~~~~~~~~~~~

    Warm Regards,
    Crystal
    *
    :) have an awesome day :)
    *
    MVP Access



    Pat wrote:
    > how do I run and update query?
    >
    >
     
  5. Pat

    Pat
    Expand Collapse
    Guest

    figured it out thanks

    "Joseph Meehan" wrote:

    > Pat wrote:
    > > how do I run and update query?

    >
    > Normally you click on the "!" button at the top of the page. How are
    > you trying to run it?
    >
    > --
    > Joseph Meehan
    >
    > Dia duit
    >
    >
    >
     
Since you're here... we have a small favor to ask...

More people are visiting & reading SPN than ever but far fewer are paying to sustain it. Advertising revenues across the online media have fallen fast. So you can see why we need to ask for your help. Donating to SPN's is vote for free speech, for diversity of opinions, for the right of the people to stand up to religious bigotry. Without any affiliation to any organization, this constant struggle takes a lot of hard work to sustain as we entirely depend on the contributions of our esteemed writers/readers. We do it because we believe our perspective matters – because it might well be your perspective, too... Fund our efforts and together we can keep the world informed about the real Sikh Sikhi Sikhism. If everyone who writes or reads our content, who likes it, helps us to pay for it, our future would be much more secure. Every Contribution Matters, Contribute Generously!

    Become a Supporter      ::     Make a Contribution     



Share This Page