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

Community Tip - Did you know you can set a signature that will be added to all your posts? Set it here! X

How to write an Info*Engine webject with multiple values for a parameter ?

BernardWielfaer
12-Amethyst

How to write an Info*Engine webject with multiple values for a parameter ?


Hi,

I like to get the result back from Info*Engine for all WTParts that are in the status RELEASED or in ENGINEERING. Can I pass multiple values for "lifecycle", how must these be separated ?

<ie:webject name="Query-Objects" type="OBJ">
   <ie:param name="INSTANCE"  data="${FORM[]instance[]}"/>
   <ie:param name="type"   data="wt.part.WTPart"/>
   <ie:param name="where"   data="lifeCycleState ='${FORM[]lifeycle[]}'"/>
   <ie:param name="where"   data="latestIteration ='true'"/>
   <ie:param name="where"   data="number='${FORM[]number[]}'"/>
   <ie:param name="group_out"  data="queryAll"/>
</ie:webject>
<ie:webject name="Sort-Group" type="GRP">
    <ie:param name="GROUP_IN"          data="queryAll"/>
    <ie:param name="GROUP_OUT"         data="${FORM[]ename[]}"/>
    <ie:param name="SORTBY"            data="NAME"/>
    <ie:param name="SORTED"            data="ASC"/>
</ie:webject>

ACCEPTED SOLUTION

Accepted Solutions

Here is a extract from I*E documentation regarding the Where Clause:

Where Clause:

The Query-Object webject has the parameter of WHERE, which can take some specific conditions.

• All objects

– The WHERE parameter has a special syntax for returning all objects – open parenthesis and close parenthesis “()”:

<ie:webject name="Query-Objects" type="OBJ">

<ie:param name="INSTANCE" data="domaim.domainname.servername.Windchill"/>

<ie:param name="ATTRIBUTE" data="number,name" delim=","/>

<ie:param name="TYPE" data="wt.part.WTPart"/>

<ie:param name="WHERE" data="()"/>

<ie:param name="GROUP_OUT" data="parts"/>

</ie:webject>

• Wild card

– Both left-hand matching and right-hand matching can be used as a wild card in WHERE parameter.

<ie:paramname="WHERE" data=“name=*engine*”/>

• AND/OR

– Some conditions can be connected with ‘&’ and ‘|’.

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

<ie:param name="WHERE" data=“name=*body|name=*engine*”/>

Refer to the “Specifying the TYPE and WHERE Parameters” topic under Advanced Customization->Windchill Adapter->Using Windchill Adapter Webjects in Windchill Help

Center.


Regards,

PASI Team

View solution in original post

3 REPLIES 3

Can you try following and check if that helps

<%

string clause= "(lifeCycleState='INWORK')|(lifeCycleState='RELEASED')";

%>

<ie:webject name="Get-Properties" type="MGT">

    <ie:param name="ATTRIBUTE" data="wt.federation.ie.VMName"/>

    <ie:param name="GROUP_OUT" data="properties"/>

</ie:webject>

<ie:webject name="Search-Objects" type="OBJ">

    <ie:param name="INSTANCE" data="$(properties[0]wt.federation.ie.VMName[0])"/>

  <ie:param name="TYPE" data="wt.part.WTPart"/>

  <ie:param name="ATTRIBUTE" data="name,number,lifeCycleState" delim=","/>

    <ie:param name="WHERE" data="<%=clause%>"/>

  <ie:param name="LATEST" data="true"/>

  <ie:param name="GROUP_OUT" data="test1"/>

</ie:webject>

Regards,

Bhushan

Here is a extract from I*E documentation regarding the Where Clause:

Where Clause:

The Query-Object webject has the parameter of WHERE, which can take some specific conditions.

• All objects

– The WHERE parameter has a special syntax for returning all objects – open parenthesis and close parenthesis “()”:

<ie:webject name="Query-Objects" type="OBJ">

<ie:param name="INSTANCE" data="domaim.domainname.servername.Windchill"/>

<ie:param name="ATTRIBUTE" data="number,name" delim=","/>

<ie:param name="TYPE" data="wt.part.WTPart"/>

<ie:param name="WHERE" data="()"/>

<ie:param name="GROUP_OUT" data="parts"/>

</ie:webject>

• Wild card

– Both left-hand matching and right-hand matching can be used as a wild card in WHERE parameter.

<ie:paramname="WHERE" data=“name=*engine*”/>

• AND/OR

– Some conditions can be connected with ‘&’ and ‘|’.

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

<ie:param name="WHERE" data=“name=*body|name=*engine*”/>

Refer to the “Specifying the TYPE and WHERE Parameters” topic under Advanced Customization->Windchill Adapter->Using Windchill Adapter Webjects in Windchill Help

Center.


Regards,

PASI Team

Thank you !

Announcements


Top Tags