Selection screen value not assigning to the value when executed for the first time
Hi ,
Im My program at selection screen there are company code, vendor account and open items at key date(takes system date as default value).
Facing problem at open items at key date - Open key date parameter is taken from LDB - KDF.
First time when I am executing the program it is taking system date value in the selection screen variable even though I have given the different date.
This problem is only when I execute for first time or press enter without giving company code.
Can any one please help us to come out of this problem.
Regards
Sri Bhargavi
HI,
you can use the Event as AT SELECTION-SCREEN
Similar Messages
-
Scroller not appearing in the popup when opened for the second time
Hi,
I have a popup window which has three tabs A, B, and C. My tab A has BorderContainer > Scroller > Vgroup
When opened for the first time, I can see the scroller. But , when opened for the second time, the scroller does not appear and the content in th Border container seems truncated.
Please help.No answers, but I may be seeing something similar.
I'm converting a project from Flex 3 to 4. In a popup (Spark TitleWindow) I have a some TabNavigators. On subsequent openings of the popup, the contents of the navigator children don't always render. After some changing of various Halo components to their Spark equivalents, I thought the problem had gone away. But the problem seems to have come back.
In my case, I'm not sure if the "subsequent opening" is the key issue. Sometimes, the contents of nested TabNaviagtor children don't render on the first opening. although the first child content always renders. But the problem seems to increase in subsequent openings. (I.e. more children of TabNavigators don't render.)
Perhaps not connected, but I notice when this happens, the outside borders of dataGrid components don't render in components outside of TabNavigators. I suspect there's a simple thing I need to to do to fix this, but I haven't found it. Any hints or insights would be welcomed. -
Understanding the Creative Cloud Plans for a first-time photoshop user
I've never had photoshop before and I downloaded just the free 30-day trial. Then I purchased the Creative Cloud Photography plan (the one that's 9.99 a month). But I need help understanding what this offer me, because in the description this seemed to offer Photoshop and Lightroom, but I don't see an option to install those apps on my creative cloud.
If I'm a first time user do I have to buy the creative cloud complete in order to have access to Photoshop and Lightroom?Here's a screenshot of what I've got right now. The apps are just saying try, not install. Do I need to purchase the products themselves and the CC is just access to the cloud?
-
My son's iph4 (not new) won't connect when attached to pc, first time i tried it said something about mobile me not being on?
http://support.apple.com/kb/TS1538
-
Screen value not assign in field symbol
Hi gurus,
I create a field symbol for module pool programming for assigning screen value. I create a tab in main screen and three subscreen for tab. in first screen values perfectly asign in field symbol but second subscreen FS1,FS2,FS3 values not assign.
Atthe time of save three subscreen values stored in internal table, then insert into ztable.
PERFORM SAVE_DATA USING '15' 'GTAB-IO_CODE' 'GTAB-IO_PER' 'GATB-IO_VAL'.
PERFORM SAVE_DATA USING '26' 'GTAB-IO_SCODE' 'GTAB-IO_SPER' 'GTAB-IO_SVAL'.
FORM SAVE_DATA USING X TYPE I
FS1 TYPE STRING
FS2 TYPE STRING
FS3 TYPE STRING.
*FORM SAVE_DATA USING X TYPE I FS1 TYPE STRING.
CLEAR SNO.
CLEAR C.
ITAB-MANDT = SY-MANDT.
ITAB-BUKRS = '1000'.
ITAB-DOCNO = '0001000005'.
ITAB-BUDAT = SY-DATUM.
DO X TIMES.
IF X EQ '15'.
FS1 = 'GTAB-IO_CODE'.
FS2 = 'GTAB-IO_PER'.
FS3 = 'GTAB-IO_VAL'.
ELSEIF X EQ '26'.
FS1 = 'GTAB-IO_SCODE'.
FS2 = 'GTAB-IO_SPER'.
FS3 = 'GTAB-IO_SVAL'.
ENDIF.
C = C + 1.
SNO = SNO + 10.
ITAB-SLNO = SNO.
ZCOMRP_ORTRN-SLNO = SNO.
CONCATENATE FS1 C INTO FS1.
ASSIGN (FS1) TO <FS>.
ZCOMRP_ORTRN-PRCOD = <FS>.
ITAB-PRCOD = <FS>.
CONCATENATE FS2 C INTO FS2.
ASSIGN (FS2) TO <FS>.
ZCOMRP_ORTRN-KBETR = <FS>.
ITAB-KBETR = <FS>.
CONCATENATE FS3 C INTO FS3.
ASSIGN (FS3) TO <FS>.
ZCOMRP_ORTRN-DMBTR = <FS>.
ITAB-DMBTR = <FS>.
INSERT ZCOMRP_ORTRN.
APPEND ITAB.
INSERT ZCOMRP_ORTRN FROM ITAB.
CLEAR FS1.
CLEAR FS2.
CLEAR FS3.
CLEAR C.
ENDDO.
PERFORM CLEAR.
ENDFORM. " SAVE_DATAsolved
-
Selected model does not contain any target value prior
Hi ODM experts,
I have tried to apply the SVM alg in order to find anomalous records.The table source have rows like that:
uniq_rec ID NAME A1 A2 A3 A4 A5 data
577 2052956018 NAMEHDRCP8 2.27 0.4 85.46 0.01 14.54 24-JAN-13
578 1250914484 NAMEDJDRVP3 11.45 1.24 56.24 0.01 43.77 24-JAN-13
579 1968689283 NAMEDKEND12 0.000011 6.78 0.000029 0.01 0.091 24-JAN-13
580 2063389130 NAMEDNMXG14 0.000011 0.65 36.65 0.02 0.091 24-JAN-13
unq_rec is the pk, id is the id for the generic name and A1 .. A5 attributes ,data when collection occur etc
I'm trying to execute the following code:
drop table ALG_SET;
exec dbms_data_mining.drop_model('SVMODEL');
create table ALG_SET (setting_name varchar2(30), setting_value varchar2(4000));
insert into ALG_SET values ('ALGO_NAME','ALGO_SUPPORT_VECTOR_MACHINES');
insert into ALG_SET values ('PREP_AUTO','ON');
commit;
Begin
dbms_data_mining.create_model('SVMODEL', 'CLASSIFICATION', 'ODM_PAR_FIN_HIST', 'UNQ_CRT', null, 'ALG_SET');
end;
The results is the following error:ORA-40104: invalid training data for model build ( if I run the code) .If I run from graphical interface I have obtained this
error code " Selected model does not contain any target value prior"(using the similar model - SVM for anomaly detction plus the same source table )
Please advice what is missing or wrong and if possible how to bypass this issue.
Thanks in advance for support.
Best Regards,
BogdanHere is also a newer example of creating a SVM Anomaly model from ODM sample code (12.1 version but this applies to 11.2):
Rem
Rem $Header: rdbms/demo/dmsvodem.sql /main/6 2012/04/15 16:31:56 xbarr Exp $
Rem
Rem dmsvodem.sql
Rem
Rem Copyright (c) 2004, 2012, Oracle and/or its affiliates.
Rem All rights reserved.
Rem
Rem NAME
Rem dmsvodem.sql - Sample program for the DBMS_DATA_MINING package.
Rem
Rem DESCRIPTION
Rem This script creates an anomaly detection model
Rem for data analysis and outlier identification using the
Rem one-class SVM algorithm
Rem and data in the SH (Sales History)schema in the RDBMS.
Rem
Rem NOTES
Rem
Rem
Rem MODIFIED (MM/DD/YY)
Rem amozes 01/23/12 - updates for 12c
Rem xbarr 01/10/12 - add prediction_details demo
Rem ramkrish 06/14/07 - remove commit after settings
Rem ramkrish 10/25/07 - replace deprecated get_model calls with catalog
Rem queries
Rem ktaylor 07/11/05 - minor edits to comments
Rem jcjeon 01/18/05 - add column format
Rem bmilenov 10/28/04 - bmilenov_oneclass_demo
Rem bmilenov 10/25/04 - Remove dbms_output statements
Rem bmilenov 10/22/04 - Comment revision
Rem bmilenov 10/20/04 - Created
Rem
SET serveroutput ON
SET trimspool ON
SET pages 10000
SET echo ON
-- SAMPLE PROBLEM
-- Given demographics about a set of customers that are known to have
-- an affinity card, 1) find the most atypical members of this group
-- (outlier identification), 2) discover the common demographic
-- characteristics of the most typical customers with affinity card,
-- and 3) compute how typical a given new/hypothetical customer is.
-- DATA
-- The data for this sample is composed from base tables in the SH schema
-- (See Sample Schema Documentation) and presented through a view:
-- mining_data_one_class_v
-- (See dmsh.sql for view definition).
-- BUILD THE MODEL
-- Cleanup old model with the same name (if any)
BEGIN DBMS_DATA_MINING.DROP_MODEL('SVMO_SH_Clas_sample');
EXCEPTION WHEN OTHERS THEN NULL; END;
-- PREPARE DATA
-- Automatic data preparation is used.
-- SPECIFY SETTINGS
-- Cleanup old settings table (if any)
BEGIN
EXECUTE IMMEDIATE 'DROP TABLE svmo_sh_sample_settings';
EXCEPTION WHEN OTHERS THEN
NULL;
END;
-- CREATE AND POPULATE A SETTINGS TABLE
set echo off
CREATE TABLE svmo_sh_sample_settings (
setting_name VARCHAR2(30),
setting_value VARCHAR2(4000));
set echo on
BEGIN
-- Populate settings table
-- SVM needs to be selected explicitly (default classifier: Naive Bayes)
-- Examples of other possible overrides are:
-- select a different rate of outliers in the data (default 0.1)
-- (dbms_data_mining.svms_outlier_rate, ,0.05);
-- select a kernel type (default kernel: selected by the algorithm)
-- (dbms_data_mining.svms_kernel_function, dbms_data_mining.svms_linear);
-- (dbms_data_mining.svms_kernel_function, dbms_data_mining.svms_gaussian);
-- turn off active learning (enabled by default)
-- (dbms_data_mining.svms_active_learning, dbms_data_mining.svms_al_disable);
INSERT INTO svmo_sh_sample_settings (setting_name, setting_value) VALUES
(dbms_data_mining.algo_name, dbms_data_mining.algo_support_vector_machines);
INSERT INTO svmo_sh_sample_settings (setting_name, setting_value) VALUES
(dbms_data_mining.prep_auto, dbms_data_mining.prep_auto_on);
END;
-- CREATE A MODEL
-- Build a new one-class SVM Model
-- Note the NULL sprecification for target column name
BEGIN
DBMS_DATA_MINING.CREATE_MODEL(
model_name => 'SVMO_SH_Clas_sample',
mining_function => dbms_data_mining.classification,
data_table_name => 'mining_data_one_class_v',
case_id_column_name => 'cust_id',
target_column_name => NULL,
settings_table_name => 'svmo_sh_sample_settings');
END;
-- DISPLAY MODEL SETTINGS
column setting_name format a30
column setting_value format a30
SELECT setting_name, setting_value
FROM user_mining_model_settings
WHERE model_name = 'SVMO_SH_CLAS_SAMPLE'
ORDER BY setting_name; -
Attribute value 'Not Assigned'
Hi..
i have created navigational attributes for a characterstic(z_custid) in a cube.At cube level i am able to see the values for those attributes.. but when i am trying to generate a report on this at attribute columns values are not displayed.whole column i am getting values 'not assigned'.Can anyone help me on this..
MahiHii..
thnks for ur reply..please find the answers for the questions u posted.
I am able to check the data of navigational attr in infocube..
Navigational attr's are checked in the infocube..
Master data is active..
while reporting only i am not able to see my data for navigational attr's..
Mahi.. -
I am trying to load a variable on SSIS Execute SQL Task with a string value. I keep on getting an error message :-
“The type of the value being assigned to variable “User::LegacyColumns” differs from the current variable type”.
Below are the settings on my package:
Execute SQL Task Result Set –
Single Row
Variable Data Type –
String
The data to be loaded on the variable is a single row shown below:
FirstName,LastName,MiddleName,PatientType,Title
Can someone kindly help me to solve this as I’m lost for ideas.
Thanks,
MpumeleloThank you Sorna. I think I have managed to solve it. After a long search I have found a solution which advises that I should use a Foreach Loop Container. The help is on this link:
https://social.msdn.microsoft.com/Forums/en-US/f46dea91-c26b-4ffe-ab1c-ebeef57c90b6/error-0xc001f009-at-mypackage-the-type-of-the-value-being-assigned-to-variable?forum=sqlintegrationservices
Mpumelelo -
At selection screen output not responding
Hi ppl,
I've 4 selection options in my screen. however I just need user to insert only 1 of the 4 for searching. Therefore i included 4 radio buttons. when user select <i>rbf</i>, <i>sfileno</i> will activer and other 3 will be grayed out, when user select <i>rbi</i>, <i>sidnum</i> will active and other will not be active and so forth. You can see the codes below.
However, during the program running, I found out when i select <i>rbf,</i> the other select options fields - <i>sfileno</i>, <i>sidnum</i> n <i>scompsno</i> are not inactive/grayed. It is the same when I seledt the other radio button. I just seem that i receive no response from the program. What have i done wrong here. please help. TQ
SELECTION-SCREEN BEGIN OF BLOCK frm1 WITH FRAME TITLE text-t01 .
SELECT-OPTIONS : sfileno FOR zlic_masterdb-nofailpermohonan modif id f01
sidnum FOR zcustomer-idnumber modif id i01,
sconame FOR zcustomer-contactname modif id n01,
scompsno FOR zcom_compdhdr-compsno modif id c01.
PARAMETERS: rbf RADIOBUTTON GROUP g1 ,
rbi RADIOBUTTON GROUP g1,
rbn RADIOBUTTON GROUP g1,
rbc RADIOBUTTON GROUP g1.
SELECTION-SCREEN END OF BLOCK frm1.
INITIALIZATION.
sfileno = '00001'.
AT SELECTION-SCREEN OUTPUT
AT SELECTION-SCREEN OUTPUT.
LOOP AT SCREEN.
CHECK SCREEN-GROUP1 = 'f01' OR
SCREEN-GROUP1 = 'i01' OR
SCREEN-GROUP1 = 'n01' OR
SCREEN-GROUP1 = 'c01'.
IF rbf = 'X'.
IF SCREEN-GROUP1 EQ 'f01'.
SCREEN-ACTIVE = 1.
ELSEIF SCREEN-GROUP1 EQ 'i01'.
SCREEN-ACTIVE = 0.
ELSEIF SCREEN-GROUP1 EQ 'n01'.
SCREEN-ACTIVE = 0.
ELSEIF SCREEN-GROUP1 EQ 'c01'.
SCREEN-ACTIVE = 0.
ENDIF.
ELSEIF rbi = 'X'.
IF SCREEN-GROUP1 EQ 'i01'.
SCREEN-ACTIVE = 1.
ELSEIF SCREEN-GROUP1 EQ 'f01'.
SCREEN-ACTIVE = 0.
ELSEIF SCREEN-GROUP1 EQ 'n01'.
SCREEN-ACTIVE = 0.
ELSEIF SCREEN-GROUP1 EQ 'c01'.
SCREEN-ACTIVE = 0.
ENDIF.
ELSEIF rbn = 'X'.
IF SCREEN-GROUP1 EQ 'n01'.
SCREEN-ACTIVE = 1.
ELSEIF SCREEN-GROUP1 EQ 'f01'.
SCREEN-ACTIVE = 0.
ELSEIF SCREEN-GROUP1 EQ 'i01'.
SCREEN-ACTIVE = 0.
ELSEIF SCREEN-GROUP1 EQ 'c01'.
SCREEN-ACTIVE = 0.
ENDIF.
ELSEIF rbc = 'X'.
IF SCREEN-GROUP1 EQ 'c01'.
SCREEN-ACTIVE = 1.
ELSEIF SCREEN-GROUP1 EQ 'f01'.
SCREEN-ACTIVE = 0.
ELSEIF SCREEN-GROUP1 EQ 'n01'.
SCREEN-ACTIVE = 0.
ELSEIF SCREEN-GROUP1 EQ 'i01'.
SCREEN-ACTIVE = 0.
ENDIF.
ENDIF.
MODIFY SCREEN.
continue.
ENDLOOP.hi Enzo
Check my sample code
TABLES: eban,
SSCRFIELDS.
SELECTION-SCREEN BEGIN OF SCREEN 100 TITLE title.
SELECTION-SCREEN BEGIN OF BLOCK b1 WITH FRAME TITLE text-t01.
PARAMETER:rad1 RADIOBUTTON GROUP rad USER-COMMAND frad1 DEFAULT 'X',
rad2 RADIOBUTTON GROUP rad .
SELECTION-SCREEN END OF BLOCK b1.
SELECTION-SCREEN BEGIN OF BLOCK b2 WITH FRAME TITLE text-t02.
PARAMETER: mtr AS CHECKBOX MODIF ID g3 USER-COMMAND chk1,
p_matnr TYPE eban-matnr MODIF ID g1,
sloc AS CHECKBOX MODIF ID g3 USER-COMMAND chk2,
str_loc TYPE eban-lgort MODIF ID g4.
SELECTION-SCREEN END OF BLOCK b2.
SELECTION-SCREEN BEGIN OF BLOCK b3 WITH FRAME TITLE text-t03.
SELECT-OPTIONS: matnr1 FOR eban-matnr MODIF ID g2.
SELECTION-SCREEN END OF BLOCK b3.
SELECTION-SCREEN PUSHBUTTON /20(10) name USER-COMMAND UCOM.
SELECTION-SCREEN END OF SCREEN 100.
name = 'FETCH'.
title = 'Test Report'.
CALL SELECTION-SCREEN '100'.
TYPE-POOLS slis.
* declaration of internal tables and work areas to be used
DATA: BEGIN OF it_pr OCCURS 0,
banfn TYPE eban-banfn,
bnfpo TYPE eban-bnfpo,
loekz TYPE eban-loekz,
statu TYPE eban-statu,
ekgrp TYPE eban-ekgrp,
matnr TYPE eban-matnr,
werks TYPE eban-werks,
lgort TYPE eban-lgort,
preis TYPE eban-preis,
peinh TYPE eban-peinh,
END OF it_pr.
DATA: BEGIN OF it_mat OCCURS 0,
matnr TYPE eban-matnr,
END OF it_mat.
*DATA:BEGIN OF ITAB1 OCCURS 0,
DATA: l_answer.
DATA: it_fieldcat TYPE slis_t_fieldcat_alv,
wa_fieldcat LIKE LINE OF it_fieldcat,
it_event TYPE slis_t_event,
wa_event TYPE slis_alv_event.
* declaration of variables to be used
DATA: r_ucomm TYPE sy-ucomm,
mat_no TYPE eban-matnr,
len TYPE i VALUE 1,
count TYPE i VALUE IS INITIAL,
iflag TYPE i VALUE IS INITIAL,
iflag1 TYPE i VALUE 0.
DATA :pr_id TYPE sy-repid,
rt_extab TYPE slis_t_extab.
INITIALIZATION.
pr_id = sy-repid.
probably it would sol;ve ur problem
regards
ravish
<b>plz dont forget to reward points if helpful</b> -
Hi,
Im trying to create a Rest WS with a @GET method that will return me an Emp object. I need the output as a JSON string.
I have created a dynamic web project and added javax RS jars:
When im trying to run this, i'm getting the below mentioned error:
FlushResultHa E org.apache.wink.server.internal.handlers.FlushResultHandler handleResponse The system could not find a javax.ws.rs.ext.MessageBodyWriter or a DataSourceProvider class for the com.rest.assignment.EmpBean type and application/json mediaType. Ensure that a javax.ws.rs.ext.MessageBodyWriter exists in the JAX-RS application for the type and media type specified.
RequestProces I org.apache.wink.server.internal.RequestProcessor logException The following error occurred during the invocation of the handlers chain: WebApplicationException (500 - Internal Server Error)
Please help as im stuck with this from long.
Thanks in advance.
Below is the code for my service class:
package com.rest.assignment;
import java.io.FileInputStream;
import java.io.FileNotFoundException;
import java.io.IOException;
import java.util.Enumeration;
import java.util.HashSet;
import java.util.Properties;
import java.util.Set;
import javax.ws.rs.GET;
import javax.ws.rs.Path;
import javax.ws.rs.Produces;
import javax.ws.rs.core.Application;
import javax.ws.rs.core.MediaType;
import javax.ws.rs.core.Response;
@Path("/restService")
public class RestService extends Application {
@GET
@Path("/getEmpDetails")
@Produces(MediaType.APPLICATION_JSON)
public Response getStringResponse()
EmpBean empBean = new EmpBean();
String filePath = "C:/Program Files/IBM/workspace/HelloWorld/src/com/rest/resources/EmpData.properties";
Properties properties = new Properties();
try {
properties.load(new FileInputStream(filePath));
} catch (FileNotFoundException e) {
e.printStackTrace();
} catch (IOException e) {
e.printStackTrace();
Enumeration e = properties.propertyNames();
String result="";
String[] empDetailsArr;
while (e.hasMoreElements()) {
String key = (String) e.nextElement();
String empDetails = properties.getProperty(key);
empDetailsArr=empDetails.split(",");
empBean.setFirstName(empDetailsArr[0]);
empBean.setLastName(empDetailsArr[1]);
empBean.setEmpId(empDetailsArr[2]);
empBean.setDesignation(empDetailsArr[3]);
empBean.setSkillSet(empDetailsArr[4]);
result = empDetailsArr[1];
//return empBean;
return Response.ok(empBean).type(MediaType.APPLICATION_JSON_TYPE).build();
@Override
public Set<Class<?>> getClasses() {
Set<Class<?>> classes = new HashSet<Class<?>>();
classes.add(RestService.class);
classes.add(EmpBean.class);
return classes;
and my empBean goes like this:
package com.rest.assignment;
public class EmpBean {
private String firstName;
private String lastName;
private String empId;
private String designation;
private String skillSet;
public String getFirstName() {
return firstName;
public void setFirstName(String firstName) {
this.firstName = firstName;
public String getLastName() {
return lastName;
public void setLastName(String lastName) {
this.lastName = lastName;
public String getEmpId() {
return empId;
public void setEmpId(String empId) {
this.empId = empId;
public String getDesignation() {
return designation;
public void setDesignation(String designation) {
this.designation = designation;
public String getSkillSet() {
return skillSet;
public void setSkillSet(String skillSet) {
this.skillSet = skillSet;
Web.xml goes like this:
<?xml version="1.0" encoding="UTF-8"?>
<web-app id="WebApp_ID" version="3.0" xmlns="http://java.sun.com/xml/ns/javaee" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://java.sun.com/xml/ns/javaee http://java.sun.com/xml/ns/javaee/web-app_3_0.xsd">
<display-name>restWS</display-name>
<welcome-file-list>
<welcome-file>index.html</welcome-file>
<welcome-file>index.htm</welcome-file>
<welcome-file>index.jsp</welcome-file>
<welcome-file>default.html</welcome-file>
<welcome-file>default.htm</welcome-file>
<welcome-file>default.jsp</welcome-file>
</welcome-file-list>
<servlet>
<servlet-name>REST</servlet-name>
<servlet-class>com.ibm.websphere.jaxrs.server.IBMRestServlet</servlet-class>
<init-param>
<param-name>javax.ws.rs.Application</param-name>
<param-value>com.rest.assignment.RestService</param-value>
</init-param>
<load-on-startup>1</load-on-startup>
</servlet>
<servlet-mapping>
<servlet-name>REST</servlet-name>
<url-pattern>/rest/*</url-pattern>
</servlet-mapping>
</web-app>
When i try to return a string from my get method, it gives me a proper response. i get this exception when im trying to return a JSON response.Hi,
Im trying to create a Rest WS with a @GET method that will return me an Emp object. I need the output as a JSON string.
I have created a dynamic web project and added javax RS jars:
When im trying to run this, i'm getting the below mentioned error:
FlushResultHa E org.apache.wink.server.internal.handlers.FlushResultHandler handleResponse The system could not find a javax.ws.rs.ext.MessageBodyWriter or a DataSourceProvider class for the com.rest.assignment.EmpBean type and application/json mediaType. Ensure that a javax.ws.rs.ext.MessageBodyWriter exists in the JAX-RS application for the type and media type specified.
RequestProces I org.apache.wink.server.internal.RequestProcessor logException The following error occurred during the invocation of the handlers chain: WebApplicationException (500 - Internal Server Error)
Please help as im stuck with this from long.
Thanks in advance.
Below is the code for my service class:
package com.rest.assignment;
import java.io.FileInputStream;
import java.io.FileNotFoundException;
import java.io.IOException;
import java.util.Enumeration;
import java.util.HashSet;
import java.util.Properties;
import java.util.Set;
import javax.ws.rs.GET;
import javax.ws.rs.Path;
import javax.ws.rs.Produces;
import javax.ws.rs.core.Application;
import javax.ws.rs.core.MediaType;
import javax.ws.rs.core.Response;
@Path("/restService")
public class RestService extends Application {
@GET
@Path("/getEmpDetails")
@Produces(MediaType.APPLICATION_JSON)
public Response getStringResponse()
EmpBean empBean = new EmpBean();
String filePath = "C:/Program Files/IBM/workspace/HelloWorld/src/com/rest/resources/EmpData.properties";
Properties properties = new Properties();
try {
properties.load(new FileInputStream(filePath));
} catch (FileNotFoundException e) {
e.printStackTrace();
} catch (IOException e) {
e.printStackTrace();
Enumeration e = properties.propertyNames();
String result="";
String[] empDetailsArr;
while (e.hasMoreElements()) {
String key = (String) e.nextElement();
String empDetails = properties.getProperty(key);
empDetailsArr=empDetails.split(",");
empBean.setFirstName(empDetailsArr[0]);
empBean.setLastName(empDetailsArr[1]);
empBean.setEmpId(empDetailsArr[2]);
empBean.setDesignation(empDetailsArr[3]);
empBean.setSkillSet(empDetailsArr[4]);
result = empDetailsArr[1];
//return empBean;
return Response.ok(empBean).type(MediaType.APPLICATION_JSON_TYPE).build();
@Override
public Set<Class<?>> getClasses() {
Set<Class<?>> classes = new HashSet<Class<?>>();
classes.add(RestService.class);
classes.add(EmpBean.class);
return classes;
and my empBean goes like this:
package com.rest.assignment;
public class EmpBean {
private String firstName;
private String lastName;
private String empId;
private String designation;
private String skillSet;
public String getFirstName() {
return firstName;
public void setFirstName(String firstName) {
this.firstName = firstName;
public String getLastName() {
return lastName;
public void setLastName(String lastName) {
this.lastName = lastName;
public String getEmpId() {
return empId;
public void setEmpId(String empId) {
this.empId = empId;
public String getDesignation() {
return designation;
public void setDesignation(String designation) {
this.designation = designation;
public String getSkillSet() {
return skillSet;
public void setSkillSet(String skillSet) {
this.skillSet = skillSet;
Web.xml goes like this:
<?xml version="1.0" encoding="UTF-8"?>
<web-app id="WebApp_ID" version="3.0" xmlns="http://java.sun.com/xml/ns/javaee" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://java.sun.com/xml/ns/javaee http://java.sun.com/xml/ns/javaee/web-app_3_0.xsd">
<display-name>restWS</display-name>
<welcome-file-list>
<welcome-file>index.html</welcome-file>
<welcome-file>index.htm</welcome-file>
<welcome-file>index.jsp</welcome-file>
<welcome-file>default.html</welcome-file>
<welcome-file>default.htm</welcome-file>
<welcome-file>default.jsp</welcome-file>
</welcome-file-list>
<servlet>
<servlet-name>REST</servlet-name>
<servlet-class>com.ibm.websphere.jaxrs.server.IBMRestServlet</servlet-class>
<init-param>
<param-name>javax.ws.rs.Application</param-name>
<param-value>com.rest.assignment.RestService</param-value>
</init-param>
<load-on-startup>1</load-on-startup>
</servlet>
<servlet-mapping>
<servlet-name>REST</servlet-name>
<url-pattern>/rest/*</url-pattern>
</servlet-mapping>
</web-app>
When i try to return a string from my get method, it gives me a proper response. i get this exception when im trying to return a JSON response. -
Value not found in allowed list of options for field...
Hi,
I'm using RIDC on UCM 11g in order to checkin contents.
UCM hosts different projects.
I've the following problem: if somebody (from a different project) insert a new Information Field (e.g. xAnnoPubblicazione) of type Integer - Option List - Select List Validated and it does not make a default value for this field, when I perform checkin using RIDC, it fails with the error:
"oracle.stellent.ridc.protocol.ServiceException: Content item 'UCMRE010132' was not successfully checked in. Value not found in allowed list of options for field 'xAnnoPubblicazione'.
How can I solve this issue? what's the recommended way?
Thank you very much.
Best regards,
S.In the database language, you have created a NON NULL column and you are trying to insert a record with NULL value to the column. Of course, it cannot work.
There are three options:
- do not declare the field as NON NULL (that is, you option list has to contain 'blank' as a possible value)
- provide the value on insert
- provide the default value -
AT SELECTION-SCREEN OUTPUT not working!
Hi,
I am useing the statement AT SELECTION-SCREEN OUTPUT to disable some input fields based on a check box(PR_FILE).however when I execute the program the changes on the screen are not reflected!I have written the AT SELECTION-SCREEN OUTPUT stmt immediately after SELECTION-SCREEN stmt .
Defination for the screen elements is as follows:
SELECT-OPTIONS s_plants FOR ls_selected_plant-plant
NO INTERVALS.
SELECTION-SCREEN BEGIN OF BLOCK filesel WITH FRAME TITLE text-012.
PARAMETERS pr_file TYPE xfeld .
PARAMETER : pr_path LIKE rlgrap-filename .
SELECTION-SCREEN END OF BLOCK filesel.
AT SELECTION-SCREEN OUTPUT.
IF pr_file = 'X'.
LOOP AT SCREEN.
IF screen-name = 's_plants'.
screen-input = '0'.
MODIFY SCREEN.
ENDIF.
ENDLOOP.
ELSE.
LOOP AT SCREEN.
IF screen-name = 'pr_path'.
screen-input = '0'.
MODIFY SCREEN.
ENDIF.
ENDLOOP.
ENDIF.
Can anybody suggest what wrong i have done??You need to use the User Command for the checkbox and the Modificaiton ID (Group) for the fields.
Try like this:
TABLES: VBRP.
SELECT-OPTIONS S_PLANTS FOR VBRP-WERKS NO INTERVALS MODIF ID GP1.
SELECTION-SCREEN BEGIN OF BLOCK FILESEL WITH FRAME TITLE TEXT-012.
PARAMETERS PR_FILE TYPE XFELD USER-COMMAND USR1.
PARAMETER : PR_PATH LIKE RLGRAP-FILENAME MODIF ID GP2 .
SELECTION-SCREEN END OF BLOCK FILESEL.
AT SELECTION-SCREEN OUTPUT.
IF PR_FILE = 'X'.
LOOP AT SCREEN.
if screen-group1 = 'GP1'.
SCREEN-active = '0'.
MODIFY SCREEN.
ENDIF.
ENDLOOP.
ELSE.
LOOP AT SCREEN.
IF SCREEN-group1 = 'GP2'.
SCREEN-active = '0'.
MODIFY SCREEN.
ENDIF.
ENDLOOP.
ENDIF.
Regards,
Naimesh Patel -
Selection Screen is not visible when i run tcode S_ALR_87013611
Hello all,
whenever i run T-code S_ALR_87013611.The report is directly executed . it does not stop at selection screen as i want to change the parameters in the screen.but the selection screen is not coming. as the report is generated on the basis of previous data selected.
Please let me know is there any user setting through which this setting can be changed.
Thanks
NaveenAre you using Webgui / portal or SAPgui
Regards
Subodh -
Selection Screen seems not to be transported, all transport log OK
hi,
our ABAP build own Z-program in SDV. After that, they transport the program to QA client using STMS and also to Production Client using the same method. All the transport log is error-free.
The problem occurs in PRD, when all selection screen declared on SE38 didn't appear when program is executed. But, when this program is executed in DEV client or QA client, all selection screen appear
correctly as declared in SE38.
In some case, all selection screen is appears correctly if the program is run on some of our application server, but didn't appear on the other application server.
is there something we missed ? or there is a problem in our STMS, or SE38 ?
thank youI guess if the latest request is in the PRD, it takes along with it the changes related to all previous requests.
If the object is in Request R1 and R1 is released but not transported.
Now the object is again edited and saved in R2.
R2 is transported. The changes done in R1 although its not sent to PRD, will come in the request R2.
But just check if all the previous versions are in PRD.
There could be a unrectified problem sometimes which may appear.
If you are sure all is fine, just create a Transport of Copies of the request and retransport it.
Also dont forget to check the syntax and consistency of the request.
It had happened with me that I had transoported the request with inactive object to PRD and I was in big trouble
good luck
reagrds -
Query Selection Screen does not appear in Web Analyzer
Hi Experts,
Query Selection Screen appears when we open the query in Bex Analayzer in production system. But when we open the query in ABAP or JAVA Web view, the selection screen does not appears.
As the volume of data in the cube is very high, and since the selection screen is not appearing, the query extracts 1.5Mrecords and results in dump.
Kindly let me know the possibility for selection screen not appearing.
Note: The selection screen appear in Development system in Bex Analyzer, ABAP View and Java View
Regards
Suresh KumarDear Suresh,
You can check if the parameter &VARIABLE_SCREEN=X is added to standard template or not, If not add this,
In order to add this parameter in the webtemplate you have to change 0ANALYSIS_PATTERN and save it as ZANALYSIS_PATTERN and enter this standard web template under TCODE RSCUSTV27.
Also I would like to explain you the behavior of Web Analyzer,
Parameter VARIABLE_SCREEN=X only influences the WEB application at startup. This will not come into affect
when you use the 'New Analysis' button. The 'New Analysis' button resets the dataprovider so this would not
affect the variable screen and would not redisplay the variable screen as you require.
Regards,
Arvind
Maybe you are looking for
-
Change the Pricing Type during billing
We are facing an issue with the rebate conditions which needs to be resolved asap.. User has created a credit memo request in VA01. Credit memo request is created for the change in the Price. (Note: Order reason for such specific credit memo requests
-
Strange folders in my Preferences
Hi All, Since I got this iMac a few weeks ago I've been seeing several wierdly named folders appearing in my Users/Library/Preferences folder. It seems like the number of them grows each time I use the Mac. When I click on them nothing happens, that
-
Version of Application Server for Oracle E-Business suite 12.0.4 ?
Hi , I want to know the complete version of Application Server for Oracle E-Business suite 12.0.4 . The installation guide/ rapid install mention this : A) Oracle database 10.2.0.3 B)Applications Server : 10.1.3 oc4j C) Application Server : 10.1.2.2
-
I have used NetworkInterface.getNetworkInterfaces() for get list of interfaces but under xp I not read interface informations. Is possible that the problem is permission level of user? Thanks.
-
Hierarchy as Flat Structure through BEx Web
Hello Gurus I want to display a hierarchy as a flat table on the web. I want to see KFs against lowest level nodes, the higher level nodes are included soley to give context. So if my hierarchy is: L1 = A L2 = B L3 = C and my KFs are 1, 2, 3. I want