sqlsql-server-2000query-help

Update Statements


I am a beginner SQL user (not formally trained; OJT only) and need some assistance with a simple update statement. I would like to write an update statement that allows me to list ID's. The statement shown below is how I am currently writing it. Ideally, the statement would allow me to write it like "where plantunitid in (49-57). Is there a way to do this? Thanks for any assistance provided.

update plantfunctiontable set decommissioned=1 where plantunitid in (49,50,51,52,53,54,55,56,57)


Solution

  • Can this work?

    update plantfunctiontable set decommissioned=1 where plantunitid  between 49 and 57