Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 7930767
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 3, 20262026-06-03T20:31:45+00:00 2026-06-03T20:31:45+00:00

I want to make a SQL query that gives the total order value for

  • 0

I want to make a SQL query that gives the total order value for a month (of my choice).
For example I want to know how much money January generated 2010.

    Table = ordrar

    ordernumber date
    1           2010-01-02
    2           2010-01-03
    3           2010-01-03
    4           2010-01-04
    5           2010-01-05
    6           2010-02-17
    7           2010-02-18

    Table = orderrader

    rownummer   ordernumber price   amount
    1           1           8624    3
    2           1           4794    2
    3           1           8755    3
    4           2           7803    1
    5           2           8987    3
    6           3           4575    3
    7           3           8747    1
    8           4           5439    3
    9           4           8624    1
    10          5           9574    2
    11          6           4794    1
    12          7           9102    2

Thank you.

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-06-03T20:31:47+00:00Added an answer on June 3, 2026 at 8:31 pm

    Maybe something like this:

    SELECT
        SUM(price*amount) AS Total
    FROM
        orderrader
        JOIN ordrar
            ON orderrader.ordernumber =ordrar.ordernumber
    WHERE
        YEAR(date)=2010
        AND MONTH(date)=1
    
    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I am using SQL Server 2008. I want to write a query that gives
I want to make many inserts in a single SQL statement, pretty much like
I have a MS SQL view that I want to make available as a
So I have a couple SQL commands that I basically want to make a
If we want in our WPF application to let a user make a SQL
Suppose I have a SQL query that looks like this: SELECT fName from employees
Looking at similar questions, I actually want the exact opposite of this: SQL query
I have a DropDownList that is filled with values returned by a SQL Query.
Right now i want to make a small java application, in order to learn
I want to make a SELECT item with the result of a query, I

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.