When creating a view in mysql, does the View name affect the data ?!?

Source: Internet
Author: User
This semester I just learned about the database. the Statement for creating a view for mysql is createviewsupply (sno, pno, qty) asselectspj. sno, spj. pno, spj. qtyfromspj, jwherej. jnospj. jnoandj. jname & #39; Sanjian & #39; in this way, the view is successfully created, but select * fromsupply; the query result is empty. If you change the view name from supply to another view name, such as san_jian, the query result is mysql view data database.

I just learned about the database this semester and asked about how to create a view for mysql.
Statement for creating a view:
Create view supply (sno, pno, qty) as select spj. sno, spj. pno, spj. qty from spj, j where j. jno = spj. jno and j. jname = 'sanj ';
In this way, the view is successfully created, but the query result is empty when select * from supply.
If you change the view name from supply to another view name such as san_jian, the query result is correct. Ask for advice. why?

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.