danweifis Posted January 3, 2013 Share Posted January 3, 2013 When a username login, the username value is taken as parameter in order to complete the "Where" condition in the SQL. HOw can be done? Link to comment Share on other sites More sharing options...
ajinkya_c Posted January 3, 2013 Share Posted January 3, 2013 Use $P{LoggedInUsername} parameter in where clause. Link to comment Share on other sites More sharing options...
oesina Posted January 4, 2013 Share Posted January 4, 2013 If you need to create some condition depending on the user name, you can create another parameter, and define formula in the Initial Expression.Variable will not work, cause variables are evaluated only per records of data. Link to comment Share on other sites More sharing options...
danweifis Posted January 10, 2013 Author Share Posted January 10, 2013 Hi, I tried without success. Can you give me a hand, please. Also, I read it a lot and still nothingI am using jasperserver 4.7.In IREPOR: I have the following SQlSelect * from users where users=$P{LoggedInUsername}The class definition of the parameter is: com.jaspersoft.jasperserver.api.metadata.user.domain.Usewithout default value and prompt FALSEIn Jasperserver I am only uploading the JXML , I am not doing any control input.Thanks Daniel Link to comment Share on other sites More sharing options...
Recommended Posts
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now