Author Question: Explain how to combine queries using the UNION clause. What will be an ideal ... (Read 63 times)

geoffrey

  • Hero Member
  • *****
  • Posts: 880
Explain how to combine queries using the UNION clause.
 
  What will be an ideal response?

Question 2

Validation can protect against SQL injection attacks.
 
  Indicate whether the statement is true or false.


aburgess

  • Sr. Member
  • ****
  • Posts: 361
Answer to Question 1

The UNION clause is used to combine the output of multiple queries into one set of output. In order for the union to work, each query must return the same number of columns. Also, each output column must be union compatible, meaning it is of the same type. The CAST command can be used to convert from one datatype to another if need be. If you wish to order the output rows, you must specify an ORDER BY clause in the last query.

Answer to Question 2

Answer: TRUE



Related Topics

Need homework help now?

Ask unlimited questions for free

Ask a Question
 

Did you know?

IgA antibodies protect body surfaces exposed to outside foreign substances. IgG antibodies are found in all body fluids. IgM antibodies are the first type of antibody made in response to an infection. IgE antibody levels are often high in people with allergies. IgD antibodies are found in tissues lining the abdomen and chest.

Did you know?

People often find it difficult to accept the idea that bacteria can be beneficial and improve health. Lactic acid bacteria are good, and when eaten, these bacteria improve health and increase longevity. These bacteria included in foods such as yogurt.

Did you know?

During pregnancy, a woman is more likely to experience bleeding gums and nosebleeds caused by hormonal changes that increase blood flow to the mouth and nose.

Did you know?

More than 2,500 barbiturates have been synthesized. At the height of their popularity, about 50 were marketed for human use.

Did you know?

After 5 years of being diagnosed with rheumatoid arthritis, one every three patients will no longer be able to work.

For a complete list of videos, visit our video library