Database Design (SQL)

posted by .

I ned help creating a query that shows the number of days left before the end of the term. I need the following functions to accomplish this: CONCAT, DAYOFYEAR, NOW. So far I have this for my query:

SELECT CONCAT('There are ',DAYOFYEAR(NOW()),' ',DAYOFYEAR(NOW())) AS `Days Left`;

The result is supposed to say: There are 69 days left before school ends for the spring term!!!

The result I got was: There are 79 79

Respond to this Question

First Name
School Subject
Your Answer

Similar Questions

  1. window 2003 server

    You are the network administrator for a telecommunications company in Rochester, New York. The network consists of two Windows Server 2003 systems and 57 Windows XP Professional systems. Both servers are used as domain controllers. …
  2. Database Design (SQL)

    Hi I need help creating an SQL query to display each faculty member's last name, comma, first name as a CONCATenated element, then their salary as CONCATenated element with a dollar sign and comma. Then, the boss's last name, comma, …
  3. Database Design (SQL)

    Hi I need help creating an SQL query to display each faculty member's last name, comma, first name as a CONCATenated element, then their salary as CONCATenated element with a dollar sign and comma. Then, the boss's last name, comma, …
  4. Database Design (SQL)

    I need help creating a query that shows the number of days left before the end of the term. I need the following functions to accomplish this: CONCAT, DAYOFYEAR, NOW. So far I have this for my query: SELECT CONCAT('There are ',DAYOFYEAR(NOW()),' …
  5. SQL

    Display a list of all instructors, showing their ID, name, and the number of sections that they have taught. Make sure to show the number of sections as 0 for instructors who have not taught any section. Your query should use an outerjoin, …
  6. databases

    Fernando Cilebra has always ben facinated by skateboards. Fernando has won several contests, both locally and nationally. His interest in skateboards led him to open Fernando's Shop in Denton, Maine. Fernando sells street, trick, and …
  7. buissness

    Data Security Password protect the database you created for your individual assignment in Week Three. Create a matrix to indicate the permissions (read, insert, delete, modify) you would grant to different users of your database. Create …
  8. SQL PROGRAMMING INFORMATION SYSTEMS

    In the following SQL query why do they have an independent letter then period then the table name?
  9. math, functions

    f(x) = 1/(1−x) is given. From this we produce two new functions: g(x) = f(f(x)) and h(x) = f(g(x)). (a) For which values of x is f(x) undefined?
  10. Functions

    f(x) = 1/(1−x) is given. From this we produce two new functions: g(x) = f(f(x)) and h(x) = f(g(x)). (a) For which values of x is f(x) undefined?

More Similar Questions