cancel
Showing results for 
Search instead for 
Did you mean: 
cancel
Showing results for 
Search instead for 
Did you mean: 

Community Tip - If community subscription notifications are filling up your inbox you can set up a daily digest and get all your notifications in a single email. X

webject with where and &

FeofilovIvan
7-Bedrock

webject with where and &

Hello!

I whant execute webject with WHERE param which use &. But them doesnt work.

Anybody know why?


<%@page language="java"%>
<%@page import="wt.util.*"%>
<%@page import="wt.util.*, java.io.*"%>
<%@taglib uri="http://www.ptc.com/infoengine/taglib/core" prefix="ie"%>
<%
WTProperties wtprops = WTProperties.getLocalProperties();
String wtInstance = wtprops.getProperty("wt.federation.ie.VMName");
%>


<ie:webject name="Query-Master" type="OBJ">
<ie:param name="INSTANCE" data="&lt;%=wtInstance" %=">"/>
<ie:param name="TYPE" data="wt.part.WTPart"/">

<ie:param name="WHERE" data="name=*body" &=" name!="*engine*"/>

<ie:param name="GROUP_OUT" data="PARTS"/">
</ie:webject>

Err msg:


- <wc:collection xmlns:wc="http://www.ptc.com/infoengine/1.0">
- <exception name="exception" type="Exception" status="-1">
<wc:message>Unbalanced quotes for data in line 13 of file://D:\ptc\Windchill_9.0\Windchill\tasks/ext/test/queryProducts.xml</wc:message>
- <wc:instance>
<hierarchy>com.infoengine.exception.fatal.IESyntaxException</hierarchy>
<hierarchy>com.infoengine.exception.fatal.IEFatalServiceException</hierarchy>
<hierarchy>com.infoengine.exception.fatal.IEFatalException</hierarchy>
<hierarchy>com.infoengine.util.IEException</hierarchy>
<hierarchy>javax.servlet.jsp.JspException</hierarchy>
<hierarchy>java.lang.Exception</hierarchy>
<hierarchy>java.lang.Throwable</hierarchy>
<hierarchy>java.lang.Object</hierarchy>
</wc:instance>
</exception>
</wc:collection>


4 REPLIES 4

This should work !

<ie:param name="WHERE" data="name=*body"/>
<ie:param name="WHERE" data="name!=*engine*"/>

Regards,

Murugesh

You need to use & amp; to allow webject code to parse properly. Note I put a space between & and amp; so it wouldn't render it in html mail format and you could see my answer. It's a obvious problem that isn't always so obvious.

Dave


Sent from my Verizon Wireless BlackBerry

Thanks,

<ie:param name="WHERE" data="name=*body"/>
<ie:param name="WHERE" data="name!=*engine*"/>
work fine.

I think that when webject compile to java class all params put into map, and result of

map.put("WHERE","name=*body");

map.put("WHERE","name!=*engine*");

map contain 1 element.

But when I decompile webject class? i find that all params puts into list as new object, and that code work.

code: & doesnt work, I don't know why.


Windchill customizer

You can also have multiple WHERE clauses with a single where in each


Announcements


Top Tags