How to pass multiple values in a single parameter
Hi allI have a setting in my report called dept, this setting takes values in a list. I am using a sql query to populate the list. then the values available for dept are HR, FINANCE, MARKETING.
In the setting column, I checked the option "MULTIPLE SÉLECTION" AND "CAN SELECT ALL" and I select "all THE VALUES PASSED.
Now my data model sql looks like
Select * from emp where Department: dept
When I try to view the report and select ALL the list of values I don't get any results out of it. In short, I want to run my query for all values of the Department and I want that this query to run when I select ALL from the list.
Select * from emp where Department ('HR', 'FINANCE', 'MARKETING')
But I don't get all the data, is it passing null? How to solve this?
Any help will be really appreciated
Thank you
Ronny
You can change the code to sql data model looks like
select * from emp where department in (:dept )
Tags: Business Intelligence
Similar Questions
-
Hello:
How to configure contextual events publish several values of payload?
On click of a button, I'm declaritively publish a contextual event, which works very well when a single value is passed to the event handler.
My event handler method has the signature of:
eventHandler (String)
But now I also have an oracle.jbo.domain.Number, so my new eventHandler looks like this:
eventHandler (Number, String)
How to pass two values during editing of the event and how to place the payload with multiple values for the new eventHandler?
All article or code would be greatly appreciated.
Thanks for the help.You define a bean holding your values and pass an instance of the bean as a payload...
Timo
-
How to pass multiple values to a data model parameter
I have a data model, where I put a setting like this.
Select col1, col2, col3 from table1 where col1 =: param1
This works very well for a single value that I pass the param1 parameter.
How can I get this to work when I want to send multiple values for param1. I already checked the box "Multiple values" and tried to change the sql for this code.
Select col1, col2, col3 from table1 where col1 in: param1
Looks like I'm missing something here.
Thanks in advance!
Krisyou need to write it as:
Select col1, col2, col3 from table1 where col1 in (: param1)
It works for me.
Klaus
-
How to select multiple values in a single field.
Hi all
I once select stmt as below
==================================
SELECT msi.segment1,
IN l_chr_omc_item
OF SGM_INV_ITEM_ATTRIBUTES SIIA, msi mtl_system_items
WHERE msi.inventory_item_id = siia.inventory_item_id
AND siia.attribute12 = l_chr_tsb_item;
======================================
I need to print some l_chr_omc_item, but if the above query retrieves multiple values of the l_chr_omc_item for a l_chr_tsb_item so I need to print all the values. How to get all these values in a single rank.
Thanks in advance.
Published by: Shivaji M on June 28, 2009 23:18
Published by: Shivaji M on June 28, 2009 23:27cursor curGetxx (inpl_chr_tsb_item in SGM_INV_ITEM_ATTRIBUTES.attribute12%type)
is
SELECT
MSI. Segment1
Of
SGM_INV_ITEM_ATTRIBUTES SIIA
msi mtl_system_items
WHERE msi.inventory_item_id = siia.inventory_item_id
AND siia.attribute12 = inpl_chr_tsb_item;l_chr_omc_item SGM_INV_ITEM_ATTRIBUTES.attribute12%type;
vStrl_chr_omc_item varchar (500);Start
Open curGetxx (l_chr_tsb_item);
loop
extract the curGetxx in l_chr_omc_item;
When the output curGetxx % NOTFOUND;
vStrl_chr_omc_item: = concat (l_chr_omc_item, ',')
dbms_output.put_line (l_chr_omc_item);
end loop;
vStrl_chr_omc_item: = substr (vStrl_chr_omc_item, 1, length (vStrl_chr_omc_item)-1);
end;
/ -
How to pass the value entered for the parameter IN a function
Hello
I'm new to pl/sql programming.
The function below is used inside a package and the package is called in visual studio.
The function uses the input parameters 2.
Out what "in_report_parameter_id" value comes through the application of service job processor.
The second IN the parameter values are hard coded into the function.
I am not able to understand this.
If the values are hard coded, how to ensure that only the hard coded values are the right ones?
Please could someone explain?
I don't really have good idea on how to move the INPUT parameter to the function or procedure
Is there any nice document that could give me good understanding about what are the ways or types we could transmit values to the input in the subprogrammes parameter?
Thanks in advance.
Published by: user10641405 on November 19, 2009 08:16CREATE OR REPLACE FUNCTION get_class_text_str ( in_report_parameter_id IN NUMBER, in_which IN VARCHAR2 DEFAULT 'SELECT' ) RETURN VARCHAR2 IS end_text VARCHAR2 (50) := ''; my_class_text_str VARCHAR2(10000) := ''; my_class_value_str VARCHAR2(10000) := ''; CURSOR class_text(c_1_text VARCHAR2, c_2_text VARCHAR2) IS SELECT c_1_text || report_parameters.report_parameter_value || c_2_text || report_parameters.report_parameter_value || '" ' FROM report_parameters WHERE report_parameters.report_parameter_id = 3690 AND report_parameters.report_parameter_group = 'CLASS' AND report_parameters.report_parameter_name = 'CLASS' GROUP BY report_parameters.report_parameter_value ORDER BY CAST(report_parameters.report_parameter_value AS NUMBER); BEGIN IF (in_which = 'SUM') THEN OPEN class_text ( 'SUM(NVL("Class ', '", 0)) "Class ' ); ELSIF (in_which = 'PERC')THEN OPEN class_text ( 'ROUND((("Class ', '" / "Total") * 100), 2) "Class ' ); end_text := ', DECODE("Total", -1, 0, 100) "Total" '; ELSE OPEN class_text ( 'SUM(DECODE(bin_id, ', ', bin_value, 0)) "Class ' ); END IF; LOOP FETCH class_text INTO my_class_value_str; EXIT WHEN class_text%NOTFOUND; my_class_text_str := my_class_text_str || ', ' || my_class_value_str; END LOOP; CLOSE class_text; my_class_text_str := my_class_text_str || end_text; RETURN my_class_text_str; END get_class_text_str; /
Published by: user10641405 on November 19, 2009 08:30This is not a conception I would use, but should work if coded correctly. I would probably create a reference text cursor query and use a fetch of open and close.
You have 2 input parameters, in_report_parameter_id and in_which. I could not find where in_report_parameter_id has been used in the program, but the value passed to in_which is used in the logic of the FI to decide on opening the cursor. After the cursor is opened lines are to be read and possibly the cursor is closed.
The in_which values are compared to the are hard-coded. It is the programming interface to ensure that the values are the values and the measures taken are also correct. Your program is assuming that if the first 2 values are not met the third listed is the one you want.
To pass values of entry in a procedure you simply provide the values as a literal or something like variable in the call,
whatever := get_class_text_str(1,'SELECT');
-
I want to pass multiple values method AM controller
Hi all
Can someone tell me please how to pass multiple values of AM method to the controller.
Thank youYou can make use of the ArrayList
In CO
OAApplicationModlue am = pageContext.getApplicationModule(webBean); ArrayList values = (ArrayList) am.invokeMethod("PassArray");
In AM
public ArrayList PassArray { ArrayList values = new ArrayList(); values.add("value") values.trimToSize(); return values; }
Thank you
AJ -
a problem in passing multiple values in the loop settings for
Hi all
I am facing a problem in passing multiple values in the loop settings for.
EX:
CREATE or REPLACE PROCEDURE (pr_id OUT NUMBER) HAVE
tab type is table of NUMBER;
TEMP_TAB TAB;
BEGIN
Select the COLLECT LOOSE pr temp_tab pr_id;
I'm in 1.TEMP_TAB. loop of COUNTING
PR_ID: = temp_tab (i);
end loop;
END TEST;
OUTPUT:-
pr_id = 234578
in the example above, I'm only a value as an out parameter. but I send you PR_ID of the loop.
why I don't get all the values that the parameters.please offer a solution for me.
Thank you my friend.More clarification, let's look at your code...
-- create a procedure and have a single numeric out variable CREATE OR REPLACE PROCEDURE TEST ( pr_id OUT NUMBER ) AS -- declare a type as an array of numbers type tab is table of NUMBER; -- declare a varianble of that array type TEMP_TAB TAB; BEGIN -- query all the values from the table into the array select pr_id BULK COLLECT INTO temp_tab from pr; -- loop through each value in the array for i in 1..TEMP_TAB.COUNT loop -- set the value of the single OUT parameter, OVERWRITING any previous value it has PR_ID := temp_tab(i); -- loop around to the next value end loop; -- end the procedure with the final value of PR_ID END TEST;
-
How to insert multiple lines using a single query
Hi all
How to insert multiple lines using a single query to the emp table?
I have the number of rows to insert into table x. consumes a lot of time. I tried to insert several lines using a single query, but get errors. I know exactly the query to do this.
Thank you
SunilLike this?
SQL> create table test(id number , dt date); Table created. SQL> insert into test values(&a,&b); Enter value for a: 1 --- It asked me and I entered 1 Enter value for b: sysdate --- It asked me and I entered sysdate old 1: insert into test values(&a,&b) new 1: insert into test values(1,sysdate) 1 row created. SQL>
g.
-
How to pass the value of the item Application Javascript function.
Hello
I have the JavaScript in the properties attribute of the HTML Form element
I'm on page 1 and passing the value of the item page P1_DEPT_NO. It is perferctly working very well and I am able to get the exact value of the element on the page
I'm on page 1 and passing the value G_DEPT_NO of the Application element .onchange="javascript:function1($x('P1_DEPT_NO').value);"
The problem here is, I don't get the point of Application inside the javascript function value.
I tried to use alert(); and it gives me the undefined value
I just want to know, How to pass the value of the Application in Javascript element.onchange="javascript:function1($x('G_DEPT_NO').value);"
Thank you
DeepakDeepak,
I'm not a Javascript expert, but the suggestin I did was because the javascript is a case-sensitive... language and thats why onChange is not the same thing as onchange.
Not sure if this is causing the problem.Application elements not associated with a page and have therefore no properties user interface.
So, as mentioned in another post, the rendering would not work for the elements of the application.
If it is for a single item, used only on this page, you might create a hidden page element and use it fo your goalIf you want to keep watching objects application and AJAX, this page contains examples of using AJAX to solve problems like the one you mentioned.
http://www.Oracle.com/technology/OBE/hol08/apexweb20/ajax_otn.htm#T1BThank you
Rajesh. -
Does anyone know how to scan multiple pages into a single jpegfile?
When you scan a document of several pages in a file on a network each page gets its own jpeg image scanend file.
HP standalone scanner allow generally allows you to add the multuple scans in a jpeg file.
Any help much appreciated!
Thank you
Joihn
Hello
Well, I don't know how you can read many jpeg files into a SINGLE file. Put scanned images in a folder is a logical way to keep them in one place. From my understanding single jpeg image may be a ONE page document, but many jpeg images cannot be concatinated to be a multiple page document. We can use images, software publishing to put them in a single document, but still only one page (each image is smaller). Using pdf output, you can concatenate/merge a lot of images in a sinlge multi-page file.
Kind regards.
-
How to scan multiple pages into a single document using the CanoScan LiDE 200?
How to scan multiple pages into a single document using the CanoScan LiDE 200?
I can't find a way to get them to analyze all the time, or a way to put together them later.
Hi dagda24,
You can scan multiple pages into a single document with the scan PDF option. Use the following steps to do:
1. open MP Navigator.
2. click on a Clcik.
3. click Save to PC.
4. change the Type of PDF file to PDF (multiple pages).
5 other changes, as needed, and then click Scan.
-
How to scan multiple documents into a single pdf file of ADF on my MX922?
How to scan multiple documents into a single pdf file of ADF on my MX922?
-
Over my OFFICE JET PRO 8600, how to scan multiple pages into a single document?
How to scan multiple pages into a single document?
Thank you
Hi REDFIERO,
I can help you scan multiple pages to a file.
If you use a Mac, you can perform your analysis with HP Scan and when you save the file, choose PDF. Under the PDF Format you chose you will see the option to save all pages in a single file.
If you are using a Windows operating system, follow the instructions in the following document, Scanning of multiple in a single PDF Pages.
I hope this helps.
-
Hello.. I'm creating an application of streaming, in which I have a list field in a screen like this...
1
--------
2
--------
3
--------
and when the item 1 is selected means a url must be passed to the video player...
I created the list field screen in a package and a video player in other package... but I do not know how to pass the value of the field from the list to the player... Help, please... its URGENT...
You can get the index selected by the listname.getSelectedIndex () method and compare that value with Vector data (data store URL) .that you will give a correct value from the URL and pass it.
-
How to pass the value of the run-time file .sh by Oracle procedure
I have a file test.sh that contain
#1/bin/bash
exp test/test@orcl file=/home/oracle/dump/test.dmp log=/home/oracle/dump/test.dmp grants = Y = index constraints Y = Y = (test) owner statistics = none
Exit 0
I craete a work called Create_job_proc in this work, I want to pass the value of job_action is the location of the file test.sh to
/U01/home/Oracle/dump/test.sh and want to spend the test/test@orcl as a variable...
Please suggest me... how to pass the value of Job_Action which will replace the .sh file content test/test@orcl to the value of the time of execution as scott/tiger@hr
Thank you much Parth... It works perfectly...
Thank you all for your help...
Maybe you are looking for
-
It is a little hiccup ey the other day, while sending an email and listen to spotify, he jumped on the beat 6 times and then just stop. The hard drive is relatively new, because he had to be replaced due to recall. I was wondering how much lifespan i
-
How to find the number of pages printed on a HP Deskjet 6540?
I use a Mac, but I could also connect the printer to a PC if necessary.
-
Open the report classic on average page / registration
HelloI'm under Apex 5.0.3 on Oracle 12 c.I have a report classic that will always return 100 records with record 51 being that the user is likely to be more interested. I would like so open the report view this intermediate page. Before the Apex 5 I
-
XML data in the table using sql/plsql
Hi experts,Could you please help with the following requirement. I have the tags xml (.xml on a server file) below. I need to access this file and read the XML and insert into the db table using sql and plsql. Is it possible with the cdata below? And
-
I bought an OEM of Windows 8 64-bit of an online retailer and I was wondering if this is considered a one-time activation? Because I think about replacing my motherboard and there seems to be a lot of conflicting info on knowledge if I can transfer t