Tuesday, February 17, 2009

MYSQL Interview Questions

How can swap same feilds data using Mysql ?
Table Name Color

ID | Color

1 Black
2 Whilte
3 Whilte
4 Black

We can swap feilds data using following query.

update `test` as i , test as c set i.color='black',c.color = 'white' where i.color='white' and c.color='black'

What is MYSQL ?
MySQL is an open source relational database management system (RDBMS) which uses Structured Query Language (SQL). MYSQL is the most popular language that is available for both Linux and Windows operating system.

No comments:

Post a Comment