Duplicate fields in af:query search
Hi Experts,
I am using af:query, in order to search record from database.
For example,Consider I am having three fields to search in basic(Employee Id, Employee Name,Gender ).
In the advanced mode, if i add another field 'Salary', it will be added. If I hit to add 'Salary' again, it added below the 'Salary' again.
Simply, it allows me to add a single filed multiple times again and again. How can I restirct this.
I am using Jdeveloper 11.1.1.5.0
-Thanks
The af:query is based on a View Criteria from a PVO, so i wrote the following code to set the value for the criteria items in the View criteria.
I wrote it in view object's getter in the AMImpl.java
public ResourcePickerVOImpl getResourcePicker(){
ResourcePickerVOImpl vo = findViewObject("ResourcesPicker");
ViewCriteria vc = (ViewCriteria)vo.getViewCriteria("ResourcePickerSearch");
ViewCriteriaManager vm = vc.getViewCriteriaManager();
Row rows[] = vc.getAllRowsInRange();
for(Row row : rows){
List<ViewCriteriaItem> cit = ((ViewCriteriaRow)row).getCriteriaItems();
Iterator<ViewCriteriaItem> itr = cit.iterator();
while(itr.hasNext()){
ViewCriteriaItem vtr = itr.next();
vtr.setValue("Mathew");
System.out.println("Column name: " + vtr.getColumnName() + " Value: " + vtr.getValue());
I changed the contextDelivery = immediate and childrenCreation = immediate since the popup was always showing empty search fields.
After changing this property i am seeing a new issue -> First time when i open the popup nothing is shown in the search fields. Then from the subsequent times it is showing the values defaulted through the above code.
Any idea!
Edited by: [email protected] on Aug 26, 2010 4:30 AM
Similar Messages
-
Defaulting search fields in af:query component
I have a search popup with af:query and a result table. My requirement is to default some of the fields in af:query when the popup launches.
Since i could not achieve this, i wrote a temporary work around which should be removed as soon as we find a permanent solution.
Work around:
1. Wrote a method showQBE() in the bean. Wrote the logic to default the QBE fields by manually iterating through the component binding.
2. Call showQBE() in the visible property of the af:query so that this executed when the popup is invoked.
public boolean showQBE(){
RichQuery rq = this.getResourcePickerQBE(); // Bindning for QBE
QueryDescriptor dq = rq.getValue();
List children = rq.getChildren();
Iterator childrenItr = children.iterator();
while (childrenItr.hasNext()) {
RichPanelGroupLayout rpcl = (RichPanelGroupLayout)childrenItr.next();
Iterator rpclItr = rpcl.getChildren().iterator();
while (rpclItr.hasNext()) {
// RichPanelLabelAndMessage
UIComponent rplm = (UIComponent)rpclItr.next();
Iterator rplmItr = rplm.getChildren().iterator();
while (rplmItr.hasNext()) {
UIComponent comp = (UIComponent)rplmItr.next();
Iterator compItr = comp.getChildren().iterator();
while (compItr.hasNext()) {
UIComponent comp1 = (UIComponent)compItr.next();
String class2 = comp1.getClass().getSimpleName();
if (class2.equals("RichInputText")) {
RichInputText rit = (RichInputText)comp1;
if ("value40".equals(rit.getId()) ||
"value41".equals(rit.getId())) {
rit.setValue("Bryan");
} else if ("value50".equals(rit.getId()) ||
"value51".equals(rit.getId())) {
rit.setValue(ADFUtil.evaluateEL("Adams"));
} else
rit.setValue("");
AdfFacesContext.getCurrentInstance().addPartialTarget(rit);
Popup code:
<af:popup id="resourceSearch1"
popupFetchListener="#{backingBeanScope.TerritoryProfileBean.showParentTerrOwnerReportsForTerrTeamMember}"
binding="#{backingBeanScope.TerritoryProfileBean.resourcePickerPopup}"
popupCanceledListener="#{backingBeanScope.TerritoryProfileBean.cancelButtonListener}"
contentDelivery="lazyUncached" childCreation="deferred">
<af:dialog id="d20" type="none" title="#{salesterrmgmtterritoriesuiGenBundle}">
<af:panelGroupLayout id="pgl191" layout="vertical">
<af:panelHeader id="ph21" text=" ">
<af:query id="qryId2" headerText="#{applcoreBundle.QUERY_SEARCH_HEADER_TEXT}" disclosed="true"
value="#{bindings.ResourcePickerSearchQuery.queryDescriptor}"
model="#{bindings.ResourcePickerSearchQuery.queryModel}"
queryListener="#{backingBeanScope.TerritoryProfileBean.onSearchBtn}"
saveQueryMode="hidden" resultComponentId="::t3"
binding="#{backingBeanScope.TerritoryProfileBean.resourcePickerQBE}"
visible ="#{backingBeanScope.TerritoryProfileBean.showQBE}"
queryOperationListener="#{backingBeanScope.TerritoryProfileBean.queryOperationListener}"/>
</af:panelHeader>
<af:panelStretchLayout id="psl2" startWidth="50px"
visible="#{backingBeanScope.TerritoryProfileBean.showSearchTable}">
<f:facet name="bottom"/>
<f:facet name="center">
<af:table value="#{bindings.ResourcesPicker.collectionModel}"
var="row"
rows="#{bindings.ResourcesPicker.rangeSize}"
emptyText="#{bindings.ResourcesPicker.viewable ? applcoreBundle.TABLE_EMPTY_TEXT_NO_ROWS_YET : applcoreBundle.TABLE_EMPTY_TEXT_ACCESS_DENIED}"
fetchSize="#{bindings.ResourcesPicker.rangeSize}"
rowBandingInterval="0"
selectionListener="#{bindings.ResourcesPicker.collectionModel.makeCurrent}"
rowSelection="multiple" id="t3"
binding="#{backingBeanScope.TerritoryProfileBean.resourcePickerTable}"
contentDelivery="immediate"
columnSelection="multiple" autoHeightRows="10"
summary="#{salesterrmgmtterritoriesuiBundle.THIS_TABLE_LISTS_THE_RESOURCES}">
<af:column sortProperty="ResourceName" sortable="true"
headerText="#{bindings.ResourcesPicker.hints.ResourceName.label}"
id="c3" rowHeader="unstyled">
<af:inputText value="#{row.bindings.ResourceName.inputValue}"
label="#{bindings.ResourcesPicker.hints.ResourceName.label}"
required="#{bindings.ResourcesPicker.hints.ResourceName.mandatory}"
columns="#{bindings.ResourcesPicker.hints.ResourceName.displayWidth}"
maximumLength="#{bindings.ResourcesPicker.hints.ResourceName.precision}"
shortDesc="#{bindings.ResourcesPicker.hints.ResourceName.tooltip}"
id="it6">
<f:validator binding="#{row.bindings.ResourceName.validator}"/>
</af:inputText>
</af:column>
<af:column sortProperty="PrimaryPhoneNumber" sortable="true"
headerText="#{bindings.ResourcesPicker.hints.PrimaryPhoneNumber.label}"
id="c6">
<af:inputText value="#{row.bindings.PrimaryPhoneNumber.inputValue}"
label="#{bindings.ResourcesPicker.hints.PrimaryPhoneNumber.label}"
required="#{bindings.ResourcesPicker.hints.PrimaryPhoneNumber.mandatory}"
columns="#{bindings.ResourcesPicker.hints.PrimaryPhoneNumber.displayWidth}"
maximumLength="#{bindings.ResourcesPicker.hints.PrimaryPhoneNumber.precision}"
shortDesc="#{bindings.ResourcesPicker.hints.PrimaryPhoneNumber.tooltip}"
id="it10">
<f:validator binding="#{row.bindings.PrimaryPhoneNumber.validator}"/>
</af:inputText>
</af:column>
<af:column sortProperty="EmailAddress" sortable="true"
headerText="#{bindings.ResourcesPicker.hints.EmailAddress.label}"
id="c5">
<af:inputText value="#{row.bindings.EmailAddress.inputValue}"
label="#{bindings.ResourcesPicker.hints.EmailAddress.label}"
required="#{bindings.ResourcesPicker.hints.EmailAddress.mandatory}"
columns="#{bindings.ResourcesPicker.hints.EmailAddress.displayWidth}"
maximumLength="#{bindings.ResourcesPicker.hints.EmailAddress.precision}"
shortDesc="#{bindings.ResourcesPicker.hints.EmailAddress.tooltip}"
id="it1">
<f:validator binding="#{row.bindings.EmailAddress.validator}"/>
</af:inputText>
</af:column>
</af:table>
</f:facet>
</af:panelStretchLayout>
</af:panelGroupLayout>
<f:facet name="buttonBar">
<af:group id="g41">
<af:commandButton actionListener="#{backingBeanScope.TerritoryProfileBean.onApplyOrDoneFromResourcePicker}"
id="cmdDone1" immediate="true"
partialSubmit="true"
text="#{acrGenBundle}">
<af:resetActionListener/>
</af:commandButton>
<af:commandButton id="cb5" actionListener="#{backingBeanScope.TerritoryProfileBean.cancelButtonListener}"
text="#{acrGenBundle}"/>
</af:group>
</f:facet>
</af:dialog>
</af:popup>
* I created the same thread ADFbc forum: http://myforums.oracle.com/jive3/thread.jspa?threadID=632625. Since there is no response posting here.
ThanksThe af:query is based on a View Criteria from a PVO, so i wrote the following code to set the value for the criteria items in the View criteria.
I wrote it in view object's getter in the AMImpl.java
public ResourcePickerVOImpl getResourcePicker(){
ResourcePickerVOImpl vo = findViewObject("ResourcesPicker");
ViewCriteria vc = (ViewCriteria)vo.getViewCriteria("ResourcePickerSearch");
ViewCriteriaManager vm = vc.getViewCriteriaManager();
Row rows[] = vc.getAllRowsInRange();
for(Row row : rows){
List<ViewCriteriaItem> cit = ((ViewCriteriaRow)row).getCriteriaItems();
Iterator<ViewCriteriaItem> itr = cit.iterator();
while(itr.hasNext()){
ViewCriteriaItem vtr = itr.next();
vtr.setValue("Mathew");
System.out.println("Column name: " + vtr.getColumnName() + " Value: " + vtr.getValue());
I changed the contextDelivery = immediate and childrenCreation = immediate since the popup was always showing empty search fields.
After changing this property i am seeing a new issue -> First time when i open the popup nothing is shown in the search fields. Then from the subsequent times it is showing the values defaulted through the above code.
Any idea!
Edited by: [email protected] on Aug 26, 2010 4:30 AM -
Creating search help for a field in AdHoc Query
Hi
We have created an infoset based on LDB PCH.
(The infoset contains object type O only).
For the object-id field the users want search help when choosing this field for selection.
Using "start via selection screen" does not give a good solution.
Can anyone explain how I can create search help for fields in an infoset?
Regards
KirstenHi
We have created an infoset based on LDB PCH.
(The infoset contains object type O only).
For the object-id field the users want search help when choosing this field for selection.
Using "start via selection screen" does not give a good solution.
Can anyone explain how I can create search help for fields in an infoset?
Regards
Kirsten -
Format issue for Number field in af:query. Is it an ADF Bug?
Hi OTN,
Requirement : Format DepartmentId in query panel
I have created a view criteria from Employees table (HR Schema). I have four view criteria items called EmployeeId, DepartmentId, Firstname, LastName and all the items having validation property as Selectively Required. DepartmentId attribute have UI Hints property as Format Type = Number and Format = *0000* and Auto Submit=true.
But in UI, I am not able to do search from af:Query panel. It works fine without setting UI Hints property Format Type* and Format
Step 1 : Enter 123 in DepartmentId field
Step 2 : Click Search Button
Error : Please provide a value for atleast one of the indicated fields
Error Screen : http://www.freeimagehosting.net/24d51
Please check the below link for downloading the sample application
http://formatissue.googlecode.com/svn/trunk/FormatTest/FormatTest.zip
http://formatissue.googlecode.com/svn/trunk/FormatTest ( SVN version)
Note:
JDev Version : 11.1.1.5.0
I am using ADF BC and ADF Faces Components
Any recommendations fully appreciated
Thanks,
Dinil Mithra
Edited by: Dinil Mithra on Nov 23, 2011 4:51 PM
Edited by: Dinil Mithra on Nov 23, 2011 5:21 PMPlease find the metadata for VO attribute and View Criteria
<ViewAttribute
Name="DepartmentId"
PrecisionRule="true"
EntityAttrName="DepartmentId"
EntityUsage="Employees"
AliasName="DEPARTMENT_ID">
<Properties>
<SchemaBasedProperties>
<CONTROLTYPE
Value="edit"/>
<FMT_FORMATTER
ResId="model.EmployeesView.DepartmentId_FMT_FORMATTER"/>
<FMT_FORMAT
ResId="model.EmployeesView.DepartmentId_FMT_FORMAT"/>
<AUTOSUBMIT
Value="true"/>
</SchemaBasedProperties>
</Properties>
</ViewAttribute>
<ViewCriteria
Name="EmployeesViewCriteria"
ViewObjectName="model.EmployeesView"
Conjunction="AND">
<Properties>
<CustomProperties>
<Property
Name="displayOperators"
Value="InAdvancedMode"/>
<Property
Name="autoExecute"
Value="false"/>
<Property
Name="allowConjunctionOverride"
Value="true"/>
<Property
Name="showInList"
Value="true"/>
<Property
Name="mode"
Value="Basic"/>
</CustomProperties>
</Properties>
<ViewCriteriaRow
Name="vcrow103"
UpperColumns="1">
<ViewCriteriaItem
Name="EmployeesViewCriteria_vcrow103_EmployeeId"
ViewAttribute="EmployeeId"
Operator="="
Conjunction="AND"
Required="SelectivelyRequired"
GenerateIsNullClauseForBindVars="false"/>
<ViewCriteriaItem
Name="EmployeesViewCriteria_vcrow103_DepartmentId_EmployeesViewCriteria_vcrow103_DepartmentId_itemHolder_vcrow105_DepartmentId"
ViewAttribute="DepartmentId"
Operator="="
Conjunction="AND"
Required="SelectivelyRequired"
GenerateIsNullClauseForBindVars="false"/>
<ViewCriteriaItem
Name="FirstName"
ViewAttribute="FirstName"
Operator="CONTAINS"
Conjunction="AND"
Required="SelectivelyRequired"
GenerateIsNullClauseForBindVars="false"/>
<ViewCriteriaItem
Name="LastName"
ViewAttribute="LastName"
Operator="CONTAINS"
Conjunction="AND"
Required="SelectivelyRequired"
GenerateIsNullClauseForBindVars="false"/>
</ViewCriteriaRow>
</ViewCriteria> -
Custom Field in Infoset Query missing in Infoset
Hi Everyone,
I'm in a puzzle and I hope someone can help me. Basically I need to maintain an existing infoset Query - While looking through the query and it's related Infoset I noticed there is a custom field appearing in the query (SQ01) but this field is nowhere to be seen in the Infoset (SQ02) - I'm just wondering how can this be ?
The same custom field exists in another Infoset - is it therefore possible to build a query using an infoset while pulling in fields from another ?
I would appreciate any thoughts on this matter as I'm in a very confused way over this.
Thanks in advance
Kind Regards
Damien
Edited by: Damien Kesle on Jul 22, 2009 3:48 PMHi Damien Kesle ,
There are ways by which you can create fields ( they are called Local fields ) in the Query too.
Please see , whether the custom field you are asking is present in the Query.
Even then , just to confirm that your said field does not exist in the infoset, follow the steps.
Go to SQ02, put the name of your Infoset and click on tab "Description ".
Then do a Ctrl + F (Find/Search) for the field. If its not there, then you can confirm that the field comes from Query and not Infoset.
Approach for any further queries.
Regards,
Subin John -
Form query/search issue F6 , F11 + Ctrl F11
Dear Techies,
I have an issue with form query/search mode in oracle applications. The Issue is i have a custom form which has headers and lines. whenever i open the form cursor is defaulting on a column called "Transaction_year" which is a mandatory column, Because of this whenever i want to search first I have to clear the record (Press F6) then press F11 and CTRl F11.
And my client is irritated to press so many buttons. I cannot make mandatory col to optional since it is "Transaction_year" a primary key. I have to customize the form in such a way that it should allow f11 + ctrl f11 to search.
Can somebody help me how can i achieve this. I am new to forms :(I have written this code in form level - when new form instance trigger
go_item('XXDOF_PA_PRJCST_HEADERS.FIN_APPRVER_DEPT');
this is a optional field ... and when when i open form it is defaulting to this ... still f11 + ctrl f11 is not working ... i have to clear it (f6) and then press f11 + ctrl f11 -
Duplicate Records in ABAP Query
I have prepared ABAP query with tables KNA1, KNB1, BSID. I have mapped only BUKRS and KUNNR from BSID . as I don't have any condition to map the fields. I want only one record for considering KUNNR and BUKRS in report . But in report It is displaying all entries from BSID considering BUKRS and KUNNR means for documents all line items.Kindly suggest as soon. How to avoid such duplicate records
Hi,
Duplicate Records in ABAP Query
Regarding on your problem,
Use these link, It will helps to your post
ABAP Querry Duplicate entries
Regards,
Sekhar -
Hi There,
In SAP GRC 10.0, our team had an issue where we could not add duplicate fields from separate table (see ERROR: Select Currency/UoM field for the selected analyzed fields). This was resolved by the SAP Note 1904313/ 1904314 (http://service.sap.com/sap/support/notes/1904313).
We upgraded our system to SAP GRC 10.1 SP05 and could now add the duplicate fields from separate tables. SAP Note 1904313/ 1904314 was part of SAP GRC 10.1 SP03 so it makes sense that we, in a higher version (SP05), would be able to do this.
The issue now is when we add the duplicate fields from different tables and run the Ad-hoc Query to test if the data source works correctly, the No Data Selected warning persists. This means that the data source provides no data for analysis, which is required to write our business rules.
Below is an example:
Basic data source with just one currency reference field EBAN-WAERS.
When you run the Ad-Hoc Query you receive data.
Basic data source with second currency reference field EKKO-WAERS.
When you run the Ad-Hoc Query no data is found.
Please also make reference to the following thread logged by my colleague (ERROR: Select Currency/UoM field for the selected analyzed fields)
Any assistance to receive data with duplicate fields from separate tables will be highly appreciated.
Thanking you in advance.
Regards
Gary KhanHi
following are the error messages from dump
hrtText
There is already a line with the same key.
hat happened?
Error in ABAP application program.
The current ABAP program "SAPLCKMS" had to be terminated because one of the
statements could not be executed.
This is probably due to an error in the ABAP program.
rror analysis
You wanted to add an entry to table "\FUNCTION-POOL=CKMS\DATA=T_DYN_CKMLCR",
which you declared
with a UNIQUE KEY. However, there was already an entry with the
same key.
This may have been in an INSERT or MOVE statement, or within a
SELECT ... INTO statement.
In particular, you cannot insert more than one initial line into a
table with a unique key using the INSERT INITIAL LINE... statement.
rigger Location of Runtime Error
Program SAPLCKMS
Include LCKMSF01
Row 226
Module type (FORM)
Module Name DYNAMIC_PERIOD_CLOSING
Source code where dump ocured
222
223 APPEND ht_ckmlpp TO t_add_ckmlpp.
224 APPEND LINES OF ht_ckmlcr TO t_add_ckmlcr.
225 INSERT ht_ckmlpp INTO TABLE t_dyn_ckmlpp.
>>>> INSERT LINES OF ht_ckmlcr INTO TABLE t_dyn_ckmlcr.
227 ENDWHILE.
Also I guess there is problem with material ledger in R/3 side
I have never worked on material ledger before so dont hav idea of Tcode and tables in SAP R/3 for material ledger.
Thanks
Navneet -
What kind of query search is implemented in ADF Query components(ADF Query, ADF Query with Table) ?
The query component provides the user the ability to perform a query based on a saved search or personalize saved searches. The component displays a search panel with various elements, each of which help the user to accomplish various tasks.
Elements rendered by the query component
Search Panel: the panel that encloses all elements rendered by the query component
Search Header: Spans the entire width of the search panel and used to display a disclosure icon, the label, search mode (toggle button) and saved search (choice list of saved searches). The help (deprecated), info and toolbar facets' content is also displayed in the header.
Match Type: A radio button group that appears below the search header, it defines whether the search criteria should be treated as an AND search or an OR search. For details on the conjunction operators refer to the QueryDescriptor and ConjunctionCriterion classes.
Criteria region: A form layout that appears below the Match type, it contains search fields that define the search parameters. For details on search fields refer to the QueryDescriptor model.
Criterion: A criterion represents a single search field, that comprises of an operator and one or more value fields. For value fields that render LOV components, the autoComplete feature is not enabled unless either of the methods, AttributeCriterion.hasDependentCriterion() or ListOfValuesModel.isAutoCompleteEnabled() return true. This is done to allow the end-user to enter partial values with wild-cards and tab around the search panel without causing the LOV dialog to be launched (everytime they tab-out of the LOV value field).
Action buttons: The search panel has four action buttons: Search, Reset, Save, and Add Fields. The action buttons appear below the criteria region. They are end-aligned within the search header.
NOTE: The Add Fields feature is only available in the Advanced mode. -
Extending SalesOrder Query search on MSR 2.0
Hi all,
I need to extend query search for sales order by adding a date range (FROM - TO in place of a single date field DATE_DOC). But the DATE_DOC_HIGH custom field has not a FieldDescriptor so it's not possible to call:
searchKeys<i> = getFieldDescriptor("DATE_DOC_HIGH"); //->>returns an Exception
(where 'i' is the Condition number index)
It's possible to clone the FieldDescriptor of the standard field DATE_DOC, and modify its KEY and VALUE in order to fill it with those of DATE_DOC_HIGH?
The standard code that run the query is this:
conditions[j][0] = queryFactory.createCondition( searchKeys<i>,
criteriaTypes<i>,
tmpSearchCondition<i>.getDateValue());
Does anybody know another way to fullfill this goal?
Thanks in advance,
GBHello,
I am not sure I am getting the question. Normally you have to create to condition on the date field one with DATE > input date 1 and DATE < input date 2.
You create a composite condition and query with it directly. No need for a custom field as they cannot be used for querying (if they are not in the syncbo def).
Thank you,
Julien.
msc mobile Canada
http://www.msc-mobile.com -
How to use ADF Query search with EJB 3.0
Hi,
In ADF guide http://download.oracle.com/docs/cd/E12839_01/web.1111/b31974/web_search_bc.htm#CIHIJABA
The steps to create query search with ADF Business Components says:
"+From the Data Controls panel, select the data collection and expand the Named Criteria node to display a list of named view criteria.+"
But with EJB, I'm not able to find Named Criteria node. Can we use ADF query search component with EJB? If yes, can you please show me some example, tutorial etc.?
Thanks
BJFor EJBs you'll need to implement the query model on your own.
An example of how the model should look like is in the ADF Faces components demo.
http://jdevadf.oracle.com/adf-richclient-demo/faces/components/query.jspx
Code here:
http://www.oracle.com/technology/products/adf/adffaces/11/doc/demo/adf_faces_rc_demo.html -
I am getting PLS-00410 error - duplicate fields in RECORD, TABLE or argumen
Here is what I am doing. I have a package header and a package body. The package header compiles successfully and the above error is displayed while compiling the package body only.
Package Header :
create or replace package pkg_pms_print is
type c_ref_printer_list is REF CURSOR;
PROCEDURE sp_get_printerlist
p_team_id IN NUMBER,
printer_list_refcur OUT pkg_pms_print.c_ref_printer_list
end pkg_pms_print;
Package Body:
create or replace package body pkg_pms_print is
PROCEDURE sp_get_printerlist (
p_team_id IN NUMBER,
printer_list_refcur OUT pkg_pms_print.c_ref_printer_list
IS
printer_list_refcur pkg_pms_print.c_ref_printer_list;
v_printer_id pms_test_team_printer.printer_id%TYPE;
v_printer_name pms_test_team_printer.printer_name%TYPE;
v_default_printer pms_test_team_printer.default_printer%TYPE;
BEGIN
OPEN printer_list_refcur FOR SELECT printer_id, printer_name,default_printer FROM pms_test_team_printer WHERE team_id = p_team_id;
--DBMS_OUTPUT.PUT_LINE('EMPNO ENAME');
DBMS_OUTPUT.PUT_LINE('--- -------');
LOOP
FETCH printer_list_refcur INTO v_printer_id, v_printer_name,v_default_printer;
EXIT WHEN printer_list_refcur%NOTFOUND;
DBMS_OUTPUT.PUT_LINE(v_printer_id || '|'|| v_printer_name ||'|'|| v_default_printer);
END LOOP;
CLOSE printer_list_refcur;
END sp_get_printerlist;
END pkg_pms_print;
Apart from this error one error also shown as " PL/SQL: Item Ignored"
The compile points to the 3rd line in the package body for errors with the above mentioned error. There is no duplicate field name or argument name as the oracle error message says. It's a simple straight forward code. Can somebody help me if I am overlooking something?
Regards,
AgrawalVthis problem is solved but i am not getting output when i have tested this procedure in test window.
Program Continues upto 2nd DBMS call, means i am getting output upto 2nd DBMS call.
create or replace package body pkg_pms_print is
PROCEDURE sp_get_printerlist (
p_team_id IN NUMBER,
printer_list_refcur OUT pkg_pms_print.c_ref_printer_list
IS
-- printer_list_refcur pkg_pms_print.c_ref_printer_list;
v_printer_id pms_test_team_printer.printer_id%TYPE;
v_printer_name pms_test_team_printer.printer_name%TYPE;
v_default_printer pms_test_team_printer.default_printer%TYPE;
BEGIN
OPEN printer_list_refcur FOR SELECT printer_id, printer_name,default_printer FROM pms_test_team_printer WHERE team_id = p_team_id;
DBMS_OUTPUT.PUT_LINE('Printer ID Printer Name Default Printer');
DBMS_OUTPUT.PUT_LINE('----- ------- ------- ');
LOOP
FETCH printer_list_refcur INTO v_printer_id, v_printer_name,v_default_printer;
EXIT WHEN printer_list_refcur%NOTFOUND;
DBMS_OUTPUT.PUT_LINE(v_printer_id || v_printer_name || v_default_printer);
END LOOP;
CLOSE printer_list_refcur;
END sp_get_printerlist;
END pkg_pms_print; -
Creation of local field in ABAP Query
Hi
Please let me know how to create a local field in ABAP query. I am finding the option inactive in SQ01.
Regards
Priyadarshinihi priya,
*__Adding u201CLocal Fieldu201D (user defined field) in SAP Query_ :
There is also facility to add the user defined fields in SAP query output. Also we can provide calculation formula for calculating values for this user defined field.
Calculation formula consists of standard fields from standard SAP tables. So the values fetched for particular standard SAP fields from standard SAP tables get calculated as per the calculation formula defined for the user defined field and displays the value accordingly.
To do this first go to change mode for Query which automatically takes you to screen shown below and click on icon , as below :
Then further screen will appears. So select the Field group and again click on the same icon button .
Then switch on the Short names for the fields and give the short names to fields which we need to use in Calculation formula.
Give the short names and then created u201CLocal Fieldu201D, as shown in below screen shot. Also Short names are given to fields, which can be used further for calculation.
Defining Local Field u201CREM_QTYu201D along with its field type and Calculation formula.
In this case we have
defined field type for new
field as similar to
ORD_QTY and
Calculation formula is
defined.
Also its possible to have Conditional logic for Local field by putting Condition in u201CConditionu201D line.
Now activate this newly added Local field for coming it in output screen. To do the same again go to u201CBasic Listu201D and activate the Local Field as shown below :
i think this will help u
regards,
sindhu. -
Alignment and restriction of Custom field in SAP query report
Hi Experts,
I have one custom field in query report(SQ01) called Amount in local currency which is calculated based on Amount in document currecy * exchange rate.
But this field values are coming in left alignment instead of right alignment so how i should get in right alignment and second issue is how i can restrict field value to only 2 decimals.
I tried the below link "http://media.techtarget.com/searchSAP/downloads/SAP_Query_C7.pdf" but the steps they mentioned are not appearing in SQ01 for example in that link they mentioned to click Basic List option for advanced steps but when i click i goes directly to field list with field groups on left pane
Please provide solution for this.
Thanks&Regards,
narasimhaHello narasimha,
In the Infoset when you create the additional field, enter an existing SAP table field that has type CURR in the parameter labeled LIKE Reference. For example you can enter BSAK-DMBTR as a value. When you select the additional field in the query, the currency will also show.
Kind Regards,
Rae Ellen Woytowiez
Edited by: Rae Ellen Woytowiez on Apr 25, 2011 11:27 PM -
CRM IC Winclient - How to add new fields in the BP Search of TRX CIC0
Hello Experts,
I want to know how to add new fields in the BP Search of TRX CIC0. In the HTML that we're using here I need to add the URL of the BP.
Can you help me?
Thanks in advance.
Caíque EscalerHi
make append to tables in se11 - CCMBP1FIELDS, CCMBP2FIELDS
in spro in Define customer-specific search control -> mark fields with X.
and enhance html template CRM_CIC_SEARCH_DISPLAY. -> tcode smw0, look for package CRM_CIC_COMPONENTS for html CRM_CIC_SEARCH_DISPLAY. export it from SAP, edit, and import.
you will need to enhance function module used for searching - you will find him in spro in Search Strategies.
Regards
Radek
Maybe you are looking for
-
Next Slide Problem with Flash In PowerPoint
When I embed a Flash file into a PPT presentation and play Slide Show, my page down (Slide Show advance) key doesn't work once the animation is underway. If I mouse-click the outside borders, it advances properly. Any suggestions on preventing this?
-
Crystal Reports 2010 shows error on 64 bit vista/7 machines
Hello, <br/><br/> I search the threads before posting my problem. I saw number of threads similar to this but none of them is pointing towards solutions to my problem. Thus decided to create new one. I tried various things listed in old post to solve
-
Generating xml from oracle 10g with BLOB image
Hello All, I have employee table with id(primary key), firstname,lastname and I have portrait table with id(secondary key from employee table),image (blob) portrait table store images of the employees which are in the employee table. I want to genera
-
Hi There is a requirement asking for dividing the database between R/3 and E Portal. If basis team do the same, Is it require to re-build the content again in Portal? Are there any drawbacks from Portal side? Whenever R/3 system is down, Is it possib
-
Repetitive System Freeze Following Start-up
I'm using a 17" MBP with 10.4.6. I did a software update 2 days ago, so I'm confident I'm have all of the latest updates. Today, I was tried to convert a .doc file to .pdf using the pdf button in Word. The computer froze up and I had to do a hard reb