Jump to content
We've recently updated our Privacy Statement, available here ×

gundinge

Members
  • Posts

    15
  • Joined

  • Last visited

 Content Type 

Profiles

Forum

Events

Featured Visualizations

Knowledge Base

Documentation (PDF Downloads)

Blog

Documentation (Test Area)

Documentation

Dr. Jaspersoft Webinar Series

Security Advisories

Downloads

Posts posted by gundinge

  1. Dear Elizam,

    sorry for late feedback, I was on a business trip.

     

    there is no domain security file - for this I am using only a datasource (data base) connection direct to a table source.

    For profile attributes I am using following statement:

     

    INSERT INTO JIProfileAttribute

    (id, attrName,attrValue,principalobjectclass,principalobjectid)

    values(nextval('public.hibernate_sequence'),'ROLE_R03018','''AT'',''DE'',''SK''','com.jaspersoft.jasperserver.api.metadata.user.domain.impl.hibernate.RepoUser',45313);

     

     

    I found the records in table "jidashboardframeproperty".

     

    Depend on the user profile attribute of user (user 1 or user 2), which creates the dashboard, all other user will see respective countries of this user.

     

    It is correct, I am using "parameters" which include profile attribute in the where clause (sql) of loggedin user. loggedin user should see only allowed countries.

     

    Parameter Country is a multi-select query input control and sql statement looks like as follow:

    select country_code, country_name from country where country_code IN ($P!{LoggedInUserAttribute_ROLE_R03018})

     

    best regards

  2. Dear all,

    I have following scenario: (jasperserver 4.7, ireport 4.7)

     

    I have created 3 line chart (3 jrxml) with same parameters TIME and COUNTRY.

    Further, user profile attribute "ROLE_R03018" is involved.

    I have 2 users which have access to that three reports.

    User 1: user profile attribute COUNTRY => "AT, DE, SK, IN,..." (in sum: 100 country codes)

    User 2: user profile attribute COUNTRY => "AT, DE" (only two!)

     

    If I call each report (=> each chart) with user 1, he will see all countries.

    If i call each report (=> each chart) with user 2, he will see only two country.

    => row based security works!!

     

    If user 1 creates the dashboard, all users, which have access to that dashboard will see all countries.

    (independet of user profile attribute !!!)

     

    If user 2 created the dashboard, all users will see only two countries.

    In that case, the row based security does not work! why???

    In database I found following records:

     

    dashControlFrameParamName => "LoggedInUserAttribute_ROLE_R03018"

    dashControlFrameParamValue =>"AT, DE, SK, IN,..." (in sum: 100 coutry codes)

    dashControlFrameDefaultParamValue =>"AT, DE, SK, IN,..." (in sum: 100 coutry codes)

    (in case of user 1 is created dashboard)

     

    dashControlFrameParamName => "LoggedInUserAttribute_ROLE_R03018"

    dashControlFrameParamValue =>"AT, DE"

    dashControlFrameDefaultParamValue =>"AT, DE"

    (in case of user 1 is created dashboard)

     

    What can I do, that the row based security also work in case of calling reports in a dashbaord?thanks and best regard

  3. Dear All,

    I have some troubles with using "access grants" in an OLAP View (JasperReports 4.5)

    I have a mondrian cube with one cube fact table and four dimensions and I want to "add a row-level security". 

    One of my dimesion is a geographical view with level "CONTINENT", "REGION", "COUNTRY" and "OFFICE".

    Depends on User - Role and "profile attributes" the logged in user is allowed to see defined countries.

    In my case:

    User: crmuser    Role: ROLE_CRM_USER    Profile Attributes: (Country: AT)User: crmmanager    Role: ROLE_CRM_MANAGER    Profile Attributes: (Country: AT, DE)

    My "roles.xml" which is linked in in the connection to mondrian cube (analysis connections) looks like followed:

                                                                                                                       [/code]

    If I am logged in as "crmmanager" I should see (hardcoded) only "AT" records (PIC.EUR.WEST EUR.AT) but I see the data without restrictions.

    If I am logged in as "crmuser" I should see only "AT" (depends on profile attribute), but I see all data too.

    Why?

    In case of "crmuser" it could be the "membergrant member" because the system do not know the correct level keys (continent, region) of profile attribute country  "AT"?

    But in case of "crmmanager", where I add the membergrant member" hardcoded (for testing I do not use profile attributes ) is also does not work?

    Many thanks in advance for you help

    best regards
    Stefan

  4. Hi Everyone,

    I am trying to add row level security to my domain in jasperserver pro 4.5, so that all users which have access to a domain (configured over role) can see only the rows with Country of there "profile Attributes".

    My schema file and security file is attached..

    For example

    user "crmuser" (profile attributes: [Country: AT]
    user "crmmanager" (profile attributes: [Country: AT,DE]

    If  I log in as crmuser and also as crmmanager I will see data from all countries.

    I couldn't find the reason and would appreciate, if anyone gives me a clue.

    Many Thanks
    Stefan

     

    EDIT 1:

    in catalina.out I got attached error message. I used the groovy function which is used in jasper tutorials?

     

    EDIT 2:

     

    I changed the filerExpression tag as followed:
    <filterExpression>testProfileAttribute(CDW_ET_COUNTRY.EK_COUNTRY, 'Country')</filterExpression>
    afterwards it works fine!



    Post Edited by gundinge at 03/28/2012 13:27
  5. Hi,
    I already found a solution how it works...
    I did a typecast from "bigdecimal" to  "float" and I used function "msg" and then it will work:

    ($V{MS_TURNOVER_AVG}.compareTo( new java.math.BigDecimal(0.00))== 0 ? "0" : msg("{0,number,##0.0 %}", new Float($V{MS_TURNOVER_EURMeasure}.floatValue() / $V{MS_TURNOVER_AVG}.floatValue())))

    best regards

  6. Hi all,
    I have a probelm: I want to divide two measures in a crosstab and become an "error evaluating expression" error.
    I have defined my measures as followed:
    MS_TURNOVER_EUR_Measure (class: java.math.BigDecimal, value: $F{MS_TU_EUR})
    MS_TURNOVER_AVG (class: java.math.BigDecimal, value: $F{MS_TU_AVG})
     

    the new text field expression is following: (class: java.math.BigDecimal)
    ($V{MS_TURNOVER_AVG}.compareTo( new java.math.BigDecimal(0.00))== 0 ? $V{MS_TURNOVER_EURMeasure} : $V{MS_TURNOVER_EURMeasure}.divide( $V{MS_TURNOVER_AVG} ))

    does somebody know where the failure is?

    many thanks in advanced!

    here you will find a part of my jrxml:

     

    Code:



    Post Edited by gundinge at 07/13/2010 12:08
  7. Hi,

    I want to have more than 2 rows in a crosstab? Is this possible?
    e.g.:
                         Product 1    Product 2 ......

    2010               10
        Q1                 6
           Jan             5
           Feb             0
           March         1
        Q2                 4
       .......................

    In my case I want to have 3 rows and one columns.
    If I create the crosstab with iReport wizzard I only can choose two rows....

    can you help me please?

    Many thanks in advance.
    best regards

     

     

    EDIT:

    I already solved my request



    Post Edited by gundinge at 05/20/2010 08:51
  8. I am using JasperServer 3.7.0 und iReport 3.7.0

    when I receive the report in excel format from a scheduled task (defined in JasperServer), the header is not displayed in it. Why?
    If I saved the Report from preview - view from iReport as excel - the header will be displayed.

    My property settings in jrxml is following:
    <property name="net.sf.jasperreports.export.xls.remove.empty.space.between.rows" value="true"/>
    <property name="net.sf.jasperreports.export.xls.remove.empty.space.between.columns" value="true"/>
    <property name="net.sf.jasperreports.export.ignore.page.margins" value="true"/>
    <property name="net.sf.jasperreports.export.xls.ignore.graphics" value="true"/>

    are they any other property setting to set?

    many thank for you help
    best regards

    Stefan

  9. Dear all,

    I have following problem:
    I created a working jrxml in iReport -->
    3 input paramater
    YEAR, WEEK, COUNTRY (use as a prompt)
    and
    2 parameter
    WHC_COUNTRY, WHC_YEARWEEK (with not use as prompt)

    WHC_COUNTRY has follwing default value expression:
    ( $P{COUNTRY}.isEmpty() == true ? "" :  " and ctry.ek_country = '"+ $P{COUNTRY}+ "' ")

    WHC_YEARWEEK has following default value expression:
    ($P{YEAR}.isEmpty()==true || $P{WEEK}.isEmpty()==true ? "" : " and timeday.ek_calendarweek > '" + $P{YEAR} + $P{WEEK} +"'" )

    The Language is "Groovy".
    The preview in iReport will work correctly.

    After testing I updated it into my JasperServer Instance (via repository navigator) - created all three input controls and run the report. Now I got follwing error msg:

    1 - Error evaluating expression : Source text : ( $P{COUNTRY}.isEmpty() == true ? "" : " and ctry.ek_country = '"+ $P{COUNTRY}+ "' ")
    java.lang.Exception: 1 - Error evaluating expression :      Source text : ( $P{COUNTRY}.isEmpty() == true ? "" :  " and ctry.ek_country = '"+ $P{COUNTRY}+ "' ")
     at com.jaspersoft.ireport.jasperserver.ws.WSClient.runReport(WSClient.java:403) 
     at com.jaspersoft.ireport.jasperserver.ws.WSClient.runReport(WSClient.java:320)
     at com.jaspersoft.ireport.jasperserver.ReportRunner.run(ReportRunner.java:70) ...

    what is the error in this default expression (WHC_COUNTRY)? why does it work in case of  running as preview (iReport) and not on JasperServer? (both are 3.7)

    Many thanks in advance
    best regards

    Stefan
     

×
×
  • Create New...