Conditional Field and Autocomplete
Hi guys,
first of all, I'm a system analyst and I work with .NET framework, I'm not a DBA. So I need a help that I guess is simple. I'm creating a table in Oracle express 10g where one of the fields will have its value from a combination of values of two others fields, in the other words, this will be a conditional field.
Any body know where I can found an example of this implementation?
Beforehand, my thank you very much
user10437322 wrote:
but as I'm not a DBA and I really don't know how to start to work with PL/SQL, do you have some link with samples about that?I know DBAs that know very little about PL/SQL. PL/SQL is a proper procedural language.. not much different than Pascal or Visual Basic or C.
The big difference is that it is a server side language. And that PL/SQL is in fact 2 separate languages.. PL is the Programming Logic language. It allows you to write native SQL (different language) inside the PL source code, using PL variables... in other words, a seamless and tight integration of the SQL language inside the PL language.
Thus no need to step out of PL source code and use a database interface/class/whatever to communicate via SQL with the database. You mix your native SQL code directly with PL source code and the PL/SQL compiler figures out the rest (creating cursors, binding variables, etc). Very powerful... and as it is so close to the SQL engine, it is the fastest way to crunch database data.
So it has very little to do with DBA'ing and everything to do with writing applications. We write full blown (and pretty complex) applications only in PL/SQL, complete with a web interface. Not a single line of code in another language needed. So do not throw PL/SQL into the DBA pigeon hole as it fits rather badly.
The [Oracle® Database PL/SQL User Guide and Reference|http://download.oracle.com/docs/cd/B19306_01/appdev.102/b14261/toc.htm] (10g Release 2) is a good place to start. If you're on 11g (or even 9i), you can find the relevant guide via http://tahiti.oracle.com
PL/SQL is a fairly simplistic language. It does not deal with client interaction (reading keyboard and mouse input). It runs inside a VM that is isolated from the o/s - so PL/SQL code written on a mainframe database will execute happily in a Windows Oracle database. Thus no need to deal with different kernels, issues like big endian vs. little endian and so on.
There are numerous beginner guides to PL/SQL available. Some of them probably good and some not so good...
Bottom line is that if you are a good programmer, then you will find PL/SQL easy to use and write equally good code in PL/SQL as you would in any other language. It is not the language that is important and dictate the quality of the code, but the programmer.
Similar Messages
-
Chart report Condition fields and Data fields
Hi all,
i have tried chart report by adding two condion fields and one data field, the report is more meaning full in this scenario. the first condition field is taken as x-axis, the 2nd condition fields is taken as legend.
while adding more condition fields and data fields, i feel its not showing meaningfull data.
can anyone explain how the condition fields and data fileds are manipulated by crystal report.
i am using CR XI R2 Server.
Thanks
Padmanaban Vi am using Crystal Report XI R2 RAS Embedded in my server.
as we can add any number condition fields programatically using the method
ConditionField.Add(FieldObj), i would like to know how these fields are manipulated internally by the RAS server.
that means, what is the significance of condition fieldobject 1, condition fieldobject 2,condition fieldobject 3 etc...
if i add more than two condition fields , RAS Chart Report always returns 0 as legend value for all legends.
Thanks in advance
Regards,
Padmanaban V
Edited by: Padmanaban Viswanathan on Dec 22, 2008 9:53 AM -
I have a field that is mandatory if another field has a value.
if (!(this.isNull || this.rawValue == ""))
Population.mandatory="error";
else
Population.mandatory="disabled";
How do i script the Popluation field to show a message if the user doesn't provide a value when the field is mandatory?Hi,
That code should do it, is it in the exit event of the controlling field? You might need to check the options under Form Properties ... Form Validations, you should have "Show Dialog Message" set. Also you might need to set the mandatory message value, so;
if (!(this.isNull || this.rawValue == ""))
Population.mandatory="error";
Population.mandatoryMessage="Please enter the population";
else
Population.mandatory="disabled";
Regards
Bruce -
CRM Pricing - BADI to Populate pricing conditions fields
Hello All,
We have CRM 5.0 installed in our customer.
We are facing problems when we tried to replicate the pricing from R/3.
Basically, all Brazilian formulas we have in R/3 are Z. We tried to replicate them in JAVA (IPC) with no success. At this time, it is imposible for us to move to the standard because of the decision of the business.
We are trying to find one BADI where we can populate all the pricing conditions retrieved via RFC from R/3. Unfortunatelly we don't have good luck with this.
Our idea is to use this BADI to call R/3 and retrieve the conditions needed, and then populate the CRM pricing fields..
Could you please help us? Do you have any other idea to solve this issue?
This is very critical for us.
Thanks in advance.
MartinHi Ntk,
Thanks for your reply.
I tried to search in se18. I found one BADI that runs when users enter new materials or changes the quantity of the sales order.
This one does not help us too much, because when you go to conditions tab (into CRMD_ORDER or via ICWEB) all conditions are redetermined with the pricing determined in IPC.
We want to fill the conditions of the sales orders or the sales quotations at running time. In the BADI we would use the function module RFC SD_SALESDOCUMENT_CREATE (in simulation mode) in R/3 and retrieve all conditions fields and then populate the pricing conditions in CRM.
Do you know any BADI with this behaviour? Or another similar?
THANKS! -
Creating Condition Table.. Key fields and line items
dear all
I am creating a Condition table and have 6 fields, I want to make 5 of them as key fields and also header line fields.
I want my 6th field as line item field but I am unable to do that. My last key field is also shoiwing in line item.
Please help.
Thank you.
Madhu.Hi,
Check this thread
Re: VK11
Regards,
Chandra -
Key fields and non-key field of condition table
Hello Gurus,
what is key fields and non-key field of condition table?
thanks very much!Key field
Each condition table contains keys that can be used for creating dependent condition records.
for example let take condition type PR00.
PR00 uses access sequence PR02 .
Access sequence PR02 has following tables associated with it namely 304, 305 & 306
When you create a conditon record for PR00 with transaction VK11 or VK31, you have a button 'key combination' which is nothing but fields associated with tables 304, 305 & 306.
In brief, Condition records are always created using specific keys. Condition tables are used to define the structure of the keys of a condition record.
Non key field
For example take condition table 144 - sales deal basic data.
Table 144 is associated with access sequence PBUD.
If you check the fields associated with this table (click technical view button), there are three fields at bottom which do not have 'key' check mark -KDATU, PLTYP, KSTAF
So, when you create a condition record for PBUD, system does not propose these 3 fields in 'key combination' and hence are non key fields.
Please reward points for good answers as this would help increase the total donation that SAP will make to the United Nations World Food Programme. -
How to transfer SRM PO Condition Type and Custom fields to ECC?
Hi All,
I have a scenario to transfer SRM Line item condition types and few custom fields to ECC.
I have found the following things but structure 'CI_EKPODB' does not exists in ECC.
I am using 'SRM 5.00' and 'SAP ECC 6.0'.
NOTE: I have to transfer condition records when PO is getting created / modified.
1) Earlier I was planning to use BADI 'BBP_CREATE_BE_PO_NEW' in SRM and this will transfer the data to ECC in case of PO
Creation.
It contains the Condition fields to be passed to ECC.
But i am unable to implement the same, whenever i create implementation when i click 'Activate' its getting activate then after few seconds its getting deactivate, i think this is because this BADI is not allowed for multiple use and SAP has already made one implementation on the same.
2) I need to implement BADI 'BBP_ECS_PO_OUT_BADI' in SRM and 'BBP_PO_INBOUND_BADI' in ECC.
SRM BADI will pass verified field details to ECC as a custom fields
It does not contains the Condition fields to be passed to ECC, so i was planning to pass the same as custom field(s).
ECC BADI 'BBP_PO_INBOUND_BADI' will be used to map the fields to correct place and this should work.
i need to modify the structures and pass all the custom fields (z-fields) - (CI_EKPODB but does not exists kindly suggest) as data.
Other required details:
Transfer of PO does not supported by SAP for service PO's, any suggestion on the same?
Expecting quick reply from your end.
Thanks in advance.
Regards,
HemantNaresh,
Thanks for quick response.
My concern is this BADI 'BBP_CREATE_BE_PO_NEW' will trigger only in case of creation, not when PO is changes.
I have to transfer condition types and custom fields to ECC in both the case (create / change)
If i have to do this only in case of creation then i can pass Condition types / custom fields then i can use parameter 'CS_PO1_DOCUMENT' from method 'FILL_PO_INTERFACE1'.
this parameter contains 'IT_POCOND', 'IT_POCONDX' and 'IT_EXTENSIONIN' as parameter so my problem will be solved.
But i dont think this will trigger in both the cases and 2nd thing i cann't implement the BADI since its not marked for multiple use so i am unable to implement the same.
Kindly correct me if i am wrong.
Once again thanks for your reply.
Please suggest on the same.
Regards,
Hemant -
Transportation Group and Shipping condition fields in Route determination
Hello Guys,
Please, I heard that if I leave Transportation Group and Shipping conditions field empty Route determination would consider whatever value I put in Material/Custumer Master.
But the determination just happen if I put the exact value in either the determination and the Material Master for Transportation Group field for example.
Have you ever determined Routes leaving the fields empty?
Thank you,
Regards,Hi,
Those fields Transportation Group and Shipping conditions available in Route Determination are essential to trigger the correct route in Sales Order level.
If blank the available routes need to be picked manually at Sales Order level.
Kindly check .
Regards,
SRK -
Condition types and value fields
hi Gurus,
Can anybody please explain me what is condidion type and value field and the purpose of these two in costing??
Regards,
S.SumanaDear Sumana,
Condition types and Value field conjuction is used in Profitability Analysis.
Condition type is an element in pricing procedure. For e.g price of the product consist of several things like base price, discount, tax, etc. so each compenent is called condition type.
Value fields are grouping of cost elements for e.g. you have created a cost element Sales revenue then all revenue cost elements which consist of revenue.
Condtion type Base Price is revenue which is mapped to value field Sales revenue. So as soon as the billing document is created value field is updated.
For more information on Profitability analysis please read the documentation provide in www.help.sap.com
Regards,
Chintan Joshi. -
SQL Query (updateable report) Region - Conditionally Hide and Set Values
SQL Query (updateable report) Region - Conditionally Hide and Set Values
Outline of requirement :-
Master / Detail page with Detail updated on same page using SQL Query (updateable report).
The detail region has the following source
SELECT item_id,
contract_id,
CASE WHEN hardware_id IS NOT NULL THEN
'HA'
WHEN backup_dev_id IS NOT NULL THEN
'BD'
WHEN hardware_os_id IS NOT NULL THEN
'HS'
END item_type,
hardware_id,
backup_dev_id,
hardware_os_id
FROM "#OWNER#".support_items
WHERE contract_id = :P26_CONTRACT_IDThe table support_items implements arced relationships and has the following columns
CREATE TABLE SUPPORT_ITEMS
ITEM_ID NUMBER NOT NULL,
CONTRACT_ID NUMBER NOT NULL,
HARDWARE_ID NUMBER,
BACKUP_DEV_ID NUMBER,
HARDWARE_OS_ID NUMBER
)A check type constaint on support_items ensures that only one of the fk's is present.
( hardware_id IS NOT NULL
AND backup_dev_id IS NULL
AND hardware_os_id IS NULL
OR ( hardware_id IS NULL
AND backup_dev_id IS NOT NULL
AND hardware_os_id IS NULL
OR ( hardware_id IS NULL
AND backup_dev_id IS NULL
AND hardware_os_id IS NOT NULL
) Hardware_Id is a FK to Hardware_Assets
Backup_dev_id is a FK to Backup_Devices
Hardware_os_id is a FK to Hardware_op_systems
The Tabular Form Element based on item_type column of SQL query is Displayed As Select List (based on LOV) referencing a named list of values which have the following properties
Display Value Return Value
Hardware Asset HA
Backup Device BD
Computer System HSThe Tabular Form Elements for the report attributes for hardware_id, backup_dev_id and hardware_os_id are all Displayed As Select List (Based on LOV).
What I want to do is only display the Select List for the FK depending on the value of the Select List on Item Type, e.g.
Item_Type is 'HA' then display Select List for hardware_id, do not display and set to NULL the Select Lists for backup_dev_id and hardware_os_id.
Item_Type is 'BB' then display Select List for backup_dev_id, do not display and set to NULL the Select Lists for hardware_id and hardware_os_id.
Item_Type is 'HS' then display Select List for hardware_os_id, do not display and set to NULL the Select Lists backup_dev_id and hardware_id.
There are properties on elements to conditionally display it but how do we reference the values of the SQL query Updateable region? they are not given a page item name?
Also on the Tabular For Elements there is an Edit tick against a report item - however when you go to the Column Attributes there is not a property with which you can control the Edit setting.
What's the best way of implementing this requirement in APEX 3.1?
Thanks.>
Welcome to the forum: please read the FAQ and forum sticky threads (if you haven't done so already), and update your profile with a real handle instead of "user13515136".
When you have a problem you'll get a faster, more effective response by including as much relevant information as possible upfront. This should include:
<li>Full APEX version
<li>Full DB/version/edition/host OS
<li>Web server architecture (EPG, OHS or APEX listener/host OS)
<li>Browser(s) and version(s) used
<li>Theme
<li>Template(s)
<li>Region/item type(s) (making particular distinction as to whether a "report" is a standard report, an interactive report, or in fact an "updateable report" (i.e. a tabular form)
With APEX we're also fortunate to have a great resource in apex.oracle.com where we can reproduce and share problems. Reproducing things there is the best way to troubleshoot most issues, especially those relating to layout and visual formatting. If you expect a detailed answer then it's appropriate for you to take on a significant part of the effort by getting as far as possible with an example of the problem on apex.oracle.com before asking for assistance with specific issues, which we can then see at first hand.
I have a multi-row region that displays values and allows entries in a number of fields.Provide exact details of how this has been implemented. (An example on apex.oracle.com is always a good way to do this.)
I should like the fields to be conditional in that they do not permit entry, but still display, if certain conditions apply (e.g. older rows greyed out). Can this be done? Almost anything can be done, often in multiple ways. Which are appropriate may be dependent on a particular implementation, the skills available to implement it, and the effort you're willing to expend on it. Hence it's necessary to provide full details of what you've done so far... -
Problems with Conditional Display and Read Only
Hi Everybody,
I have a form to Add/ Modify Table Info.
I have column which stores numeric value (like no. of purchases, no.of returns etc.,) and I have a text field with this Database column as Source.
In some cases the value is a foreign key (Id of the Owner, Buyer etc.,) to another table. In such cases, I want to display a select list containing people information. Is that possible?
This is what I did to achieve that
I added a select list with info from second Table. Made both the text field and the select list to conditional display and conditional read only.
My understanding is that When an item is made read only it should not be saved to the Database.
But while Updating I am getting the following Error
ORA-06550: line 1, column 130: PL/SQL: ORA-00957: duplicate column name ORA-06550: line 1, column 7: PL/SQL: SQL Statement ignored.
Any can anybody help me out on this?
Thanks
NimmiMy understanding is that When an item is made read only it should not be saved to the Database
No, all page items with a Source Type of "Database Column" will be used by the Automatic DML process to insert/update the database. Form inputs with the "disabled" HTML attribute set are not POSTed to the server.
Try to create 2 items, one Select List and other Text Field but setup their conditions such that only one of them is rendered on the page at any given time. That might work. -
Requirement of creation of new condition types and Account keys tax codes
Hi,
In what all possible scenarios will the requirement to create new Condition types and accont keys arise for the creation of new depreciation keys.
Thanks
Raja.
Edited by: Raja Gopal 345 on Aug 29, 2010 1:06 PMUnless you use jurisdiction codes, and no external tax system, for
example with tax procedure TAXUSJ, there is no validity dates for the
condition records. You can see this differnce by comparing the tables
A003 without jurisdiction codes and A053 with jurisdiction codes. A053
contains the extra fields DATBI (key field) and DATAB. This is the
standard functionality.
Please have a look at the following part of note 418582:
" Changing past percentage rates has to be inhibited in order to avoid
database inconsistencies. For this reason, the functions which allow you
to transport time-dependent tax codes with percentage rates from the
past are not supported." -
Sales Pricing Procedure : Statistical Condition type and Reqt.
Hi,
I wish to know what else is the use of marking the condition type statistical except the ones i know. (a) now included in the final price. but will be seen in the condtions (b) Can be used to send that value to a particular account.
What is the use of the following routines in the Reqt. field and what do they do
a. (2) - Item with Pricing. Now in this routine it check "prsfd". which is field called carry out pricing in the table.
Can someone explain me how this works. Also if you can explain how these subroutines genrally work. It would be great.Hi Dheeraj,
What you told is correct that Statistical Condition means that the condition item is ignored. In other words, no flow records are generated in the cash flow.
While regarding Requirement, it is pre-requisite to take that particular Cond type (to which it is assigned) into consideration while carry out pricing.
Like in your case Requirement "2" (item with pricing), the condition type(s) to which it is assigned would be taken into pricing only when item has pricing attched to it.
Regards
SD -
Date fields and compare and get the later date of the fields
I am trying to compare these date fields and compare and get the later date of the fields
Tables are
TABCASER
TABCASER1
EVCASERS
Field
Are
TABCASER1.CASER_no
The dates are to be compared and then get the records with the highest or latest date value.
TABCASER1.CASERRECIEVEDDATE
EVCASERS.FINALEVDATES
EVCASERS.PUBLICATIONDATE
EVCASERS.PUBLICATIONDATE
TABCASER.COMPAREACCEPDATE
I have this code but I am trying to figure out what it all means.
I have several questions.
1.
1. greatest it is used here to compare right? How do I then output this ? do I store it to a var (coldfusion) ultimately , I wish to send it to a page of records
2. is it necessary to use todate? And to_date? What does this do?
3. decode, is this necessary too. What does this do? NULL?
4.
5.
6. when I do get the query results how do I send it to coldsuion and out put to a display.
Someone sent me this code.
is there abetter way of doing this? To compare the dates and store in a var to display. thanks
Here is my code below:
Greatest(
CASE
WHEN INSTR(TABCASER1.CASER_no,'-CE') > 0 THEN
decode(TABCASER1.CASERRECIEVEDDATE,NULL,TO_DATE('01/01/1900','mm/dd/yyyy'),TABCASER1.CASERRECIEVEDDATE)
WHEN INSTR(TABCASER1.CASER_no,'-ERNIE') > 0 THEN
decode(EVCASERS.FINALEVDATES,NULL,TO_DATE('01/01/1900','mm/dd/yyyy'),EVCASERS.FINALEVDATES)
WHEN INSTR(TABCASER1.CASER_no,'-MONIE') > 0 THEN
decode(EVCASERS.PUBLICATIONDATE,NULL,TO_DATE('01/01/1900','mm/dd/yyyy'),EVCASERS.PUBLICATIONDATE)
WHEN INSTR(TABCASER1.CASER_no,'-NADINE') > 0 THEN
decode(EVCASERS.PUBLICATIONDATE,NULL,TO_DATE('01/01/1900','mm/dd/yyyy'),EVCASERS.PUBLICATIONDATE)
ELSE
decode(TABCASER.COMPAREACCEPDATE,NULL,TO_DATE('01/01/1900','mm/dd/yyyy'),TABCASER.COMPAREACCEPDATE)
END
,decode(TABCASER.COMPAREACCEPDATE,NULL,TO_DATE('01/01/1900','mm/dd/yyyy'),TABCASER.COMPAREACCEPDATE))
between TO_DATE('#dateformat(form.startDate,"mm/dd/yyyy")#','MM/DD/YYYY') and TO_DATE('#dateformat(form.endDate,"mm/dd/yyyy")#','MM/DD/YYYY')
is there abetter way of doing this? To compare the dates and store in a var to display. thanksHi
If you have date datatypes than:
select
greatest(TABCASER1.CASERRECIEVEDDATE, EVCASERS.FINALEVDATES, EVCASERS.PUBLICATIONDATE, EVCASERS.PUBLICATIONDATE, TABCASER.COMPAREACCEPDATE)
from TABCASER, TABCASER1, EVCASERS
where ...-- join and other conditions
1. greatest is good enough
2. to_date creates date dataype from string with the format of format string ('mm/dd/yyyy')
3. decode(a, b, c, d) is a function: if a = b than return c else d. NULL means that there is no data in the cell of the table.
6. to format the date for display use to_char function with format modell as in the to_date function.
Ott Karesz
http://www.trendo-kft.hu -
Help with Conditional Display and Validation
Version 4.1.1.00.23
Hello,
I'm having a difficult time with a conditional display and validation I'm hoping someone can help with.
Requirements:
When the Start Date (Datepicker) and/or End Date (Datepicker) change then display the Change Reason (Select List) and Change Description (Textbox)
If the page is saved without entering a Change Reason display a validation error message that the Change Reason cannot be empty (NULL)
What I've tried
Create a Dynamic Action on the Start Date
Event: Change
Selection Type:Item(s)
Items(s): P51_START_DATE
Condition: none
True Action Section:
Action: Show
Fire on Page Load: Checked
Show all page items on the same line: No
Affected Items Section:
Selection Type:Item(s)
Item(s): P51_CHANGE_REASON,P51_CHANGE_DESC
I've also created a Dynamic Action with similar settings for the P51_END_DATE.
I created a Validation for the P51_CHANGE_REASON as Function Returning Error Text:
DECLARE
v_start_date work_items.start_date%TYPE;
v_end_date work_items.end_date%TYPE;
BEGIN
SELECT start_date
,end_date
INTO v_start_date
,v_end_date
FROM work_items
WHERE work_items_id = :P51_WORK_ITEMS_ID;
IF ( (v_start_date != TO_DATE(:P51_START_DATE,'DD-MON-YYYY') OR v_end_date != TO_DATE(:P51_END_DATE,'DD-MON-YYYY') ) AND
:P51_CHANGE_REASON IS NULL ) THEN
RETURN 'Change Reason must have a value';
END IF;
END;
The Issue
I tried to create another Dynamic Action to hide the P51_CHANGE_REASON and P51_CHANGE_DESC fields on page load, but when either of the date fields are changed and the validation is fired the P51_CHANGE_REASON and P51_CHANGE_DESC are hidden again.
There are two buttons to submit the page: 'SAVE' will submit the page and stay on the page and 'SAVE_CHANGES' will submit the page and branch to the previous page (which is a report with EDIT buttons to edit the record).
I can't get the page load Dynamic Action to NOT fire when the validation is fired.
I hope this is clear and if not what information can I provide?
Thanks,
JoePhil,
Thank you for looking at this.
Yes if the Change Reason is NULL when the edit page is displayed then the Change Reason and Change Description fields are hidden. If the Start Date (Datepicker) and/or End Date (Datepicker) change then display the Change Reason (Select List) and Change Description (Textbox). If the page is saved without entering a Change Reason display a validation error message that the Change Reason cannot be empty (NULL).
The problem I'm having is that if no Change Reason is entered and the page is saved thereby firing the validation the Change Reason and Change Description fields are hidden again (because of the On-Load Dynamic Action to hide them). So now the user can't put in a Change Reason...unless they change one of the date fields again which isn't going to be accepted.
Is there a way to determine if a validation error was fired and be able to use that on the On-Load Dynamic Action to hide the two fields? Something like...If the validation fired then don't run?
Please let me know if I'm still confusing you.
Thanks,
Joe
Maybe you are looking for
-
Hi , We have setup service desk and want all the users to work on workcenters,created two test users 1.processor 2.enduser Scenario: when a new msg is crated, the message is processed by processor and when he needs additinal info, he set sthe status
-
Hi IS it supported in GL code combinations to have a alpha numeric values in key segment values .. we have a project segment in our chart of accounts and need the aplpha numeric values eg PRT001 , ADT001 etc . We do have some customizations and wonde
-
Problem with numeric types in Abap Proxy
Hello, We are having problems with some abap proxy calls. When a numeric type is filled with 0 the node it´s automatically removed and no value it's recived in XI. The only way I have found to avoid this problem it's to define the field with type str
-
Hi, It maybe sounds really weird, but for some reason there is no 'Preview' mode in my illustrator, only preview modes like GPU\Pixel\Overprint. How can I fix this?
-
Tomcat can't find existing file
Hello, unfortunately i keep getting the following error: Servlet /tomcat-docs threw load() exception javax.servlet.ServletException: Service not available (propertyFile not loadable:Can't find properties file /usr/share/tomcat4/webapps/tomcat-docs/..