After logging in a user I want to display records from a second database. I tried to inner join the databases but I don't think its possible in WebMatrix.
If the email field within the database used for logging user in is the same as the email field in the second database, what code do I need to use this variable to insert it into new query against the second database so I am able to show user records.
I am adding my attempts so far.. any direction greatly appreciated. Regards. SJ
// Initialize general page variables
var authenticatedUser = "";
var authenticatedUserLastName = "";
var authenticatedUseremail = "";
authenticatedUser = WebSecurity.CurrentUserNam
var db = Database.Open("StarterSite
var UserData = db.QuerySingle("SELECT FirstName, LastName, email FROM UserProfile WHERE LOWER(Email) = LOWER(@0)", authenticatedUser);
authenticatedUserLastName = UserData.LastName;
authenticatedUserLastName = UserData.email;
<meta charset="utf-8" />
Hello, <a class="username" href="~/Account/PasswordRe
set" title="Change password">@authenticatedUs