Closed GoogleCodeExporter closed 9 years ago
Please check your context.xml file once again. Attached configuration contains
two resources with the same name:
Resource name="jdbc/liferay"
The first resource shoud have the name as follows:
Resource name="jdbc/aperte-reports"
Regards,
Tomek
Original comment by tsera...@bluesoft.net.pl
on 27 Nov 2012 at 11:18
hi Tomek
in context.xml file which i wrote, i want to:
enable db MySQL:
<Resource name="jdbc/liferay"
auth="Container"
driverClassName="com.mysql.jdbc.Driver"
maxActive="8"
maxIdle="4"
password="lportal_cims"
type="javax.sql.DataSource"
url="jdbc:mysql://localhost/lportal_cims"
username="lportal_cims"
/>
disable HSQL:
<!--
<Resource name="jdbc/liferay"
auth="Container"
driverClassName="org.hsqldb.jdbcDriver"
maxActive="8"
maxIdle="4"
password=""
type="javax.sql.DataSource"
url="jdbc:hsqldb:${liferay.home}/data/hsql/lportal"
username="sa"
/>
-->
So, no the same Resource name
Thanks
ThaiSon
Original comment by sonmapqn...@gmail.com
on 27 Nov 2012 at 11:55
Oh, I'm sorry... I haven't noticed that the first statement was a comment. I
will try to check it soon.
Tomek
Original comment by tsera...@bluesoft.net.pl
on 27 Nov 2012 at 12:00
Original comment by tsera...@bluesoft.net.pl
on 27 Nov 2012 at 2:46
Original comment by tsera...@bluesoft.net.pl
on 27 Nov 2012 at 2:46
hi Tomek
Thanks for your support. I find out the bug. The bug is located in query of
liferay-users.jrxml.
<queryString>
<![CDATA[select screenname, firstname fn, lastname ln
from USER_ order by lastname]]>
</queryString>
It run on HSQL but not run on MySQL. When we change type of db, db syntax
sometimes must be changed. However, I run liferay-users.jrxml on IReport 4.8
that datasource connect directly to MySQL, it run (?)
By the way, thanks a lot
ThaiSon.
Original comment by sonmapqn...@gmail.com
on 27 Nov 2012 at 2:50
Hi ThaiSon,
You're welcome.
I don't know if you know the solution to this problem... I found out that there
are problems using aliases in sql query with some jdbc drivers
(http://community.jaspersoft.com/questions/513341/unknown-column-name). You can
just remove aliases from query:
<queryString>
<![CDATA[select screenname, firstname, lastname
from USER_ order by lastname]]>
</queryString>
and then it works properly.
Regards,
Tomek
Original comment by tsera...@bluesoft.net.pl
on 27 Nov 2012 at 3:13
Original comment by tsera...@bluesoft.net.pl
on 27 Nov 2012 at 3:22
Original issue reported on code.google.com by
sonmapqn...@gmail.com
on 27 Nov 2012 at 9:08Attachments: