This project has moved. For the latest updates, please go here.

Has anybody made a report using SQL management S?

Topics: User Forum
Apr 16, 2012 at 11:50 PM
Edited Apr 16, 2012 at 11:51 PM

Hi has anybody successfully made a report which shows students grades / subject / assignment?

if so has anybody got any good instructions about how to achieve this, my SQL server knowledge is not great.

I've managed to connect to the SLK database using managment studio but not sure what to do from there.

even if its just a quick how to get the query to link the tables and data I need, that would be a great start..

If nobody knows its ok, just thought I would ask just incase ;o)

Jun 8, 2012 at 1:26 AM

Use the following tables in the SQL database,

AssignmentItem, LearnerAssignmentItem, User Item and AttemptItem

Create a new view and try out this sql script.



SELECT     dbo.UserItem.Name, dbo.LearnerAssignmentItem.FinalPoints, dbo.AssignmentItem.Title, dbo.AssignmentItem.DateCreated, dbo.AttemptItem.FinishedTimestamp
FROM         dbo.UserItem INNER JOIN
                      dbo.LearnerAssignmentItem ON dbo.UserItem.Id = dbo.LearnerAssignmentItem.LearnerId INNER JOIN
                      dbo.AssignmentItem ON dbo.LearnerAssignmentItem.AssignmentId = dbo.AssignmentItem.Id INNER JOIN
                      dbo.AttemptItem ON dbo.UserItem.Id = dbo.AttemptItem.LearnerId AND dbo.LearnerAssignmentItem.Id = dbo.AttemptItem.LearnerAssignmentId
WHERE     (dbo.LearnerAssignmentItem.IsFinal = 'TRUE') AND (dbo.AssignmentItem.AutoReturn = 'TRUE')




Hope this helps.



Jul 17, 2013 at 5:00 PM
Thanks so much I will try this! :)
Jul 17, 2013 at 5:05 PM
Hi I executed the code you provided in a view and I saw the results! How do I export that to a CSV? or something?

Jul 18, 2013 at 2:29 AM
If you are using SQL 2008, you right-click the database, tasks, export data, on the destination select a flat file. The rest should be self-explained I believe. :)
Jan 13, 2014 at 5:52 PM
Edited Jan 23, 2014 at 7:44 AM

This is great!