How to change each row of data

Source: Internet
Author: User
How to change each row of data? At last, this post was edited by b234387 from 2013-02-1921: 02: 02. how can I modify each row of data? Can you teach me how to directly change the SQL & nbsp; on the webpage or use PHP to change it? MySQL table tabA sequence & nbsp; class & nbsp; quota _ restrictions & nbsp; quota _ usage & nbsp; & nbsp; & how to change each row of data?

This post was last edited by b234387 at 21:02:02



How to change each row of data?


Can you teach me how to directly modify the SQL statement on the webpage or use PHP to change it?


MySQL table

TabA
Ordinal round _ restricted round _ used round _ remaining round _ level
1 A 5 3 2 2
2 B 5 1 4 2
3 C 5 2 3 1


1st cases: change "all" limits of "level" = 2 "to 10, and modify" remaining ".

2nd cases: limit all "levels" = 2 "+ 4. change" remaining ".

3rd cases: all "remaining" must be correct. Update "left" = "limit"-"use" for each row ".


======================

TabB
A B
"1"-> ""
"2"-> "W"


How can I copy all the "A" columns to the "B" column?









------ Solution --------------------
The first one did not understand
The second one can be written as follows:
Update tabB set B =;

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.