LEFT OUTER JOIN problems

Beep

I have a error I relay cant understand, if some one could explain to me the problem as its preventing me from progressing with my program.

the error is saying i have a syntax error on the JOIN

Code

using (OleDbDataAdapter query_prof = new OleDbDataAdapter("SELECT aspnet_Users.AplicationId, aspnet_User.UserName, aspnet_User.LastActivityDate FROM (aspnet_Users LEFT OUTER JOIN UserProfile ON aspnet_User.UserName = UserProfile.UserName) WHERE (UserProfile.UserName IS NULL)", conn))
{
    query_prof.Fill(dt);
}
PeterRing

Leave out the parenthesis from the from clauses:

FROM (aspnet_Users LEFT OUTER JOIN UserProfile ON aspnet_User.UserName = UserProfile.UserName)

you should do :

FROM aspnet_Users LEFT OUTER JOIN UserProfile ON aspnet_User.UserName = UserProfile.UserName

Collected from the Internet

Please contact [email protected] to delete if infringement.

edited at
0

Comments

0 comments
Login to comment

Related