Scenario: A bank analyst queries transaction counts. SELECT…
Scenario: A bank analyst queries transaction counts. SELECT COUNT(*) FROM transactions WHERE ISNULL(status, ”) = ”; What should be done to improve portability? OPTIONSA. Replace the vendor-specific SQL (“ISNULL”)B. Add a vendor-specific optimizer hint.C. Delete the WHERE clause.D. Replace empty strings with NULL. ANSWERReplace ISNULL with COALESCE. EXPLANATIONCOALESCE is ANSI-standard and runs across multiple engines, unlike vendor-specific ISNULL.
Read DetailsScenario: A car rental analyst checks reservations by city….
Scenario: A car rental analyst checks reservations by city. SELECT reservation_id, city FROM reservations WHERE city = Chicago; What’s the fix? OPTIONSA. Put Chicago in single quotes.B. Replace city with uppercase.C. Use double quotes for Chicago.D. Move the condition to SELECT. ANSWERPut Chicago in single quotes. EXPLANATIONString literals must be single-quoted. The other changes don’t solve the issue.
Read DetailsYou are promised a lump sum payment of $`FV` exactly `n` ye…
You are promised a lump sum payment of $`FV` exactly `n` years from now. The annual nominal interest rate is `i`%, compounded semi-annually (twice per year). What is the amount you would need to invest today to have this same future value? **Remember, because the compounding is semi-annual, both the interest rate per period and the total number of periods must be adjusted accordingly. Enter your answer with 2 decimal places and NO special characters. Do not submit a negative value; submit your answer as a positive value.
Read DetailsMaria wants to establish a community arts grant that awards…
Maria wants to establish a community arts grant that awards $`A`,000 every year to a local artist indefinitely, with the first grant to be given out exactly one year from now. If the community foundation can invest Maria’s donation at an annual interest rate of `i`%, how much does Maria need to contribute today to permanently support the yearly arts grant? Enter your answer with 2 decimal places and NO special characters. Do not submit a negative value; submit your answer as a positive value.
Read Details