cvc-complex-type.3.2.2 attribute 'uuid' is not allowed to appear in element 'jasperreport'

后端 未结 11 931
盖世英雄少女心
盖世英雄少女心 2020-12-02 23:57

Downloaded iReport-4.6.0 for Linux and when creating a new report via the File->New... menu, the new report is not shown in the preview, but the error message cvc-comp

相关标签:
11条回答
  • 2020-12-03 00:21

    In my case I just removed uuid="63f04b11-4b7e-4cf1-99b5-a5ec6db799d6" I generated a sample report for testing it worked perfectly

    So you can try by removing uuid=" "

    0 讨论(0)
  • 2020-12-03 00:21

    Strictly speaking this fix is only for Jaspersoft Studio, however this question is the first result when searching for the attribute 'uuid' is not allowed error.

    For Jasper Server version <= 4.5.0 and Jaspersoft Studio 6.11:

    1. Right click on the jrxml file in the Project Explorer -> Properties -> Jaspersoft Studio -> Compatibility -> Source .jrxml Version -> JasperReports 4.5.0
    2. Right click on the server in the Repository Explorer -> Edit JasperReports Server Connection -> Advanced Settings -> JasperReports Library Version -> JasperReports 4.5.0

    The second step is important if you are using Jaspersoft Studio to publish to the server.

    0 讨论(0)
  • 2020-12-03 00:37

    I found an answer:

    I opened the JRXML file with notepad++ and did a "Search and Replace" of uuid="\w*-\w*-\w*-\w*-\w*", and selected REGULAR EXPRESSION, with empty string then all the occurrences of this wrong tag were removed.

    Worked for me.

    0 讨论(0)
  • 2020-12-03 00:37

    I have a good easy solution.

    I am supporting reports on Jasper Server 4.5, with Jasper Studio 5.5

    1. In Jasper Studio, delete the server reference if there is one.
    2. Recreate the connection. When you create the server connection, go to "Advanced Settings > Jasper Server Library Version" and select your server version from the list.
    3. Open your report, check that the uuid tags have been removed, Deploy
    0 讨论(0)
  • 2020-12-03 00:40

    Open report in the notpad++ and just only remove uuid and it's number.. After You will compile proper and generate report.... I have same problem and I solveby this way..

    0 讨论(0)
  • 2020-12-03 00:41

    I just suggested my coworker who also run into the problem this:

    sed -i 's/ uuid="[^"]*"//g' $(find * -name \*.jrxml)
    

    I don’t normally use sed(1)-i but she’s on GNU/Linux so it wasn’t a problem here. The more professional Unix way of solving this is:

    find * -name \*.jrxml -print0 | while IFS= read -d '' -r file; do
        ed -s "$file" <<-'EOF'
            1,$g/ uuid="[^"]*"/s///g
            w
            q
        EOF
    done
    

    (These four spaces are tabs, otherwise it won’t work, and you need mksh(1) or another shell that can read NUL-separated input.)

    You could also use Perl:

    find * -name \*.jrxml -print0 | xargs -0 perl -pi -e 's/ uuid="[^"]*"//g'
    

    Or something like that, anyway, depending on your needs, your xargs(1), etc. ;-)

    0 讨论(0)
提交回复
热议问题