Ram Mandavkar

+ Follow
since Mar 23, 2009
Cows and Likes
Total received
In last 30 days
Total given
Total received
Received in last 30 days
Total given
Given in last 30 days
Forums and Threads
Scavenger Hunt
expand Ranch Hand Scavenger Hunt
expand Greenhorn Scavenger Hunt

Recent posts by Ram Mandavkar

Hello All,

I want to use UNION in hibernate
Does HQL support UNION (or INTERSECT)?

Any one know about this.
Which version of Hibernate supports UNION / INTERSECT

Ram Mandavkar
Hello Victor,

Thanks for suggestion
I was using Hibernate 3.0 which is not supported 'WITH' KEYWORD

as per Hibernate 3.1.3 Released
** Improvement
* [HHH-1520] - with clause with implied joins within an explicit join

It works with Hibernate 3.1.3

I had changed Hibernate 3.0 with Hibernate 3.1.3
and it works

Thanks again

Hello All,

SELECT p.id, p.name, s.id, s.name, c.name from Product As p inner join supplier as s On p.supplierid =s. supplierid and s. compayid=1 inner join customer as c on p.customerid=c.customerid and c. compayid=1

I do not want to use where close in above SQL

HQL (Working):
SELECT p.id, p.name, s.id, s.name, c.name from Product p inner join p.supplier as s inner join p.customer as c

I had tried

SELECT p.id, p.name, s.id, s.name, c.name from Product p inner join p.supplier as s and s. compayid=1 inner join p.customer as c and c. compayid =1

But Exception “unexpected token: and”

Can anyone help me to add ‘and s.compayid =1’ clause in above HQL to get it work.

Ram Mandavkar
As shown in index.jsp ( form tag is missing in above code but it is there in my code
<s:form id='theForm2' theme="ajax" > )

‘FIRST ‘ is the link with action="Searchresult" method="next" theme="ajax"
If I click on ‘FIRST’ link then ‘Searchresult’ action will get called and index.jsp page is submitted and result jsp page (Remotediv.jsp) will get render into index.jsp as <div id="two"/>

How to send the checkboxes from Remotediv.jsp(Which are not part of index.jsp) page to the action(Searchresult)?
So how to access remote page(Remotediv.jsp) elements which is part of main page(index.jsp) as DIV.
12 years ago

David Newton wrote:I don't see a form or JavaScript submission anywhere; how are you sending the checkboxes to the action?

I was bit delayed.

12 years ago
I am New o struts 2,
I am using remove div method to populate search result into a table with struts tag checkbox, I can able to traverse through search result with four link ( FIRST, NEXT, PRIVIOUS, LAST )
In my action class I am getting null pointer exception (java.lang.NullPointerException)at
for (Iterator<String> iterator = isSelectedData.iterator(); iterator.hasNext();)
While collecting checked values from Remotediv.jsp

I did not understand why this exception is coming
How to access values from remove div where a nex jsp is getting render which is pare of Index.JSP.


<s:url id="url" action="Searchresult" method="next"/>
<s:a theme="ajax" targets="two" href="%{url}" ><b>First</b>
<div id="two" style="border: 1px solid yellow;width:823px;height:350px;">

Config file

<action name="Searchresult" class="remotemonitor.userpreset.SearchResultAction" >
<result name="success">/jsp/remotemonitor/userpreset/SearchResult.jsp</result>

SearchResultAction.java Actionclass

private ArrayList<String> isSelectedData;
private List<SearchResultDAO> searchResultDAO;

public String next() throws Exception{
for (Iterator<String> iterator = isSelectedData.iterator(); iterator.hasNext();) {
String key = iterator.next();
System.out.println("Selected : "+ key);
setSearchResultDAO((List<SearchResultDAO>) new ArrayList());
for( int j=11;j<=20;j++ ){
SearchResultDAO Data_List = new SearchResultDAO();
Data_List.setPresetnm( "ROW"+j );
getSearchResultDAO().add( Data_List );

public ArrayList<String> IsSelectedData() {
return isSelectedData;
public void setIsSelectedData(ArrayList<String> isSelectedData) {


<table width="50%" border="1">
<s:iterator value="searchResultDAO">
<tr class='fieldsetfont'>
<td width="9%" align="center" bgcolor="#6389A0" class="frontValid11">
<s:checkbox labelposition="right" name=" isSelectedData"
label="%{presetnm}" value="%{presetCheck}" fieldValue="%{presetid}"/>
<td width="19%" align="center" bgcolor="#6389A0" class="frontValid11">
<s:a theme="simple" href="UserPreset.action?presetid=%{presetid}">
<s:property value="presetid" />
<td width="68%" align="center" bgcolor="#6389A0" class="frontValid11"> <s:property value="presetnm" />
12 years ago
Hello all,

I am using struts2-core-2.0.14 and Tomcat 6.0.14

'Remote forms' and 'Remote link tag' did not work on IE6 But works on IE7 and FF3

In IE6 for Remote forms and Remote link tag when I clicked on any button or link new page gets open
In IE7 and FF3 for Remote forms and Remote link tag when I clicked on any button or link, then only div part of that page get render.

Strut 2 had any explorer compatibility issue. Or I need to change some settings in IE6.

Need some suggestions.

Waiting for reply,
12 years ago

Ulf Dittmer wrote:What do you mean by "does not get executed"? Surely it will get executed if you run the code. The results may be different, in which case you should tell us how they differ.

"does not get executed"?

In Xp I can see
System.out.println as LPT1 and LPT2

Vista there is no System.out.println
12 years ago

Is there any compatibility issue for Windows vista with javax.comm.* package

Any Other package which can help to access PC parallel port and compatible to Win Xp and Win Vista

Code Which does not get executed on Vista but get executed on Xp

public void CollectAllComport(){
Enumeration portList;
CommPortIdentifier portId;
portList = CommPortIdentifier.getPortIdentifiers();
while (portList.hasMoreElements()){
portId = (CommPortIdentifier) portList.nextElement();
if (portId.getPortType() == CommPortIdentifier.PORT_PARALLEL){
System.out.println( portId.getName() );
}catch( Exception E ){
12 years ago

I am new to struts 2.0

i had User registration page with a search button on it
If i want to modify User then i have to open the search on new window to select the User and
get id and collection information from DB and display on user page for modification process.

so i am facing some problem in it.

1] How to open the child window from parent window without using windows.open('action name',,,,) or it is necessary to use it.
2] How to render values into that user search table on child window.
3] How to select single use from that table from child window.
4] How to pass selected user id from child window to its parent window on any submit button(on child window).
12 years ago

David Newton wrote:As per the S2 Ajax tag docs you'll probably need to use Dojo's even handling mechanism. On that page there's a link to the Dojo event handling mechanism docs.

Thanks for reply

Can we give check box to each tree node as we are giving label to each tree nodes
if yes then
how to collect Checked tree notes out of all tree check box on submit event/button
12 years ago

Is it possible to get ondblclick event (mouse event) with Tree or treenote tag(<s:treenode/> or <s:tree />)

Ram Mandavkar
12 years ago

David Newton wrote:I think you misunderstood my response--I meant that this isn't a Struts-specific issue: it's a browser issue, so should be addressed in a browser-related forum. Setting absolute sizes might help in reducing some of the flicker.

It's also unlikely that having a <head> etc. section will produce legal HTML--you can't embed an entire HTML page inside a <div> in the "parent" HTML page.

now i understand.
12 years ago

David Newton wrote:This is much more likely to be a browser issue (as opposed to Struts)--it's the browser that's doing the redraw.

Hi David,

Thanks For replay

But is there any way to avoid this.
or can you suggest me any another way with which i can able to avoid this Flickering.

12 years ago
I am new in Struts 2.0

I tried to use struts 2.0 tag <s:div ( ajax ) to refresh Table contains
I can able fetch data from server after each 2 sec But its gives me flickering effect to table

So any one can tell me how to avoid this flickering effect on table

please go through code

<s:url id="ajaxTest" value="/TEST/DataRefreshAction.action" />
<s:div id="once" theme="ajax" href="%{ajaxTest}" updateFreq="2000">

<%@ taglib prefix="s" uri="/struts-tags" %>

request.setAttribute("decorator", "none");
response.setHeader("Cache-Control","no-cache"); //HTTP 1.1
response.setHeader("Pragma","no-cache"); //HTTP 1.0
response.setDateHeader ("Expires", 0); //prevents caching at the proxy server
<link href="../jsp/style1.css" rel="stylesheet" type="text/css">
<link href="../jsp/Pages.css" rel="stylesheet" type="text/css"/>
<body topmargin="0" leftmargin="0" bgcolor="#FFFFFF" >
<table class="repTableLayout">
<s:iterator value="transdata">
<td width="8%" class="frontValid11"></td>
<s:iterator value="top" >
<td width="15%" class="frontValid11">
<s:property />
12 years ago