Focal Point Banner


As of December 1, 2020, Focal Point is retired and repurposed as a reference repository. We value the wealth of knowledge that's been shared here over the years. You'll continue to have access to this treasure trove of knowledge, for search purposes only.

Join the TIBCO Community
TIBCO Community is a collaborative space for users to share knowledge and support one another in making the best use of TIBCO products and services. There are several TIBCO WebFOCUS resources in the community.

  • From the Home page, select Predict: WebFOCUS to view articles, questions, and trending articles.
  • Select Products from the top navigation bar, scroll, and then select the TIBCO WebFOCUS product page to view product overview, articles, and discussions.
  • Request access to the private WebFOCUS User Group (login required) to network with fellow members.

Former myibi community members should have received an email on 8/3/22 to activate their user accounts to join the community. Check your Spam folder for the email. Please get in touch with us at community@tibco.com for further assistance. Reference the community FAQ to learn more about the community.


Focal Point    Focal Point Forums  Hop To Forum Categories  WebFOCUS/FOCUS Forum on Focal Point     Restricting data on a drop down list

Read-Only Read-Only Topic
Go
Search
Notify
Tools
Restricting data on a drop down list
 Login/Join
 
Member
posted
I have a fairly simple launch
page that has two dynamic list boxes on it.
Currently, they pull back
all the data in the specified column. How do
I restrict what they pull
back (ie - only where active = 1)
and how do I order the
data in the boxes?
This is the launch page code:
<TITLE>Count of Jobs Done</TITLE>
<META content="WebFocus
Report Layout Painter" name ="Generator">
<SCRIPT id=IbiOptionsScript type=text/javascript>
var cgipath = "cgipath";
var ibirls = "ibirls";
var multidrill = "multidrill";
var mntFormValidate = "mntFormValidate";
var dyncalendar = "dyncalendar";
var ibiOptions = new Array(cgipath,
ibirls,mntFormValidate,multidrill);
<SCRIPT id=nls src="/ibi_html/javaassist/nls.js" type=text/javascript>
<SCRIPT id=ibigbl src="/ibi_html/javaassist/ibi/html/js/ibigbl.js" type=text/javascript>
<SCRIPT id=ibigblloadCss type=text/javascript> ibigblloadCss(null);
<BODY onload=OnLoad() nextelementnum="15" drawgrid="1" snaptogrid="1"
gridsizeCX="10"
gridsizeCY="10"
pagesizeCX="2000" pagesizeCY="2000">
< !--startibiitems-->
<FORM onsubmit=SaveValues() method=post name ="form">
<INPUT type=hidden
value=countofjobsdone name ="IBIF_ex">
<INPUT id=IBIAPP_app type=hidden
value=docfinity name ="IBIAPP_app">
<SPAN id=ITEM1 style="Z-INDEX: 6;
LEFT: 10px; WIDTH: 80px; POSITION: absolute; TOP:70px; HEIGHT: 20px" name ="lblUser" elementname="lblUser"
elementtype="text">
<SPAN FragmentColor="0" sourcetype="typeUrl" targettype="1" FragmentStartChar="0"
FragmentEndChar="7">User ID</SPAN>
<SELECT id=ITEM2 style="Z-INDEX: 7; LEFT: 10px;
WIDTH: 150px; POSITION: absolute;
TOP: 100px; HEIGHT: 100px" multiple
size=2 name ="UserID" elementname="lstUser" elementtype="listbox" sourcetype="typeMaster"
labelid="ITEM1" caption="listbox" operation="
{AND|OR}" ibiformat datatype="1" addalloption="1" dynalldisplayvalue="ALL
="-1" chainnumber="-1"
cacheruntimedata="0" displayfield="USER_LOGIN_ID"
numofrecords="-1" datafield="USERID" datasource="SEC_USERS.mas" datafieldtype="CHAR"></SELECT>
<SPAN id=ITEM3 style="Z-INDEX: 8;
LEFT: 170px; WIDTH: 70px; POSITION: absolute; TOP: 70px; HEIGHT: 20px" name ="lblGroup" elementname="lblGroup"
elementtype="text"><SPAN FragmentColor="0"
sourcetype="typeUrl"
targettype="0" FragmentStartChar="0" FragmentEndChar="5">Group
<SELECT id=ITEM4 style="Z-INDEX: 9;
LEFT: 170px; WIDTH: 150px; POSITION:
absolute; TOP: 100px;
HEIGHT: 100px"
multiple size=2 name ="Group" elementname="lstGrp"
elementtype="listbox" s
ourcetype="typeMaster" labelid="ITEM3" caption="listbox" operation="
{AND|OR}" ibiformat
datatype="1" addalloption="1" dynalldisplayvalue="ALL"
inchainindex="-1"
chainnumber="-1" cacheruntimedata="0"
displayfield="GROUP_NAME"
numofrecords="-1" datafield="GROUPID" datasource="SEC_GROUP.mas"
datafieldtype="CHAR">
<INPUT id=ITEM5
style="Z-INDEX: 10;
LEFT: 10px; WIDTH: 80px;
POSITION: absolute; TOP: 210px; HEIGHT: 30px" type=submit value=Submit name ="btnSubmit" elementname="btnSubmit"
elementtype="button" sourcetype="typeUrl" targettype="0" targetname onclickset="0">
<INPUT id=ITEM6 style="Z-INDEX: 11; LEFT: 110px; WIDTH: 80px; POSITION:
absolute; TOP:
210px; HEIGHT: 30px" type=reset
value=Reset name ="btnReset" elementname="btnReset"
elementtype="button"
sourcetype="typeUrl" targettype="0" targetname
onclickset="0"><SPAN id=ITEM11 style="Z-INDEX: 30; LEFT: 10px; WIDTH: 60px; POSITION: absolute; TOP: 30px; HEIGHT: 20px"
name ="text11" elementname="text11"
elementtype="text">
<SPAN FragmentColor="0" sourcetype="typeUrl" targettype="0" FragmentStartChar="0" FragmentEndChar="7">
Between <SPAN id=ITEM12 style="Z-INDEX: 31; LEFT: 220px; WIDTH: 30px;
POSITION: absolute; TOP:
30px; HEIGHT: 20px"
name ="text12" elementname="text12"
elementtype="text">
<SPAN FragmentColor="0" sourcetype="typeUrl" targettype="0" FragmentStartChar="0" FragmentEndChar="3">and
<INPUT id=ITEM13 style="Z-INDEX: 37; LEFT: 70px; WIDTH: 150px; POSITION:
absolute; TOP: 30px;
HEIGHT: 22px" name ="BDate" elementname="txtBDate" elementtype="edit" labelid caption="edit"
operation="NONE" ibiformat>
<INPUT id=ITEM14 style="Z-INDEX: 38; LEFT: 250px; WIDTH: 150px; POSITION: absolute; TOP: 30px; HEIGHT: 22px" name ="EDate" elementname="txtEdate"
elementtype="edit" labelid
caption="edit" operation="NONE" ibiformat>!--endibiitems--> <SCRIPT id=OnloadHandler> function OnLoad()
< !--startibilines--> UpdateData();
< !--endibilines-->} </BODY>[/code]Thanks for any help!
-Stephanie

This message has been edited. Last edited by: <Mabel>,
 
Posts: 15 | Location: Texas | Registered: July 19, 2005Report This Post
Expert
posted Hide Post
Hi Stephanie, You could a
lways control the SELECT
instance yourself of
course by performing a
TABLE request in your
launching
fex. Something along the lines of
DEFINE FILE SEC_
GROUPOPTIONS/A100='<option value='|GROUPID||'>'
|GROUPID||'<
/option>';
TABLE FILE SEC_GROUP SUM O
PTIONS BY GROUPID NOPRINT
WHERE ACTIVE EQ 1;
ON TABLE SET HOLDLIST
PRINTONLY ON TABLE HOLD
AS SELECT1 FORMAT ALPHA END -RUN and
then in your HTML you would add
     
<SELECT id=ITEM4 style="Z-INDEX: 9; 
LEFT: 170px; WIDTH: 150px; 
POSITION: absolute; TOP:
100px; HEIGHT: 
100px" multiple size=2 name ="Group" elementname="lstGrp" 
elementtype="listbox"
sourcetype="typeMaster" 
labelid="ITEM3" caption="listbox" operation="{AND|OR}" 
ibiformat datatype="1" 
addalloption="1" 
dynalldisplayvalue="ALL" 
inchainindex="-1" chainnumber="-1"      cacheruntimedata="0" 
displayfield="GROUP_NAME" numofrecords="-1" 
datafield="GROUPID"      datasource="SEC_GROUP.mas" datafieldtype="CHAR">!IBI.
FIL.SELECT1;</SELECT> 
Please note
that I haven't tested this
(I don't have your master and data etc.)
but I have proved it against
the CAR file of course Smiler Good luck

This message has been edited. Last edited by: <Mabel>,
 
Posts: 5694 | Location: United Kingdom | Registered: April 08, 2004Report This Post
Expert
posted Hide Post
One other alternative is, of course, to create a view (depending upon your datasource) that covers your selection requirements, and then use that as the "datasource" attribute in the SELECT tag within your launch page.
 
Posts: 5694 | Location: United Kingdom | Registered: April 08, 2004Report This Post
Member
posted Hide Post
Took a while to get back to this as other bugs took priority.
I tried this, but consistently receive
this error:
 
(FOC1400) SQLCODE IS 
245 
(HEX: 000000F5) XOPEN: 22018 
Microsoft OLE DB Provider 
for SQL Server: [22018] Syntax error 
convertin: g the varchar 
value '<option value=' to a column of data type int. L    (
FOC1406) SQL 
OPEN CURSOR ERROR.  : 
SEC_USERS 

I've tried retyping, restructuring and still it tells me no.
Any ideas would be much appreciated.
-Stephanie

This message has been edited. Last edited by: <Mabel>,
 
Posts: 15 | Location: Texas | Registered: July 19, 2005Report This Post
Expert
posted Hide Post
I take it that you get this when you choose an option from the combo box?

Is your 'datafieldtype' set to CHAR and it should be INTEGER?
 
Posts: 5694 | Location: United Kingdom | Registered: April 08, 2004Report This Post
Member
posted Hide Post
No, it happens on the page load. I get no data back and upon checking the source code I see the error.

I checked and the datafieldtype is set to CHAR.

-Stephanie
 
Posts: 15 | Location: Texas | Registered: July 19, 2005Report This Post
Master
posted Hide Post
Silver179, Don't know what version you are using but in 5.3 and newer you can populate the list box from a procedure (WebFOCUS procedure). in there you can add what ever if/where statements you want.
 
Posts: 865 | Registered: May 24, 2004Report This Post
Expert
posted Hide Post
Stephanie,

Where are you creating the list of options? Because the error message seems to say that MS SQL is having a problem putting the '<option value=' into an integer column.

If you would like me to look at your code the you can PM me.
 
Posts: 5694 | Location: United Kingdom | Registered: April 08, 2004Report This Post
Virtuoso
posted Hide Post
quote:
Originally posted by TexasStingray:
Silver179, Don't know what version you are using but in 5.3 and newer you can populate the list box from a procedure (WebFOCUS procedure). in there you can add what ever if/where statements you want.


I was searching for listbox population. I currently have a procedure to populate the list box, but it doesn't put in all occurances and when it does accept the field as a parameter ( a whole other issue ) the returned data is for an occurance of the selection for just previous to the one selected and the 'just previous' is not on the list because of the error in loading the list box. This is occurring using dev studio 7.1.4 against either 7.1.2 or 7.1.5

Any thoughts, this was a post from 2005.


Leah
 
Posts: 1317 | Location: Council Bluffs, IA | Registered: May 24, 2004Report This Post
  Powered by Social Strata  

Read-Only Read-Only Topic

Focal Point    Focal Point Forums  Hop To Forum Categories  WebFOCUS/FOCUS Forum on Focal Point     Restricting data on a drop down list

Copyright © 1996-2020 Information Builders