Search found 176 matches

by robinwilson16
Thu Mar 02, 2017 11:39 pm
Forum: Table Valued Functions
Topic: TVF_ProAchieveRatesByLearningAim
Replies: 0
Views: 51

TVF_ProAchieveRatesByLearningAim

Returns the retention, pass and achievement rates from ProAchieve for every learning aim. It uses OpenQuery as otherwise the LB_GEN_FUN_CalculateRate function cannot be called from a linked database CREATE FUNCTION [dbo].[TVF_ProAchieveRatesByLearningAim] ( @Session VARCHAR(10) ) RETURNS TABLE AS RE...
by robinwilson16
Thu Mar 02, 2017 11:28 pm
Forum: Table Valued Functions
Topic: TVF_PostCodeDistance
Replies: 0
Views: 67

TVF_PostCodeDistance

Returns the distance (as the crow flies if he is going in a straight line) between two post codes outputted in the required unit of measurement. Link to regularly updated post code source data is: https://www.freemaptools.com/download-uk-postcode-lat-lng.htm File contains millions of rows so if you ...
by robinwilson16
Thu Mar 02, 2017 11:23 pm
Forum: Table Valued Functions
Topic: TVF_ModuleCodeYearlyMapping
Replies: 0
Views: 51

TVF_ModuleCodeYearlyMapping

Used to return a course code as would have been coded in a previous year, useful for yearly comparisons. This coding will be specific for here but you should be able to adapt if part of a course code in the same in both years and the rest includes the session/year CREATE FUNCTION [dbo].[TVF_ModuleCo...
by robinwilson16
Thu Mar 02, 2017 11:20 pm
Forum: Table Valued Functions
Topic: TVF_LearnerNumbersByFundModel_Q
Replies: 0
Views: 52

TVF_LearnerNumbersByFundModel_Q

Returns the learner numbers against a qualification split by the funding model - note that this has some coding specific to here so you will probably need to adapt somewhat CREATE FUNCTION [dbo].[TVF_LearnerNumbersByFundModel_Q] ( @Session VARCHAR(10), @QualID numeric(16, 0) ) RETURNS TABLE AS RETUR...
by robinwilson16
Thu Mar 02, 2017 11:19 pm
Forum: Table Valued Functions
Topic: TVF_LearnerNumbersByFundModel_PRG
Replies: 0
Views: 44

TVF_LearnerNumbersByFundModel_PRG

Returns the learner numbers against a programme split by the funding model - note that this has some coding specific to here so you will probably need to adapt somewhat CREATE FUNCTION [dbo].[TVF_LearnerNumbersByFundModel_PRG] ( @Session VARCHAR(10), @ProgID numeric(16, 0) ) RETURNS TABLE AS RETURN ...
by robinwilson16
Thu Mar 02, 2017 11:17 pm
Forum: Table Valued Functions
Topic: TVF_LearnerMainStudentApp
Replies: 0
Views: 53

TVF_LearnerMainStudentApp

Returns a learner's main student application record Will always return a single line for each learner, useful for learner lists including main application information CREATE FUNCTION [dbo].[TVF_LearnerMainStudentApp] (@Session VARCHAR(10), @StudentRef VARCHAR(20)) RETURNS TABLE AS RETURN SELECT TOP ...
by robinwilson16
Thu Mar 02, 2017 11:16 pm
Forum: Table Valued Functions
Topic: TVF_LearnerMainApp_PRG
Replies: 0
Views: 29

TVF_LearnerMainApp_PRG

Returns a learner's main application at the programme level Will always return a single line for each learner, useful for learner lists including main application information CREATE FUNCTION [dbo].[TVF_LearnerMainApp_PRG] (@Session VARCHAR(10), @StudentRef VARCHAR(20)) RETURNS TABLE AS RETURN SELECT...
by robinwilson16
Thu Mar 02, 2017 11:14 pm
Forum: Table Valued Functions
Topic: TVF_LearnerMainAim_YR
Replies: 0
Views: 31

TVF_LearnerMainAim_YR

Returns a learner's main aim at the year level Will always return a single line for each learner, useful for learner lists including main course information CREATE FUNCTION [dbo].[TVF_LearnerMainAim_YR] (@Session VARCHAR(10), @StudentRef VARCHAR(20)) RETURNS TABLE AS RETURN SELECT TOP 1 Value = MEY....
by robinwilson16
Thu Mar 02, 2017 11:14 pm
Forum: Table Valued Functions
Topic: TVF_LearnerMainAim_Q
Replies: 0
Views: 66

TVF_LearnerMainAim_Q

Returns a learner's main aim at the qualification level Will always return a single line for each learner, useful for learner lists including main course information CREATE FUNCTION [dbo].[TVF_LearnerMainAim_Q] (@Session VARCHAR(10), @StudentRef VARCHAR(20)) RETURNS TABLE AS RETURN SELECT TOP 1 Valu...
by robinwilson16
Thu Mar 02, 2017 11:13 pm
Forum: Table Valued Functions
Topic: TVF_LearnerMainAim_PRG
Replies: 0
Views: 28

TVF_LearnerMainAim_PRG

Returns a learner's main aim at the programme level Will always return a single line for each learner, useful for learner lists including main course information CREATE FUNCTION [dbo].[TVF_LearnerMainAim_PRG] (@Session VARCHAR(10), @StudentRef VARCHAR(20)) RETURNS TABLE AS RETURN SELECT TOP 1 Value ...