Not going to dispute it. Looking at the source code 06.02.00.SqlDataProvider it looks like I match what the script should have done.
/** EventsSignupsMyEnrollments **/ CREATE PROCEDURE {databaseOwner}[{objectQualifier}EventsSignupsMyEnrollments] ( @ModuleID int, @UserID int, @SocialGroupId int ) AS BEGIN SET NOCOUNT ON; SET DATEFORMAT mdy;
SELECT s.EventID, s.SignupID, s.ModuleID, s.Userid, s.Approved, u.displayName as UserName, u.Email, c.EventTimeBegin, DATEADD(mi, c.Duration, c.EventTimeBegin) as EventTimeEnd, c.EventName, c.Importance, c.Approved as EventApproved, c.MaxEnrollment, ( SELECT SUM(NoEnrolees) FROM {databaseOwner}[{objectQualifier}EventsSignups] WHERE EventID = c.EventID AND c.Signups = 1 ) as Enrolled, PayPalStatus, PayPalReason, PayPalTransID, PayPalPayerID, PayPalPayerStatus, PayPalRecieverEmail, PayPalUserEmail, PayPalPayerEmail, PayPalFirstName, PayPalLastName, PayPalAddress, PayPalCity, PayPalState, PayPalZip, PayPalCountry, PayPalCurrency, PayPalPaymentDate, PayPalAmount, PayPalFee, NoEnrolees, r.EventTimeZoneId, AnonEmail, AnonName, AnonTelephone, AnonCulture, AnonTimeZoneId, S.FirstName, S.LastName, S.Company, S.JobTitle, S.ReferenceNumber, S.Street, S.PostalCode, S.City, S.Region, S.Country FROM {databaseOwner}[{objectQualifier}EventsRecurMaster] AS r RIGHT OUTER JOIN {databaseOwner}[{objectQualifier}Events] AS c ON r.RecurMasterID = c.RecurMasterID RIGHT OUTER JOIN {databaseOwner}[{objectQualifier}EventsSignups] AS s LEFT OUTER JOIN {databaseOwner}[{objectQualifier}Users] AS u ON s.UserID = u.UserID ON c.EventID = s.EventID LEFT OUTER JOIN {databaseOwner}[{objectQualifier}EventsMaster] AS e ON s.ModuleID = e.SubEventID Where s.Userid = @UserID AND (s.ModuleID = @ModuleID Or e.ModuleID = @ModuleID) AND (r.SocialGroupId = @SocialGroupId or (r.SocialGroupId is null and @SocialGroupId = 0)) ORDER BY c.EventTimeBegin desc END GO
|