Click here to Skip to main content
14,640,679 members
Rate this:
Please Sign up or sign in to vote.
See more:
I want to run this sql query to populate the gridview in my asp.net webform,

SELECT userinfo.user_id "User",userinfo.User_last_login "Last Login",orginfo.Dept,orginfo.Div FROM UserInfo 
INNER JOIN OrgInfo  ON userinfo.Org_Code=orginfo.org_code  
WHERE userinfo.User_ID= 'txtUserId.text'


the userinfo.user_ID value is coming from the textfield

gridview is populating with userId,lastlogin,Dept,Div columns

thnks in advance..

[edit]Code block added, SQL formatted for readability - OriginalGriff[/edit]
Posted
Updated 30-Mar-13 21:45pm
v2
Comments
Zoltán Zörgő 31-Mar-13 3:10am
   
And your question is...?
OriginalGriff 31-Mar-13 3:46am
   
This is not a good question - we cannot work out from that little what you are trying to do.
Remember that we can't see your screen, access your HDD, or read your mind.
Use the "Improve question" widget to edit your question and provide better information.

1 solution

Rate this:
Please Sign up or sign in to vote.

Solution 1

"SELECT userinfo.user_id as User, userinfo.User_last_login as [Last Login], orginfo.Dept, orginfo.Div FROM UserInfo INNER JOIN OrgInfo ON userinfo.Org_Code=orginfo.org_code WHERE userinfo.User_ID='" + txtUserId.text + "';"
   
Comments
Maciej Los 31-Mar-13 15:24pm
   
+5

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)




CodeProject, 503-250 Ferrand Drive Toronto Ontario, M3C 3G8 Canada +1 416-849-8900 x 100