Results 1 to 2 of 2

Thread: update entry

  1. #1
    Join Date
    Oct 2003
    Posts
    4

    Unanswered: update entry

    Hi,
    I have performed nested query to find out the ssn of a lawyer.

    SELECT ...
    FROM...
    WHERE
    ( SELECT ...
    ...
    ...
    );

    And then I want to update the lawyer table by this ssn that I just got from the query. So i type

    Update Lawyers
    SET ssn = L.ssn
    WHERE ssn = L2.ssn;

    L, L2 are defined in the nested queries

    but I can't make this compile?

    Can anyone tell me what's wrong?
    (I don't exactly know generally how you update the entries in a table after performing queries, I am new to sql)

    Thank you

    Edmund

  2. #2
    Join Date
    Oct 2003
    Posts
    17
    write the entire query...

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •