Validate entered values based on a database
I'm trying to do something that seems that like it would be relatively simple but I just can't find the answer.
I have a form that I'm trying to design which would reference 4 database fields. I want the user to manually enter the value and then get an error message if they enter an invalid value. Drop down boxes won't work because they all have at least a couple hundred values.
There are about 3000 values in total so manually entering them isn't really an option. The values are in an Oracle database and can pull them into Excel or Access if I need to.
Suggestions on how to best handle this?
One way would be to use a SOAP call; do you have a web server that you could make a call to with the entered data?
To do this you'd create a data connection to the SOAP service that does the validation, add hidden fields for the parameters and the response, and then in the exit event for the field, click the hidden submit button to call the service.
Try creating the service and a connection to it first - testing a connection to a web service is pretty easy. You add the WSDL, drop the request and response fields from the Data View onto the form, drop the button that submits the response and hit Preview. Fill out the request fields and hit the button, and the response fields should fill in with the results of the call.
Once that works, you can set the request fields programmatically, programmatically click the button by using buttonName.execEvent("click") and then programmatically get the values from the response fields.
Let me know if this doesn't make sense to you, it seems a little strange but once you get it, it's not so bad.
Steve Tibbett, Developer Guy
Adobe Systems
Similar Messages
-
Validate field value against LOV in JClient
Hi,
I have wondered is it possible when i have a LOV attached to a textfield or column from JTable to validate entered value against values in LOV. I mean when i enter wrong value in field, automatically to invoke LOV panel when the field lost focus.
Thanks in advance!Hi,
this is currently not a feature available in JClient. We are evaluating this as a new feature in a next version fo ADF JClient (which will be named ADF Swing then)
Frank -
Value based billing plans?
Hi...
I am ABAPer,
I am trying to create value based billing plan in the contrcat creattion..
But if i enter date and bill value and press enter billvalue which entered is not mapping there,
As of now there is no items for this contract,
How can i eneter value based billing plans...?
Thanks,
Naveen.II got the solution for this..,
First of all we can't enter value based bill plans for header with having items..
And, for this problem enter at least one line item and then proceed with bill plans.
Then header can accepts you to enter the value based plans...
Thanks,
Naveen.I -
How to enter values to a database table with data type 'LCHR'?
Hello All,
I have created a database table with five fields, of which the last field is 'Value' field in which i have to enter text with a maximum of 1000characters. I have also specified a 'Length' field preceding the 'Value' field.
The datatype specified for the 'Length' field is 'INT2' and for the value field is 'LCHR' with length 1000.
When i tried inserting values to the table through a report, the report is giving an error that 'Literals that take up more than one line are not permitted', which means 255characters.
Also, when i entered a short text which is less than 250 characters to the 'Value' field,, the report is working fine and the table entry is visible.
Can anyone help me in this?
It would be really helpful if you explain how to use 'LCHR' data type in tables and how to enter values to such a field with more than 255characters.
Thanks in Advance,
ShinoHi shino,
Alternatively,
you can use STRING instead of LCHR.
I too have tried with LCHR and am facing the same issue.. i am not sure why its coming..
i have tried STRING and its working perfectly.
wa-key_field = 'IN4'.
CONCATENATE 'Long text over 200 chars length '
'another Long text over 200 chars length '
'another Long text over 200 chars length '
INTO wa-long_text.
wa-len = strlen( wa-long_text ).
INSERT zshino_table from wa.
SELECT * FROM zshino_table INTO table it.
clear wa.
LOOP AT it INTO wa.
WRITE:/ wa-len, ' ' , wa-long_text.
ENDLOOP.
Also, remember to set the type of the database field as String.
hope this was of some help,
thanks and regards,
Sagar. -
VALUE BASED PARTITIONING BETWEEN AN EXCEL AND DATABASE
Can any1 help I have an EXCEL FILES and DATABASE. I want to make partitioning value-based between these sources.
Thanks you in advances.Hi,
Actually value based partitioning works fine on the data sources which are stored on RDBMS. I haven't try it with a excel source. There is a detailed description in the link below.
http://108obiee.blogspot.com/2009/01/fragmentation-in-obiee.html
Hope this helps,
Cheers.
Cuneyt -
Problem in populating lookup values based on the lookup query from database
HI all
I have problem of population look-up values based on look-up query
I am giving the details what i am trying
I need to populate the values from the UD_LDAP_USR table into the field of UD_USRGRPC_NisNetTriple of type lookup
i planned to set the properties of lookup as like this
look up query as select UD_LDAP_USR_COMMON_NAME as NisNetTriple from UD_LDAP_USR
ColumnNames as UD_LDAP_USR_COMMON_NAME
Column captions as UD_LDAP_USR_COMMON_NAME
Column width as 30
Lookup Column Name as UD_LDAP_USR_COMMON_NAME
But when i try to add ColumnName as wht i mentioned above i m getting invalid property exception,update failed
I am not sure about that are we able to use other Connector table prefix with UD into the another processFrom
Let me give update on this issue
Urgent,struck my work here
thanks
NagarajThanks for the reply raghav
I tried but it was not working
I gave like what u specified but no use
It is throwing exception like set look-up query for the field
Any one help me out on this issue
Edited by: Nagaraju Chowdary on Jan 21, 2013 3:41 AM
Edited by: Nagaraju Chowdary on Jan 21, 2013 3:42 AM -
How to draw custom line in crystal report without manually entering value?
Hi,
I have a bubble chart and want to represent custom lines one in x-axis and one in y-axis at the value arrived based upon an internal calculation.There is an option to manually enter value for custom line.
But i want to generate custom line at runtime without manually entering it.
Can somebody help out?
Regards,
FelixNot sure what this has to do with Database Connectivity?
Moved it to the Report Designer forum. If you are using code then specify what Report engine and version you are using and we can move it again. -
Auto populate values in the the database table
Hi All,
I have a requirement where user enter values in one of the ZTransaction. This will update a Ztable. So the new requirement is to add two new columns in the fields, which is completed. Now this two new fields are supposed to auto populate values based upon the key field .
The transaction code is defined with Transaction as SM30 and Default values as
Name of the screen field value
Update X
VIEWNAME "table name which the values are updated".
Please let me know how to do this.
Thank you!!Hi Swetha,
I am unsure of what you are trying to accomplish so I will make a few assumption and perhaps you can find some benefit in it.
I suppose you are trying to add new fields to a custom (Z) database table.
If so then use SE11 to add the two new columns.
After this is complete then rebuild the table maintenance by using the following path: SE11-> Utilities->Table Maintenance Generator. (Remember to double check the Recording Routine Radio button.)
If the user needs fields automatically populated then check the following link. It describes how to use table maintenance events. I suppose you need to use Event 01 and Event 05.
http://help.sap.com/saphelp_nw04/helpdata/en/91/ca9f0ea9d111d1a5690000e82deaaa/frameset.htm
Good luck and reward points if helpful,
AK
Moderator message - Asking for points is against the Forum's RoE
Message was edited by: Suhas Saha -
Problems with value-based hierarchies in Oracle 11gR2
Hello,
I have the following problem:
I want to cereate a dimension with 2 hierarchies.
These hierarchies have to be value-based.
It's no problem to fill and display one of them, but when I fill both and try to display them, at the lowest level, the parent-child relevancy is now incorrect.
Let's display this in OLAP Worksheet for Cube Type OLAP 11g :
lcolwidth=20
rpr down nim_2 w 25 NIM_2_PARENTREL
------------------NIM_2_PARENTREL------------------
------------------NIM_2_HIERLIST-------------------
NIM_2 KON AGT
L1_Total_AGT_A NA NA
L1_Total_KONZ_K NA NA
L2_AGT_A_A NA L1_Total_AGT_A
L2_AGT_B_A NA L1_Total_AGT_A
L2_AGT_C_A NA L1_Total_AGT_A
L2_KONZ_1_K L1_Total_KONZ_K NA
L2_KONZ_2_K L1_Total_KONZ_K NA
L3_100_A NA L2_AGT_A_A
L3_100_K L2_KONZ_1_K NA
L3_200_A NA L2_AGT_B_A
L3_200_K L2_KONZ_1_K NA
L3_300_A NA L2_AGT_C_A
L3_300_K L2_KONZ_2_K NA
L4_101_A NA L3_100_A
L4_101_K L3_100_K NA
L4_301_A NA L3_300_A
L4_301_K L3_300_K NA
L5_302_A NA L4_301_A
L5_302_K L4_301_K NA
100 NA L3_100_A
101 L4_101_K NA
102 NA L4_101_A
200 NA L3_200_A
201 L3_200_K NA
300 L3_300_K NA
301 NA L4_301_A
302 NA L5_302_A
303 NA L5_302_A
304 NA L5_302_AAs you see, the lowest level items are only connectet with one of the hierachies, instead connected with both. (100, 101, e.g)
If I build the same dimension in a 10g Cube, the result is now correct.
Let's display this in OLAP Worksheet for Cube Type OLAP 10g :
lcolwidth=20
rpr down nim w 25 NIM_PARENTREL
-------------------NIM_PARENTREL-------------------
-------------------NIM_HIERLIST--------------------
NIM AGT KON
L1_Total_AGT_A NA NA
L1_Total_KONZ_K NA NA
L2_AGT_A_A L1_Total_AGT_A NA
L2_AGT_B_A L1_Total_AGT_A NA
L2_AGT_C_A L1_Total_AGT_A NA
L2_KONZ_1_K NA L1_Total_KONZ_K
L2_KONZ_2_K NA L1_Total_KONZ_K
L3_100_A L2_AGT_A_A NA
L3_100_K NA L2_KONZ_1_K
L3_200_A L2_AGT_B_A NA
L3_200_K NA L2_KONZ_1_K
L3_300_A L2_AGT_C_A NA
L3_300_K NA L2_KONZ_2_K
L4_101_A L3_100_A NA
L4_101_K NA L3_100_K
L4_301_A L3_300_A NA
L4_301_K NA L3_300_K
L5_302_A L4_301_A NA
L5_302_K NA L4_301_K
100 L3_100_A L3_100_K
101 L4_101_A L4_101_K
102 L4_101_A L4_101_K
200 L3_200_A L3_200_K
201 L3_200_A L3_200_K
300 L3_300_A L3_300_K
301 L4_301_A L4_301_K
303 L5_302_A L5_302_K
304 L5_302_A L5_302_K
302 L5_302_A L5_302_K-----
We are using the latest Version of AWM: Version 11.2.0.1.0A
Database:
Oracle Database 11g Enterprise Edition Release 11.2.0.1.0 - 64bit Production
PL/SQL Release 11.2.0.1.0 - Production
"CORE 11.2.0.1.0 Production"
TNS for IBM/AIX RISC System/6000: Version 11.2.0.1.0 - Production
NLSRTL Version 11.2.0.1.0 - Production
Thank you verry much for any help.11.2.0.2 for AIX was announced in October 2010. See DOC ID 1249584.1
What is being announced?
We are pleased announce the October 19, 2010 release of Oracle Database 11g Release 2 Patchset 1 (11.2.0.2) on HP-UX > Itanium and IBM AIX on POWER Systems.Patchset 10098816
Description 11.2.0.2.0 PATCH SET FOR ORACLE DATABASE SERVER
Product Oracle Database Family
I have looked, but I cannot find a formal bug for this problem. My hunch is that it was fixed as a side effect of other changes, and I know there were several in this area. My simple test case did work in 11.2.0.2, so I hope it is all fixed. But feel free to enter an SR if you want. (If you mention my name in the SR then support should contact me.) You should certainly do this if moving on to 11.2.0.2 does not resolve the issue. -
Return a value based on multiple criteria
Dear Support Community,
I am trying to formulate a function so that I am able to return a cell value based on more than one criteria.
Referring to the attached screen shot, "Local Start Time" refers to the time that a person will start a work shift, and depending on the "sectors" the person's duration of time at work will vary.
For example, if a person starts work between 07:00am and 07:59am AND the particular shift involves 2 sectors, the allowed time at work is 12H15M. However, given the exact start time, if the shift only involves ONE "sector' the allowed time at work becomes 13H00M etc.
I am trying to formulate a function whereby I can tell the spreadsheet the local start time AND sectors, and then have the appropriate time returned.
I hope the above makes sense!
Thanks
STHi ST,
Print your table and pin it up as a "Ready Reckoner" for humans to refer to.
Convert your table into a Database, something like this:
Start
Finish
Sectors
Allowed Duration
Scenario
0700
0759
1
13h 0m
1
0700
0759
2
12h 15m
2
0700
0759
3
11h 30m
3
0800
1259
1
14h 0m
4
0800
1259
2
13h 15m
5
0800
1259
3
12h 30m
6
1300
1759
1
13h 0m
7
1300
1759
2
12h 15m
8
1300
1759
3
11h 30m
9
1800
2159
1
12h 0m
10
1800
2159
2
11h 15m
11
1800
2159
3
10h 30m
12
2200
0659
1
11h 0m
13
2200
0659
2
10h 15m
14
2200
0659
3
9h 30m
15
(You may want to check that I have converted correctly)
Columns A and B have a Custom Format that allows them to be numbers (not Text) with leading zeroes.
Hide Separator to get rid of the comma
Show zeroes for Unused Digits to show leading zeroes.
Then you can enter "Army Time" (24 hour clock with leading zeroes) into a Query table
Thunderstorms playing havoc here with my internet connection. I will post this now. Watch for the next instalment.
Regards,
Ian -
Validate input value against calculated value
Hi Chaps,
Need a bit of guidence with some PHP code.
I have a Query that estimates a quote ($price_total) for a job.
The estimate ($price_total) is the value of an input (jobquote), and the database is updated once the form is submitted (using a seperate script.php page).
What I need, is to validate the entered value of 'jobquote' against the estimated value of $price_total, just incase a 'custom' price has been agreed with a customer.
If the values are different, then I need an 'admin override' radio button (admin_quote enum('y','n')) to appear.
If someone can help or point me in the right direction, I'd be most grateful.
CheersGot a bit further:
PHP Code:
<input type='text' name='jobquote' value="<?php echo $price_total; ?>"/>
<input type='hidden' name='original_jobquote' value="<?php echo $price_total; ?>"/>
<?php
if ($_POST['original_jobquote'] != $_POST['jobquote'])
{ ?>
<span id="spryradio1">
<input type="radio" name="jobquoteadmin" value="y" id="radio" />Confirm<br />
<span class="radioRequiredMsg">Please confirm Admin Override</span></span>
<?php };
?>
Problem 1. The information is '$_POST'ed to a script file, not to the page itself and at the moment, the $_POST takes place before the PHP validation takes place. If I remove the link to the script page, the validation works.
Problem 2. (link to script removed for testing) If I change the value (from the default 'original_quote'), then submit, the page reloads, the 'Confirm' radio button appears, but the value of 'job_quote' has reverted back thte default:
1. Start - job_quote = £350
2. Change - job_quote = £100
3. Submit
4. Page reloads - job_quote = £350, confirm appears
Is there a way around this? -
Security for value based hierarchy + OLAP
Hi,
I am using row-level security mechanism described here: http://www.rittmanmead.com/2012/03/obiee-11g-security-week-row-level-security/
It works well for level based hierarchies... but is there a way to apply it to value based OLAP hierarchy in OBIEE 11.1.1.6?
My case is:
- I have parent-child value based hierarchy representing management structure with various depth.
- of course facts are always linked to leaf members of hierarchy
- I need to apply security at different levels. E.g. Office manager should have access to one/multiple offices information (basically all employees he manage currently + his previous office before he was moved)
- In report I display presentation hierarchy that starts at country level and then manager drill to his offices
- At country level, manager should see a measure aggregate only for his offices (not whole country)
In relational database there is no problem:
- I follow rittman blog
- create session variable that store list of all leaf members of hierarchy (employees) managed by manager
- with OBIEE "Manage"->"Identity" I apply filter on fact table and get right measure aggregates at all levels of hierarchy
Issue for OLAP:
- with OBIEE "Manage"->"Identity" I apply filter on OLAP value based hierarchy
- in case of filter "MY_BMM"."Org Str"."Org Str Key" = VALUEOF(NQ_SESSION."LEAFS_LIST") -> when manager include hierarchy column to report there are no results because hierarchy starts at country level and he have no access to country data
- to workaround it I tried: "MY_BMM"."Org Str"."Org Str Key" = VALUEOF(NQ_SESSION."LEAFS_LIST_AND_ALL_ANCESTORS") -> manager can see all aggregates at country level because he have access to country, and OLAP just use country level aggregate
- IsDescendant("MY_BMM"."Org Str" , VALUEOF(NQ_SESSION."OFFICE_ID")) will work only for single office as we can not use row wise variables here
One solution I can imagine is to create additional level based dimension that have only 2 levels: "All"->"Org Str Leaf". Then apply filter on this "artifitial" dimension. It is not perfect solution to duplicate dimensions only for security purposes... that's why I ask you for advice if you know better way?
Regards,
mudiHere is an example, how to set security in OBIEE 11.1.1.5 (or future versions) against Oracle OLAP dimensions.
*(1). Create the Oracle OLAP Hierarchy Descendant View against Value-based hierarchy*
These views return a row for each ancestor-descendent relationship in the hierarchy. As you can see how easy it is.
CREATE OR REPLACE VIEW DEPT_DESCENDANTS
AS
SELECT 'DEPT' "DIMENSION", 'DEPTHIER' "HIER", ancestor, descendant
FROM TABLE(OLAP_TABLE('BAWOLAP.BNSOLAP DURATION QUERY', null, 'LIMIT DEPT_HIERLIST TO 'DEPTHIER''',
'DMNS DESCENDANT AS VARCHAR2(60) FROM DEPT
DMNS GID_VAL AS NUMBER FROM ___AW_GID_DIMENSION
MSR ANCESTOR AS VARCHAR2(60) FROM DEPT_FAMILYRELVAL'
where ancestor is not null
*(2). Create the User ACL Tables and Populate with Data*
Create an Access Control list test table by user and Dept. Later this will be populated with production data.
create table user_dept_acls
username varchar2(30),
dept varchar2(60)
insert into user_dept_acls(username, dept) values ('user1', 'GWM');
insert into user_dept_acls(username, dept) values ('user1', 'GT');
insert into user_dept_acls(username, dept) values ('user1', 'SC');
insert into user_dept_acls(username, dept) values ('user2', 'GWM');
insert into user_dept_acls(username, dept) values ('user2', 'GT');
insert into user_dept_acls(username, dept) values ('user3', 'SC');
commit;
*(3). Create an Init Block Connection Pool*
Oracle BI EE requires a separate Connect Pool for Init blocks. It does not allow the default query connection pool to be reused for init blocks. So, we need to create a new init block.
*(4). Create the ACL Session Variables*
These session variables hold the list of all members that the user may access.
Example Session Variable: DEPT_ACL
Init Block: "Init DEPT_ACL"
SQL:
select 'DEPT_ACL', account from user_DEPT_acls where username = ':USER'
union all
select 'DEPT_ACL', descendant
from DEPT_descendants
where ancestor in (select account from user_DEPT_acls where username = ':USER')
union all
select 'DEPT_ACL', ancestor
from DEPT_descendants
where descendant in (select account from user_DEPT_acls where username = ':USER')
The first query block of the init block SQL just selects the members explicitly entered into the ACL table. The second block selects all the descendants of those members from the descendants view. The third block selects all the ancestors to ensure that the user has access to all the members in the drill path starting from the root member.
Make sure that row-wise initialization is checked in the Variable Target section of the init block.
*(5). Add the Data Filters*
In our test case we assigned the data filters to the BIAuthor role, but the filters should be added to whatever role makes the most sense.
Data filter on "BNSGL"."Department":
"BNSGL"."Department"."Dept" = VALUEOF(NQ_SESSION."DEPT_ACL")
*(6). Log in as a Normal User and Query the Hierarchy*
The user can only see to the members to which they are granted access in the ACL table plus all ancestors and descendants of those members.
Drill down to the bottom of the hierarchy.
*(7). Look at the Query Log*
In the nqquery.log we see that the session variable is expanded into an IN list in the physical SQL query. The BI Server breaks the IN list into two IN lists to avoid the Oracle SQL limit of 1,000 items per IN list.
Edited by: Nasar Ali-Khan on Jul 2, 2012 8:14 AM -
Key figure value based on user input.
Dear Friends,
We are using BI7.00 and NW2004S. In one of our report to monitor the number of notification closed and the number of notification open upto the user selected month. For this i have created a Query which has selection screen value as month. I have created a condition which will fetch the difference in days (notification completion - notification creation date) based on user entered value. For example if user enters 10 in the selection screen, report will fetch the notifications which have diffrence in days as 10.
The condition is okay for the above. What user actually wants is the number of notifications completed and that pending based on the value he enters in the screen. For example he enters 10 in the screen, system should show the values as shown below
> 10 days
Completed Pending
3 2
I tried various options but could not achieve this.
Experts help expected. Kindly provide solution.
Regards,
M.MHi,
As per my understanding 1 firstly u have to find out
the no of days (diff between dates notification completion, notification creation date .)
then u have to create condition on no of days which u
have find.there u have to create one user entry
variable for the user can enter his own parametrs.
Right?????
If It is right..
here are the steps..
1st:in the query designer at key figure coloumn create
one local formula.in that local formula create formula
variable with replacement path.in that take reference character
notification completion.in the next tab take replace ment
as key.in the last tab select "date".
2nd: do the same thing for the notification creation date.
3 rd : create 3 rd local formula and do the substraction
for the first 2 local formulas.
4th:create codition on the difference which u have find with
on that condition u can create one user entry varibale.
5th:while u defining the query put these 2 dates,i,e
notification completion, notification creation date in the character block.
If not system will ignore the formula variable which u created in
above steps.
Hope this wil help u.
regards....KP -
Function module to validate input value
Hi all,
can you please provide me the name of the function module to validate input value.
I have a case where i have to validate decimal values. sometimes users may enter wrong decimal values by mistake instead of "0.23" "0..23' and it gives CONVT_NO_NUMBER runtime error so have to come up with some solutions to validate user input.
Please provide me Function module if anybody knows.
Thanks,Try this one
data: lv_htype TYPE dd01v-datatype.
CALL FUNCTION 'NUMERIC_CHECK'
EXPORTING
string_in = my_number
IMPORTING
htype = lv_htype.
IF lv_htype NE 'NUMC'.
Raise an error here...
ENDIF. -
Using infoset based on logical database gives lots of selection parameters
Hi
I'm trying to assist a new Crystal user in getting up on running on Crystal using infosets from SAP. Presently a simple infoset based on logical database PNPCE has been built using fields from just three infotypes (to keep things simple).
When the user logs onto crystal and selects either this infoset, or a query based on the infoset, the very next step requires the user to set 80+ parameters to be null before running the report, and unfortunately those values cannot be saved to if in order to re-run the user has to manually set all the vallues to null again. Clearly this makes it pretty frustrating to use!
This initial screen does not appear if using an infoset based on table joins, but unfortunately the logical database needs to be used to fulfill certain reporting requirements.
I've tried saving a selection variant against a query and forcing it's use but these setting don't seem to be picked up by Crystal.
Are there any Crystal/Query experts out there that can help with this?
Regards
PhilHi,
Is there anyone out there that can help with this? Seems to me like an issue that there 'should' be a soluton to...but I haven't found it yet!
As a bit of additional info - the use of table join based infosets is not an option primarily because there are a lot of reports required that pull in the OM 'additional fields' that come through automatically when using an LDB. However, for table joins, it requires custom coding to be required to the infoset, which clearly restricts the user base from the ability to build their own reports.
Regards
Phil
Maybe you are looking for
-
Error after upgrading BI Publisher report from 10g to 11g
Hi All, I have migrated the BI Publisher from 10g to 11g. The upgrade was done using the upgrade assistant and the installation process was a success. However whenever I try to access the reports in 11g after migration I get the following error: orac
-
I am getting a framing error when running a VI via RS-232. Any thoughts?
I have a Keithley 2700 multi meter and am trying to get its IDN. I am getting error number 800, on the multimeter, back when running the VI
-
How to create a sales order using a catlog numer
hi, is it possible to create a sales order using a catlog number of the material .. did any one work on this type ... and how to maintain catalog number for a material? thank you mmn
-
Another strange compressor bug
I've got a 12 minute film that I'm compressing for DVD SP with Compressor using the 90-minute best quality settings. I've got a title card at the beginning of the film that I comped in Shake ... It's totally static. When playing back the compressed v
-
Instagram doesn't open in safari or on iPad.
Every time I try to login to instgram I get the following message: "Sorry, an error occurred while processing this request." The page starts to load then stops and en this message appears in the Safari window.