Question

Which generates the most rows in MySQL? • SELECT 1 UNION SELECT 1 UNION SELECT 2;...

Which generates the most rows in MySQL?

• SELECT 1 UNION SELECT 1 UNION SELECT 2;

• SELECT 1 UNION SELECT 1 UNION SELECT 1;

• SELECT 1 UNION ALL SELECT 1 UNION ALL SELECT 1;

• SELECT 1 UNION ALL SELECT 2 UNION SELECT 2;

0 0
Add a comment Improve this question Transcribed image text
Answer #1

SELECT 1 UNION SELECT 1 UNION SELECT 2; ---- returns 2 rows

SELECT 1 UNION SELECT 1 UNION SELECT 1; ---- returns 1 row

SELECT 1 UNION ALL SELECT 1 UNION ALL SELECT 1; ------ returns 3 rows

SELECT 1 UNION ALL SELECT 2 UNION SELECT 2; ---- return 2 rows

Answer : C

SELECT 1 UNION ALL SELECT 1 UNION ALL SELECT 1;

this my sql will returns 3 rows

Add a comment
Know the answer?
Add Answer to:
Which generates the most rows in MySQL? • SELECT 1 UNION SELECT 1 UNION SELECT 2;...
Your Answer:

Post as a guest

Your Name:

What's your source?

Earn Coins

Coins can be redeemed for fabulous gifts.

Not the answer you're looking for? Ask your own homework help question. Our experts will answer your question WITHIN MINUTES for Free.
Similar Homework Help Questions
  • Using the bank database, which generates an error in MySQL? • SELECT emp_id FROM employee UNION...

    Using the bank database, which generates an error in MySQL? • SELECT emp_id FROM employee UNION SELECT open_emp_id FROM account ORDER BY open_emp_id; • SELECT emp_id FROM employee UNION SELECT open_emp_id FROM account ORDER BY emp_id; • SELECT emp_id emp FROM employee UNION SELECT open_emp_id FROM account ORDER BY emp; • SELECT emp_id open_emp_id FROM employee UNION SELECT open_emp_id FROM account ORDER BY open_emp_id;

  • MYSQL Consider the sql statement "select * from t1 UNION t2" where t1 and t2 are...

    MYSQL Consider the sql statement "select * from t1 UNION t2" where t1 and t2 are two sets (tables). This query executes without any errors. Assume t1 has n columns. How many columns does t2 have? How many columns will the resultset have? Is it possible for the result set to have more records than the combination of t1 and t2 (for example say t1 has 8 records and t2 has 8 records) is it possible for the resultset to...

  • MySQL problem. Show MySQL queries to solve these problems. DO NOT USE JOIN keyword to solve...

    MySQL problem. Show MySQL queries to solve these problems. DO NOT USE JOIN keyword to solve this Question 1: Rows in A, but not in B Question 2: Rows in B, but not in A Question 3: Rows in A and B, no overlap Question 4: Rows in A and B (Full Join) REMINDER: DO NOT USE JOIN KEYWORD

  • e mysql> Select from Orders; | Order ID | Order_Date | Customer_ID | Shipping_Date I -----...

    e mysql> Select from Orders; | Order ID | Order_Date | Customer_ID | Shipping_Date I ----- --- -- --- | 12489 | 12491 | 12494 | 12495 | 12498 | 12500 | 12504 | 02-JUL-11 | 02-JUL-11 I 04-JUL-11 I 04-JUL-11 | 05-JUL-11 | 05-JUL-11 | 05-JUL-11 | 124 311 315 256 522 | 124 | 522 | 22-JUL-11 | 22-JUL-11 | 12-JUL-11 | 22-AUG-11 | 22-AUG-11 7 rows in set (0.18 sec) mysql> Select * from Order_line; Order_ID |...

  • 1. Which company generates the most cash inflow from operating activities?

    1. Which company generates the most cash inflow from operating activities? 2. Which of these companies report "Net cash used in investing activities"? 3. Calculate the total net increase or decrease in cash for (a) Gadberry, (b) Nessly, and (c) Tootsey. 

  • 1. Write the php statements to connect to MySQL server and select the database named personnel....

    1. Write the php statements to connect to MySQL server and select the database named personnel. The database personnel is located at localhost server. The user id and password to log on to the server are finalexam and thePassword respectively. 2. Using the above connection, write the php statements to retrieve the name and the email fields from all records of the users table ( 'SELECT name, email FROM users') and display them one record per line.

  • Which SQL keywords are used to add, remove, and modify rows in a table? CREATE,DROP,ALTER INSERT,DELETE,UPDATE...

    Which SQL keywords are used to add, remove, and modify rows in a table? CREATE,DROP,ALTER INSERT,DELETE,UPDATE ADD,REMOVE,MODIFY INSERT,DELETE,ALTER ----------------------------------------------------------- In comparing strings in MySQL which character(s) can be used as a wildcard for any number of characters? * ? % _(underscore) -------------------------------------------------------- In comparing strings in MySQL which character(s) can be used as a wildcard for any single character? ?? % * _ (underscore) -------------------------------------- In MySQL which wildcard is used to substitute for any columns being displayed in a...

  • which below is Not part of the steps in using MySQL with php? create a cookie...

    which below is Not part of the steps in using MySQL with php? create a cookie retrieve the results and output them to a webpage build a query string connect to MySQL snd select the database to sur

  • Q1: Which of the following claims are true?* 1 point The recognizable languages are closed under union and intersection...

    Q1: Which of the following claims are true?* 1 point The recognizable languages are closed under union and intersection The decidable lanquages are closed under union and intersection The class of undecidable languages contains the class of recognizable anguages For every language A, at least one of A or A*c is recognizable Other: This is a required question Q2: Which of the following languages are recognizable? (Select all that apply) 1 point EDFA-{ «A> 1 A is a DFA and...

  • What are 2 ways I could insert rows to a table, using the SELECT statement.

    What are 2 ways I could insert rows to a table, using the SELECT statement.

ADVERTISEMENT
Free Homework Help App
Download From Google Play
Scan Your Homework
to Get Instant Free Answers
Need Online Homework Help?
Ask a Question
Get Answers For Free
Most questions answered within 3 hours.
ADVERTISEMENT
ADVERTISEMENT