Updating multiple rows in sql

you really ought to help make it easier for poeple to try to help you.

There are other issues but, I got confused with the table names.

in the above table i want to update all rows fields in emloyee_name in Single Statement using this update Employee Job Details set employee_name='anil jangam' where(Employee Job Details.eid=12313), set employee_name='Rama Krishna' where(Employee Job Details.eid=12314), set employee_name='anil jangam' where(Employee Job Details.eid=12313), set employee_name='anil jangam' where(Employee Job Details.eid=12313) This site functions according to votes.

For all helpful answers below, show this by clicking on the thumbs up next to those answers.

The problem I find with that structure is there are at the same time an variable number of questions and an variable number of answers plus multiple answers for a single individual that need to be recorded. Unfortunately, I was tasked to present the survey in the format shown in the screenshot below, which is why I chose to design the table structures the way I did.

r397 recommended to have the three rows in a normalized table, in first normal form. Now if there was a Member #1 Responses - Question #1: yes, 22, no, 34 - Question #2: no, 24, yes, 42 - Question #3: yes, 14, no, 42 Member #2 Responses - Question #1: no, 42, no, 55 - Question #2: no, 51, yes, 21 - Question #3: yes, 11, no, 14 etc., I see your concern and how you may recommend having only one answer for one question, which makes it so much easier to update SQL and PHP wise!

You would need a separate UPDATE statement for each.

But, what you can do is pass in all the values you want to update as a table valued parameter. FROM statement that will enable you to update all the values based on the listing of values within the parameter.

If you are an application programmer then you will more than likely need to write TSQL code to update your SQL Server database tables.

In order to update a row in a SQL Server table you will use the UDPATE statement.

Leave a Reply

  1. Meet girls no signup sex cam 14-Apr-2017 18:35

    Aspiring members have to pass a 48-hour peer vote to be accepted as one of the ‘beautiful people’.

  2. How do i get 1to1 sex cams 15-Apr-2017 23:46

    If some SIP messages appear to be retransmitted too often, adjust these parameters.

  3. korean actress eugene dating 05-Aug-2017 02:46

    because she is not and usually has bad breath, I wouldn't her anymore if she shared the inheritance so far she is doing well with it and ps: youy old enough to do for yourself.