0

My_Table (Contains Columns A & B). I need to Check Column A and if it does not equal a designated fixed value Add a new record using the designated fixed Value for Column A and existing Column B Value for Column B.

Is there way to combine VALUES & SELECT into a INSERT Statement? Temp Table? How do I do this?

Thanks

1
  • What language is this for? SQL? Commented Oct 12, 2011 at 3:19

1 Answer 1

1

Your question's a bit unclear, but I think this should do it

INSERT INTO My_Table (A, B) (SELECT "DESIGNATED_VALUE", B FROM My_Table WHERE A <> "DESIGNATED_VALUE") 
Sign up to request clarification or add additional context in comments.

Comments

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.