InputListOfValues behavoir when entered value returns multiple rows
Hi,
We're using ADF Faces & BC 11.1.1.2.0. Our app is being tested and our QA team has flagged the following behaviour as a bug:
Test:
Type the value 'S' into the list of values input box.
Expected behaviour:
System recognises entered value 'S' as matching row with primary key 'S'.
Actual behaviour:
LOV search box appears automatically, showing the values 'S' and 'SX'.
User is required to explicitly select row 'S'.The inputListOfValues is set to autosubmit, so it seems that as soon as the user enters a value that could be the prefix of a number of rows, the search box is shown (even if the value they've entered does actually have an exact match to one of the rows).
How can we stop this behaviour? Ideally, we don't ever want the search dialog to automatically popup (would rather have the LOV simply shown as in error if the user enters an invalid value).
Cheers!
I don't think creating our own popup is an option. As you know, the inputListOfValues popup offers a huge range of search features that our users are attached to.
If there's no easy way to disable this then we'll just have to argue that this is the expected behaviour. I agree with our QA guys though, if I enter a valid (and exact) key, why does the search box pop up? It makes data entry much slower than it should be.
Thanks for the info Frank.
Similar Messages
-
When subquery returns multiple rows
I have a doubt in this case. I follow Oracle SQL by example book and I find that "<=" is used in this query.
He says that when the subquery returns single row,,only then <=, >=, = should be used..
Why did they not use ANY,ALL or SOME operators.....When I use ANY,ALL ,,,it gives me an error "Invalid Relational operator"...... Please help
select c.description, s.section_no, c.cost, s.capacity
from course c, section s
where c.course_no=s.course_no
and s.capacity <= (select avg(capacity) from section)
and c.cost=(select min(cost) from course)Hi,
user11090588 wrote:
I have a doubt in this case. I follow Oracle SQL by example book and I find that "<=" is used in this query.
He says that when the subquery returns single row,,only then <=, >=, = should be used..
Why did they not use ANY,ALL or SOME operators.....If the sub-query returns no more than 1 row, then it doesn't matter which, if any, of the keywords ANY, ALL or SOME you use: they all give the same results. Only when there are 2 or more rows can it matter if you're doing the comparison to any, all or some of the rows.
When I use ANY,ALL ,,,it gives me an error "Invalid Relational operator"...... Please help
select c.description, s.section_no, c.cost, s.capacity
from course c, section s
where c.course_no=s.course_no
and s.capacity <= (select avg(capacity) from section)
and c.cost=(select min(cost) from course)If the problem occurs when you use ANY or ALL, why not post a query where you use ANY or ALL?
Post a complete script that people can use to re-create the problem and test their ideas. That includes CREATE TABLE and INSERT statements for your tables (unless you can show the problem using commonly available tables, like those in the scott schema).
Always say which version of Oracle you're using.
I can't reproduce the problem. I don't get any error using ANY, ALL, SOME or nothing before either sub-query:
SELECT d.deptno
, e.ename
, e.sal
FROM scott.dept d
JOIN scott.emp e ON d.deptno = e.deptno
WHERE e.sal <= ANY (
SELECT AVG (sal)
FROM scott.emp
AND d.deptno = SOME (
SELECT MIN (deptno)
FROM scott.dept
;Output from the query above:
` DEPTNO ENAME SAL
10 MILLER 1300I'm using Oracle 10.2.0.1.0.
Don't worry too much about ANY, ALL or SOME before sub-queries. I've never seen them used outside of a textbook (or questions like this, taken from a textbook). In real life, nobody uses them.
Someone once showed me any example where one of these actually would be useful if you didn't have analytic functions, but I didn't note what it was, or where I saw it. Analytic functions were introduced in Oracle 8.1, so that's only of historical interest now. -
The simplest way for plsql procedure to return multiple rows
Hi,
What is the simplest way for plsql procedure to return multiple rows (records). There are many combination of ways to do it but I am looking for a solution that is appropriate for plsql beginners. Many solutions use cursors, cursor variables, collections and more that kind of things that are complex on the face of it. Is it somehow possible to achieve the same with less effort?
Sample query would be: SELECT * FROM EMPLOYEES;
I want to use returned rows in APEX to compose APEX SQL(in that context plsql) report.
It is enough to use just SELECT * FROM EMPLOYEES query in APEX but I want to use plsql procedure for that.
Thank you!Hi,
It depends :-).
With +...that is appropriate for plsql beginners...+ in mind... it still depends!
The list of techniques (ref cursors, cursor variables, collections, arrays, using explict SQL) you have referenced in your post can be made to work. but...
+Is it somehow possible to achieve the same with less effort?+ Less effort : That needs to be defined (measured). Especially in the context of pl/sql beginners (who is a beginner?) .
What is the level of "programming experience" ?
What is the level of understanding of "Relational Result set" as processible in Oracle?
If you are looking for
Process_the_set_of rows_in APEX () kind of capabilitywhich "abstracts/hides" relation database from developers when working on relation database, it may not be the best approach (at least strategically). Because I believe it already is abstracted enough.
I find REF CUROSOR most effective for such use, when the "begginer" has basic understanding of processing SQL result set .
So in a nut shell, the techniques (that you already are familiar with) are the tools available. I am not aware of any alternative tools (in pure Oracle) that will simplify / hide basics from develpers.
vr,
Sudhakar B. -
Pl/sql block returning multiple rows
Hi,
I've created a plsql block which obtains an id from a name and then uses this id in another sql statement. The select statement to get the id works fine and the correct id is placed into the variable awardID.
when i try to use this variable in another select statement it returns multiple rows. but when i just use the id in the select statement it works fine.
select AwardID into awardID
from award_objtabA
where Name = awardName;
this returns the correct id '5999'
select Points into award_points
from award_objtabA
where AwardID = awardID;
this returns multiple rows
select Points into award_points
from award_objtabA
where AwardID = 5999;
this works fine
can anybody help with this confusing error?
Cheersselect AwardID
into awardID <= the same column
from award_objtabA
where Name = awardName;
this returns the correct id '5999'
select Points
into award_points
from award_objtabA
where AwardID = awardID; <= the same column
this returns multiple rows
to solve use different name not exactly the same as that of the column name
select AwardID
into vAwardID
from award_objtabA
where Name = awardName;
select Points
into award_points
from award_objtabA
where AwardID = vAwardID;as Alex and Kamal have suggested use different name for your variable. -
TimesTen SQL with group by returning multiple rows
I have a Active-Standby TimesTen nodes.
Using group by with or without having clause:
Whenever I do a group by query on table1 table with or without having clause, SQL returns multiple rows. This looks very strange to me. Each time it gives different count
Command> select count(*) from table1 group by pname having pname='pool';
< 390400 >
1 row found.
Command> select count(*) from table1 group by pname having pname='pool';
< 390608 >
< 32639 >
2 rows found.
Command> select count(*) from table1 group by pname having pname='pool';
< 2394 >
< 351057 >
2 rows found.
Command> select count(*) from table1 group by pname having pname='pool';
< 305732 >
1 row found.
Command> select count(*) from table1 group by pname having pname='pool';
< 420783 >
1 row found.
Command> select count(*),pool_name from root.rms_address_pools group by pool_name order by pool_name;
< *435473, pool* >
< *32313, pool* >
< 453, smvG3 >
< *28980, pool* >
< 3786, smvG4 >
< *26025, pool* >
< 236120, smvG6 >
< 131455, smcG3 >
< *65150, pool* >
< 23, snt1G1 >
< 510, snt2G1 >
< 510, snt2G2 >
Using where clause:
Command> select count(*) from table1 where pname='pool';
< *442354* >
1 row found.
Command> select count(*) from table1 where pname='pool';
< 442354 >
1 row found.
Table description:
Command> desc table1;
Table table1:
Columns:
*IP_ADDRESS BIGINT NOT NULL
PNAME CHAR (32) NOT NULL
SITEID TINYINT NOT NULL
1 table found.
ttVersion:
bash-3.00# ./ttVersion
TimesTen Release *7.0.3.1.0 (64 bit Solaris)* (tt70:17001) 2007-10-30T22:17:07Z
Instance admin: root
Instance home directory: /TimesTen/tt70
Daemon home directory: /var/TimesTen/tt70
bash-3.00#
Could any one suggest what is wrong with my SQL? or is it a bug with TimesTen?
Many thanks in advance.
Br,
BrijHi Gena,
When i execute the query with where clause, it gives me the output with more than one pool:
Command> select pname, count (*) from table1 where pname='pool' group by pname ;
< smcG3 , 18836 >
< pool , 423527 >
2 rows found.
Command> select pname, count (*) from table1 where pname='pool' group by pname ;
< intG302 , 17202 >
< pool , 425159 >
2 rows found.
While if give use the having clause it gives me multiple rows for one pool only ( sometimes) :
select pname, count (*) from table1 group by pname having pname='pool';
< pool , 32686 >
< pool , 420445 >
2 rows found.
select pname, count (*) from table1 group by pname having pname='pool';
< pool , 393574 >
< pool , 5838 >
< pool , 110943 >
3 rows found.
Command> select pname, count (*) from table1 group by pname having pname='pool';
< pool , 414590 >
< pool , 8395 >
2 rows found.
Please suggest what can be done in this case, need i open a case with Oracle for this.
Regards, Brij -
Problem with database control returning multiple rows as Array using Oracle
Has anybody using Oracle gotten a Database control that
returns multiple rows to work returning an array?
The only way I can seem to return multiple rows is by returning
a RowSet. Returning an array gives me a NullPointerException
(when called within a pageFlow). When calling a database control
that returns an array from a web service I get a
"java.sql.SQLException: ResultSet has no more data." error.
The samples using the pointbase database seem to work, but when I
converted the CustomerDBClient web service to use Oracle, it starts
failing on calling the database control that returns an array
with: "java.sql.SQLException: ResultSet has no more data."
Has anybody gotten this to work using Oracle?
I'm also having some problem returning an Iterator. It seems
to work when called from a web service, but returns nothing
if called from a page flow.
I'm using Oracle 8.1.7 and WebLogic 8.1.
EricDo you need a particular service pack installed to return an array of custom object?
I am getting a ResultSet contained no data error when trying.
Thanks,
-Thomas
"Robin Karlin" <[email protected]> wrote:
>
Eddie O'Neil <[email protected]> wrote:
All--
Unfortunately, returning an Iterator to a JPF (or JSP) from a
database control is broken in WLW 8.1, though it will work inside of
a
JWS or JCS.
There shouldn't be a problem with returning an array of objects out
of Oracle to the JPF, and if you need an Iterator specifically, youcan
wrap the array in an Iterator implementation.
Sorry for the inconvenience.
Eddie
Lenny wrote:
I have gotten it to work on Oracle using Array:)
However, I haven't gotten it to work on Oracle using Iterator:( Itis so
simple, but doesn't work:(
"Eric Dokken" <[email protected]> wrote in message
news:[email protected]...
Has anybody using Oracle gotten a Database control that
returns multiple rows to work returning an array?
The only way I can seem to return multiple rows is by returning
a RowSet. Returning an array gives me a NullPointerException
(when called within a pageFlow). When calling a database control
that returns an array from a web service I get a
"java.sql.SQLException: ResultSet has no more data." error.
The samples using the pointbase database seem to work, but when I
converted the CustomerDBClient web service to use Oracle, it starts
failing on calling the database control that returns an array
with: "java.sql.SQLException: ResultSet has no more data."
Has anybody gotten this to work using Oracle?
I'm also having some problem returning an Iterator. It seems
to work when called from a web service, but returns nothing
if called from a page flow.
I'm using Oracle 8.1.7 and WebLogic 8.1.
Eric
I get the same error that Eric reported when trying to return an Array
of objects.
It is really frustrating because I can't use much of the built-in control
logic
that WLW provides. All I did was create a data pool for Oracle and a
datasource.
I modified the sample app in C:\bea81\weblogic81\samples\workshop\SamplesApp\WebApp\callJavaControl
to point to that datasource and I get the error that Eric reports above.
Can
anyone help me out????
Thanks,
Robin -
JDeveloper + WebServices, RETURN multiple rows from pl/sql
I need to return multiple rows from pl/sql procedure or function and publish it as a Web Service through JDeveloper.
I try to use ref cursor, but then found that it is impossible to use ref cursor as a return value in Web Services.
Please, help me to achieve result.Hello. I tried to make commands from article, but got errors
"C:\Program Files\Java\jdk1.6.0_18\bin\java" -jar D:\oracle\Middleware\oracle_common\modules\oracle.webservices_11.1.1\wsa.jar -plsqlAssemble -appName Echo -sql wo -dataSource jdbc/OracleManagedDS -dbConnection jdbc:oracle:thin:@192.168.246.2:1521:data -dbUser syd/manager -style rpc -use encoded
Error: Interface oracle.generated.wo: The class could not be loaded from the class path. -
Concatenate a column value across multiple rows - PDW
We are using PDW based on SQL2014. We require an efficient logic on how to concatenate a column value across multiple rows. We have the following table
T1
(CompanyID, StateCD)
Having following rows:
1 NY
1 NJ
1 CT
2 MA
2 NJ
2 VA
3 FL
3 CA
We need a code snippet which will return following result set:
1
CT,NJ,NY
2
MA,NJ,VA
3
CA,FL
We have tried built-in function STUFF with FOR XML PATH clause and it is not supported in PDW. So, we need a fast alternative.Hi Try this:
SELECT * INTO #ABC
FROM
SELECT 1 AS ID,'NY' AS NAME
UNION
SELECT 1 AS ID,'NJ' AS NAME
UNION
SELECT 1 AS ID,'CT' AS NAME
UNION
SELECT 2 AS ID,'MA' AS NAME
UNION
SELECT 2 AS ID,'NJ' AS NAME
UNION
SELECT 2 AS ID,'VA' AS NAME
UNION
SELECT 3 AS ID,'FL' AS NAME
UNION
SELECT 3 AS ID,'CA' AS NAME
)A
CREATE TABLE ##CDB (ID INT, NAME NVARCHAR(800))
DECLARE @TMP VARCHAR(MAX),
@V_MIN INT,
@V_MAX INT,
@V_COUNT INT
SELECT @V_MIN=MIN(ID),@V_MAX=MAX(ID) FROM #ABC
SET @V_COUNT=@V_MIN
WHILE @V_COUNT<=@V_MAX
BEGIN
SET @TMP = '' SELECT @TMP = @TMP + CONVERT(VARCHAR,NAME) + ', ' FROM #ABC
WHERE ID=@V_COUNT
INSERT INTO ##CDB (ID, NAME) SELECT @V_COUNT AS ID ,CAST(SUBSTRING(@TMP, 0, LEN(@TMP)) AS VARCHAR(8000)) AS NAME
SET @V_COUNT=@V_COUNT+1
END
SELECT * FROM ##CDB
OR
SELECT * INTO #ABC
FROM
SELECT 1 AS ID,'NY' AS NAME
UNION
SELECT 1 AS ID,'NJ' AS NAME
UNION
SELECT 1 AS ID,'CT' AS NAME
UNION
SELECT 2 AS ID,'MA' AS NAME
UNION
SELECT 2 AS ID,'NJ' AS NAME
UNION
SELECT 2 AS ID,'VA' AS NAME
UNION
SELECT 3 AS ID,'FL' AS NAME
UNION
SELECT 3 AS ID,'CA' AS NAME
UNION
SELECT 5 AS ID,'LG' AS NAME
UNION
SELECT 5 AS ID,'AP' AS NAME
)A
CREATE TABLE ##CDB (ID INT, NAME NVARCHAR(800))
DECLARE @TMP VARCHAR(MAX),
@V_MIN INT,
@V_MAX INT,
@V_COUNT INT
SELECT @V_MIN=MIN(ID),@V_MAX=MAX(ID) FROM #ABC
SET @V_COUNT=@V_MIN
WHILE @V_COUNT<=@V_MAX
BEGIN
SET @TMP = '' SELECT @TMP = @TMP + CONVERT(VARCHAR,NAME) + ', ' FROM #ABC
WHERE ID=@V_COUNT
SELECT @V_COUNT AS ID ,CAST(SUBSTRING(@TMP, 0, LEN(@TMP)) AS VARCHAR(8000)) AS NAME INTO #TEMP
INSERT INTO ##CDB (ID, NAME) SELECT ID, NAME FROM #TEMP WHERE NAME<>''
DROP TABLE #TEMP
SET @V_COUNT=@V_COUNT+1
END
SELECT * FROM ##CDB
Thanks Shiven:) If Answer is Helpful, Please Vote -
How to check if "fetch" returns Multiple rows
I want to know thru some variable (like %found) if the "fetch" returns multiple rows. How can I do it?
My code:
open tab1_rec for
'select fld1 ' ||
'from tab1 f ' ||
'where f.fld3 = :s1 and ' ||
'f.fld4 = :s2 and ' ||
'f.fld5 = 1 '
using fld3_in,
fld4_in;
fetch tab1_rec into var1;
-- If MULTIPLE
if tab1_rec%multiple
ThanksIf returning more than one row is unusual in some way (that is you are expecting only a single row) then you can do it like:
BEGIN
SELECT fld1 INTO var1
FROM tab1 f
WHERE f.fld3 = fld3_in and
f.fld4 = fld4_in and
f.fld5 = 1;
< Do your processing here >
EXCEPTION
WHEN NO_DATA_FOUND THEN
< handle no rows >
WHEN TOO_MANY_ROWS THEN
< handle multiple rows >
END;No need for a cursor here. If you are expecting more than one row, and just want to know the count for information purposes, then you have to loop and fetch the records.
HTH
John -
How to create a function that returns multiple rows in table
Dear all,
I want to create a funtion that returns multiple rows from the table (ex: gl_balances). I done following:
-- Create type (successfull)
Create or replace type tp_gl_balance as Object
PERIOD_NAME VARCHAR2(15),
CURRENCY_CODE VARCHAR2(15),
PERIOD_TYPE VARCHAR2(15),
PERIOD_YEAR NUMBER(15),
BEGIN_BALANCE_DR NUMBER,
BEGIN_BALANCE_CR NUMBER
-- successfull
create type tp_tbl_gl_balance as table of tp_gl_balance;
but i create a function for return some rows from gl_balances, i can't compile it
create or replace function f_gl_balance(p_period varchar2) return tp_tbl_gl_balance pipelined
as
begin
return
(select gb.period_name, gb.currency_code, gb.period_type, gb.period_year, gb.begin_balance_dr, gb.begin_balance_cr
from gl_balances gb
where gb.period_name = p_period);
end;
I also try
create or replace function f_gl_balance(p_period varchar2) return tp_tbl_gl_balance pipelined
as
begin
select gb.period_name, gb.currency_code, gb.period_type, gb.period_year, gb.begin_balance_dr, gb.begin_balance_cr
from gl_balances gb
where gb.period_name = p_period;
return;
end;
Please help me solve this function.
thanks and best reguardhi,
Use TABLE FUNCTIONS,
[http://www.oracle-base.com/articles/9i/PipelinedTableFunctions9i.php]
Regards,
Danish -
How To Concatenate Column Values from Multiple Rows into a Single Column?
How do I create a SQL query that will concatenate column values from multiple rows into a single column?
Last First Code
Lesand Danny 1
Lesand Danny 2
Lesand Danny 3
Benedi Eric 7
Benedi Eric 14
Result should look like:
Last First Codes
Lesand Danny 1,2,3
Benedi Eric 7,14
Thanks,
David JohnsonStarting with Oracle 9i
select last, first, substr(max(sys_connect_by_path(code,',')),2) codes
from
(select last, first, code, row_number() over(partition by last, first order by code) rn
from a)
connect by last = prior last and first = prior first and prior rn = rn -1
start with rn = 1
group by last, first
LAST FIRST CODES
Lesand Danny 1,2,3
Benedi Eric 7,14Regards
Dmytro -
How do I edit or enter values on multiple sheets at the same time in Numbers? I can do it in Excel but I don't the procedure in Numbers. Thank you!
The only I way I can think of to modify a single value and have that value change in multipl locations is to have all "the other places" reference a single cell. There is not way without a referene to modify a set of cells simulateously.
This may be something like what you want:
Enter a value in the table "Original Data" cell A1 and the A1 cells of tables Ref1, Ref2 and Ref2-1 will change -
Custom database functoid to return multiple rows from database
Hi,
I have created a custom database fucntoid to execute a stored procedure which returns just single row from the database.But I could not manage to return multiple rows from the database.
Does anyone know how to return multiple rows from DB and create a node with that many occurrences in the target schema?
Thanks
JBIf you want to do this in messaging-only way without orchestration, then only option let to you is using .NET in BizTalk:
We had similar requirement with one of our clients, where they didn’t want to use orchestration (though we emphasised on less impact orch would have compared to manageability),
they still wanted to have pure-messaging only.
We extended the custom XslTransform component that ships with BizTalk SDK (<BizTalk installation directory>\SDK\Samples\Pipelines\XslTransformComponent)).
Created a custom disassembler pipeline component, used the XslTransform component from SDK to execute the map’s XSLT. Here we created a map with every links except the database ones. After executing the map, access the database, execute the store procedure
which returns more than one row/dataset, enrich the XSLT transformed message with the dataset from your database in disassembler.
Since .NET gives you the flexibility of access the dataset with more than one row, you can enrich the message in custom pipeline code.
Other option is code the message transformation completely in .NET code in custom disassembler by passing the received message to method/code which would code the map/enrichment.
While enriching you can execute the store procedure which returns more than one row/dataset, enrich the message further with the dataset from db.
If this answers your question please mark it accordingly. If this post is helpful, please vote as helpful by clicking the upward arrow mark next to my reply. -
Procedure from PowerBuilder returning multiple rows
In want to call a procedure from PowerBuilder which return multiple rows. I would like to know how to write the procedure and also how to call it. I tried using REFCURSOR , but i heard that Powerbuilder doesnot support REFCURSOR . Please help
Thanks in advanceThis is not a PL/SQL qustion, but a Powerbuilder question.
Just what SQL constructs does Powerbuilder supports? And if there is no support for ref cursors, then the choice of using a client language that lacks basic core SQL support is questionable. -
Print Child SQL which is returning multiple rows to single colum.
I have a requirement to print both Parent and Child SQLs rows to single row.
For Ex:
Parent row is returning single row
Id, Name, Primary Rate.
101, LName,FName ,30
Child row is returning multiple rows
Id, Name, Secondary Rate
101, LName,FName,15
101, LName,FName,10
The end result should be
101,LName,FName,30,15,10
Any suggestions please?Below is the XML TAG
<LIST_EMPLOYEERATE>
<EMPLOYEERATE>
<EMPNUMBER>112</EMPNUMBER>
<EMPNAME>Aaron</EMPNAME>
<PAYRATE>38.09</PAYRATE>
<JOBNAME>Technician</JOBNAME>
<EMPTYPE>Salary</EMPTYPE>
<LIST_ADDRATE>
<ADDRATE>
<ADDPAYRATE>26</ADDPAYRATE>
</ADDRATE>
<ADDRATE>
<ADDPAYRATE>7.9</ADDPAYRATE>
</ADDRATE>
</LIST_ADDRATE>
</EMPLOYEERATE>
</LIST_EMPLOYEERATE>
The Result should be (assume this is going onto excel spread sheet)
EmpNum EmpName Rate EmpType Rate1 Rate2
112 Aaron 38.09 Salary 26 7.9
Using @inline we are able to get 26 and 7.9 on the same line, but how to push 7.9 to next column?
Thanks!
Maybe you are looking for
-
I keep on getting this error when i try to copy files to my 2T Time Capsule, Please help im running out of space on my MacBook Pro.... The operation can't be completed because an unexpected error occurred (error code -50)
-
Why does Illustrator CS 5.1 crash on save?
I am running Windows XP and my Illustrator CS 5.1 crashes every time I try to save. I have made sure that my print spooler is running, and I have also restarted the service as well. The only file format I can save it in is .fxg (none of the others wo
-
Lightroom 3 and external hard drive import issues
So here is my situation. I just came from a PC to a new MacBook Pro. Intially all my phots from over the years got imported into iPhoto. But I don't want to use iPhoto because I bought LR3. So I copied all my photos (manually) out of the iPhoto direc
-
ITunes 9.2 update problem
Hi! I've been trying unsuccessfully to update to iTunes 9.2. It says a programme needed to complete the installation is missing in the installation software. I haven't uninstalled iTunes yet, only tried to update a few times with the same result. Any
-
Upgrade to CS4: from CS2 upgrade / Photoshop 3.0 Full
Ok, I've decided to go to CS4 from CS2 on my Intel Mac. Yeah I bought CS2 unknowingly for my Intel Mac and have not been happy with the performance. Are there any special install procedures for doing a fresh install of CS4 upgrade on Snow Leopard 10