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 9138037
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 17, 20262026-06-17T09:12:17+00:00 2026-06-17T09:12:17+00:00

I have a SQL Server 2005 table in which I store the book exchanges

  • 0

I have a SQL Server 2005 table in which I store the book exchanges that take place between two students.

ExchangeID   BookID   ExchangeDate   FromPersName   ToPersName
1            23       23.12.2011     John           Matt
2            22       15.02.2012     Billy          Ken
3            23       27.12.2011     Matt           Riddley
5            23       05.03.2012     Riddley        Josh
6            22       08.03.2012     Ken            Rachel
7            23       19.03.2012     Josh           Laura
8            23       15.01.2013     Laura          Mike
9            22       17.01.2013     Rachel         Stephanie

I want to generate a report for a specified year that looks like this:

Year:2012

BookID    PersonName      ReceivingDate   DeliveryDate
23        Matt            01.01.2012      27.02.2012
23        Riddley         27.02.2012      05.03.2012
23        Josh            05.03.2012      19.03.2012
23        Laura           19.03.2012      31.12.2012
22        Ken             01.01.2012      08.03.2012
22        Rachel          08.03.2012      31.12.2012
  • 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-17T09:12:18+00:00Added an answer on June 17, 2026 at 9:12 am

    This is half solution.You need to change it a litle bit to work. I will not make whole query for Your homework. Put some effort!

    http://sqlfiddle.com/#!3/39d73/17

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I have an SQL Server 2005 table that has a varchar(250) field which contains
I have a sql server 2005 table which has xml store in a text
I have a SQL Server 2005 table that has a string column in which
SQL Server 2005 I have an SQL Function (ftn_GetExampleTable) which returns a table with
I have a table in SQL Server 2005 which has a date time field.
I have an ADOQuery that inserts a record to SQL Server 2005 table that
I have a table made in SQL Server 2005 which has the following columns:
I have a table in a SQL Server 2005 Database that is used a
SQL Server 2005. I have a stored procedure which accepts a few parameters that
I have a table in SQL Server 2005 which contains some changelog data for

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.