Column based on a classic report LOV
In a classic report, I want to display a value from a lov, based on the value of a column. I can't make this work, however, not even on apex.oracle.com. I am also on apex 4.1.What I've tried, this is to set the column to display as text, based on lov. I tried named static and dynamic lovs and tried to provide a definition own lov, static and dynamic. Same apex_item doesn't seem to work.
As a test, I created this on apex.oracle.com:
Classic report:
Source of the region:
Select the status, descr, status2 apex_item.text_from_lov (status, 'lov_status')
Of
(
Select the State 15, 'test for State 1' double descr
Union of all the
Select the State 30, 'test for status 2' double descr
Union of all the
Select the State 45, 'test for status 3' double descr
)
The status column on the column attributes:
Display in the form: Display text (based on LOV, does not save the State)
The list of values-> LOV named: LOV_STATUS
LOV_STATUS (shared-> value lists components):
It is a static lov with these values:
15; "' A status '.
30; "" Two "
45; ' Status of three '
60; ' Status of four '
(which could also be used as a non-designated as lov: STATIC2:15;) "Status One ', 30 '; "Rule of two", 45; "Status three ', 60; "Status of four") "
The two status of status2 column keep displays only their value, and not the "display" value I would expect from the lov.
I could use decode or case, Yes. But using a lov maintains cleaner, especially when there are more than 3 or 4 values and can be reused in several reports.
I'm using or do this wrong?
Hi Tom,
changing the order of your elements LOV (description so first and then identity).
as for example:
STATIC2: 'a status '; 15, "two Status; 30, "three Status." 45, 'Four Status' 60
Which toured (tried).
If you want to see an example of control on page 2 of the application on apex.oracle.com
WS: bklerk
User: demo
PWD: demo123
Concerning
Bottom
Tags: Database
Similar Questions
-
Bug report - classic report lov definition retained when it is no longer relevant
Hello
In January, I spotted a case where, the attributes were selected after a selection has been changed, and related fields are hidden in the dev environment.
http://www.grassroots-Oracle.com/2013/01/dynamic-action-hidden-false-actions.html
Anthony Rayner asked me on twitter for more examples, and I just found a.
Classic report - display of the column as "list of selection (query based lov).
Add sql LOV.
Replace 'report type column' or 'display as text... '. ', save.
Change to 'select list... ". '--> lov definition is displayed again.
I actually founded it after assigning the column standard report column, then copy the page - the LOV was present in the new page!
ScottScott,
Thank you for following up on that. I submitted the bug #16482841 to do this, which will be reviewed at the next major release.
Thanks again.
Kind regards
Anthony. -
Bug report? WITH the statement contained in the classic report LOV
I've defined a "list of selection with query based lov' in a column of the classic report, and if I try a clause
I get this errorwith data as (Select 4 qty from dual) select round(100/qty*(level-1)) perc, round(100/qty*(level-1)) c from data connect by level <= qty +1
WWV_FLOW_UTILITIES. ERR_LOV
ORA-06550: line 1, column 45: PLS-00428: an INTO clause in this SELECT statement
ORA-06512: at "SYS." DBMS_SYS_SQL", line 1249
ORA-06512: at "SYS." WWV_DBMS_SQL', line 930
ORA-06512: at "SYS." WWV_DBMS_SQL', line 999
ORA-06512: at "APEX_040200.WWV_FLOW_DYNAMIC_EXEC", line 695
ORA-06512: at "APEX_040200.WWV_FLOW_UTILITIES", line 927 >
It is fine when I remove the WITH and put my value inside the rest of the query.
Wait?
Request Express 4.2.1.00.08I think you just need to make it clearer to the 'engine '. :)
Try this:
select perc d, c r from ( with data as (Select 4 qty from dual) select round(100/qty*(level-1)) perc, round(100/qty*(level-1)) c from data connect by level <= qty +1 )
I found that LOV analysis can be picky sometimes.
Thank you
-Jorge -
How to set the column width in the classic report.
Dear friends
I use Apex 3.2.
I created Clasic report and I have the analytical column in my report this column I description of the problem, so I want to set the width of this column nn classic report.
I try a code in the expression of html
style = "width: 480px;" display: block; space: normal; do-size: 11px; ' >Dear Newcomb, greetings! Thank you very much for the new request, and we are pleased to confirm the availability of a single cabin in all three categories of cabin on the M.V. Mahabaahu. We wish to inform you that two departures on October 15, 2013 & 29 October 2013 (golden triangle with Cruise) are operational and attached are the prices for your kind attention. As a special promotion for October 15, 2013 start only, we offer 100 USD by reduction of the person on the triangle of gold, combined to the cruise portion. Please review and advise us to block accommodation as a result. Cordially... pepette<span>style="width: 480px; display: block; white-space: normal; font-size: 11px;">#ACTIVITY_SUMMARY#</span> {code after apply abovemention code that display me in my summary like this and not manage width of column.
How to fix Width of column in classic report. Thanks
Hi najet
Try this
#ACTIVITY_SUMMARY#
the * > * is removed.
Kind regards
Kees Vlek
-----
Company: http://www.orcado.nl
Blog: http://www.orcado.nl/blog/blogger/listings/69-kvlek
Twitter: http://www.twitter.com/skier66
If the answer to question please change replied and mark the appropriate post as correct / helpful. -
Reduction "between the column" space in a classic report
To cram more on a screen, I want to reduce by half the spacing between columns in a classic report. Is this possible with these default settings? (I know, it can probably go negative.)
Is these same control spacing inter-colonne? The space can be reduced? What is required?<tr><td><table cellpadding="0" border="0" cellspacing="0" ...
HowardHoward (in training) wrote:
@joe,If you log in here
http://Apex.Oracle.com/pls/Apex/f?p=4550:1:2807482452656:WS: APEX_EXAMPLES_01
USER: demo
PW: demoApplication BPS_f991202 page 1 shows where I'm trying to reduce the spacing between the columns.
For the region of report, I gave her a static ID
Ok. It is useful/necessary to provide a selector for a style target for a specific region and to provide greater specificity selectors to override the theme style.
and I placed the style in the header of the region as suggested.
Do not do this. The HTML specification requires that the context of the elements ofstyle elements without scope attribute is the head of page element. APEX 4.2 provides the property CSS File URL/Inline especially page for the style information can be correctly located in the page header. The header HTML property page must be used in previous versions.
I reduce all the '1px' to '0px '. I even cut the police but he seems to have no effect.
It has no effect because the CSS pasted from the above posts contains no selectors for theme/templates that you use:
Structures HTML class and ID attributes are not consistent or interchangeable in most themes APEX (more still more backward in time go you to your templates). Therefore the CSS selectors required to style the elements are not consistent or interchangeable. Your page contains a region with ID RR_COLLATERAL_SUMMARY, but it doesn't have a tbody.uReportBody or a table.uReportStandard , and therefore these rules are not applied to each of the elements on the page.
If you look at the HTML templates in the theme you are using (17 Sapphire), or inspect the page rendered with even low web Inspector IE8, required selectors can be determined, and the required stylesheet created in the HTML Header page:
That's why I keep going the importance of providing model information and its theme, and/or examples on apex.oracle.com when asking questions about the layout and Visual formatting. Without this information, proposed "solutions" are random speculation that produce only nets long and winding, time-wasting. As I said above, if you had 15 minutes creating an example on apex.oracle.com Thursday, you would have been answered in the night, instead of 4 days later.
-
Dynamic cell colors based on values - Classic report
Hello
I have a requirement where certain columns in my classic report should change the color according to the percentage.
I referred to the following code:
But my requirement is quite complicated, I already do a lot of calculations on the existing columns:SELECT e.*, CASE WHEN sal < 1000 THEN 'red' WHEN sal BETWEEN 1000 AND 2000 T wHEN 'yellow' WHEN sal > 2000 THEN 'green' END the_color FROM emp e
ex:
Can someone help me to modify this code for the column, so that cells (not lines) of my changes to report Classic color dynamically, say what percentage of the above code is > = 75 it must be green, less than 50 means red.ROUND(((COUNT(CASE WHEN class ='A' THEN 1 END)/ nullif((SUM(CASE WHEN class ='B' THEN 1 END)+ SUM(CASE WHEN class ='C' THEN 1 END)),0))*100),1) as Percentage
Thank you!Example query:
select cust.* , case when credit_limit > 5000 then 'red' else 'green' end as bg_color from ( select CUSTOMER_ID, CUST_FIRST_NAME, round(dbms_random.value(1000,9000)) as CREDIT_LIMIT from #OWNER#.DEMO_CUSTOMERS ) cust
In the definition of the column in CREDIT_LIMIT, set the HTML Expression < div style = "background-color: #BG_COLOR #" > #CREDIT_LIMIT # < / div >
See the result: http://apex.oracle.com/pls/apex/f?p=41715:3
You can also create html together in SQL but I would like to split logic (SQL) and the user interface.
Another option might be to create dynamic Action (after discounting the report area) and to create a combination of astute selector and a piece of JavaScript, but I guess it's easier. -
Columns group apex 4 classic report
Hello
Does anyone know how to group the columns classic report? I use 4 Apex.
Thank you.
AndySimple. Create a named column (model line). Use the col/colgroup HTML and th elements and the colspan attribute to structure the headers and column groups in the definition of the model lines before :
Group 1 Group 2 Empno Ename Job Mgr Hiredate Sal Comm Deptno Complete the rest of the model if necessary.
Sort a hyperlink column in the classic report
4.2.1
THM2:
Hi I have a classic report with a hyperlink column. And I need enable sorting on this. What I did is
Select '< a href = "somelink" >' | party_name | "< /a > ' party_name party_name table.
However, I just need to show the hyperlink column in the report. Couple of questions
1. How can I create party_name-based sorting logic using the updated classic sorting standard? Given that all a hyperlink names begin with < - sorting is random. I added the second party_name column an active by default sort on it, but given that the column can not be shown, is not a good way.
2. I was wondering if there is another way to sort this classic report hyperlink column as shown in the hyperlink and sorting is enabled on the report?
Thank you!
ryansun wrote:
Hi Fac586 - Yes, the requirements are not of the same report. We have several pages with the same type of aspect, however, some of them have a different feature. In this case, Yes, I too simplified it so that easier to understand. I use the hyperlinks on query sql rather that the link of the column is because we have about 5 unions in this query from different sources and each of those interviewing him, having a hypertext link and additional formatting like "BOLD", color etc, under certain conditions. Query1 will return only the party_name, the second query United would have hypertext links, the third would fat etc. The union of the request is not made to take into account this feature, but because of the nature of the data. While the apex feature works very well, the only question I hit is the hyperlink column sorting in a classic report. Where the simplified question. Individual responses, I've had have been very useful and have been applied successfully.
In this case, the request for a classic report that has column link, how to sort would work it would be on a regular character column.
Option 1 (deeply inelegant): Generate an HTML comment containing the sort at the beginning of the column value. The value must be sortable using the character comparison semantics, so dates must follow the format YYYYMMDD, numbers padded to the same length with zeros etc: Re: problem with the Date command
Option 2A: Expand the Expression HTML technique described in your previous thread (marking dynamically of columns in a "BOLD" for the highest value report) to include the tags.
Option 2b: Use the HTML Expression technique described in the previous thread to include custom data attributes and use these to add links to dynamic actions.
If this is done on several pages, and then create a view all the necessary logic and the columns which you can keep it in one place.
Balloon classic report in the column header
How can I create a ToolTip on the column header in a classic report?
Hello
Here is an example
http://dbswh.webhop.NET/HTMLDB/f?p=blog:read:0:article:1902000346637155
Kind regards
JariClassic report with column LOV
I have simple classic report (Apex 4.2.4) with two columns. One is to main table and shows the ID; another column is LOV that contains detail table names, which must FK main table.
Table structure:
master_table (id NUMBER);
detail_table (detail_name VARCHAR2 (50), master_id NUMBER);
Source report looks like:
Select
ID,
lov_column null
of master_table;
lov_column is defined as a query in function LOV and query looks like:
Select detail_name from detail_table
where master_id = #ID #.
But the application does not recognize the values #ID #? Can I use it without the WHERE statement, but in this case in LOV, I got all the records, and that I want in a folder have values only for this ID.
What can I do?
Thanks in advance.
Kiran I thank you for your care, I finally found the solution.
Apex.Oracle.com cloud works with Apex5, it is not possible to obtain a classical column LOV relation, but it is possible to do this by using APEX_ITEM. SELECT_LIST_FROM_QUERY. And so I did in my application.
in the statement I wrote:
Select
Mt.ID,
apex_item.select_list_from_query (1, null, "select dt.detail_code d, dt.detail_code r detail_table dt where dt.master_id = ' |") Mt.ID) retail
of master_table TM;
And it works!
change the color of line based on the value of column 5 Apex in the classic report
Version of the apex 5.0.0.00.31
Standard universal theme
Page theme default template
Classic report
Foldable report template
Hello
I know this question has been asked several times here, but I'm working on 5 Apex and need to know the correct way to do it in this version.
I need to change the color of the text of the entire line (no background color) based on the value in one of the columns of the classic report. I have just two conditions, if the value of column = Yes, color should be red, otherwise it must be green.
I am new to jscript and css, so appreciate if someone can tell me the solution with steps.
I have already checked this link that changes the value of the column, need to do something similar to the whole line.
https://tylermuth.WordPress.com/2007/12/01/conditional-column-formatting-in-apex/
Hi coolmaddy007-Oracle,.
Here's an example set up on the apex.oracle.com according to the specifications you gave: https://apex.oracle.com/pls/apex/f?p=35467:1
Version of the apex 5.0.0.00.31
Standard universal theme
Page theme default template
Classic report
Foldable report template
Here is how it is done:
Create a dynamic action with the following specifications:
Name: Give the appropriate name
Event: After refresh
Selection type: region
Region: select your region classic report
Condition: No strings attached
Action: Run the JavaScript Code
Fire on loading the Page: Yes
Code:
$('td[headers="JOB"]').each(function() { if ( $(this).text() === 'MANAGER' ) { $(this).closest('tr').find('td').css({"color":"red"}); } if ( $(this).text() === 'SALESMAN' ) { $(this).closest('tr').find('td').css({"color":"green"}); } if ( $(this).text() === 'CLERK' ) { $(this).closest('tr').find('td').css({"color":"blue"}); } });
NOTE: Download the selector appropriate for your knowledge $('td[headers="JOB"]') case using firebug/browser development tools.
Items concerned: leave blank.
PS: Changed the example to change the color of text instead of the background color.
I hope this helps!
Kind regards
Kiran
Select row column in classic report default beat all
Hello
Based on my previous thread how can I do the same task in classic report.
I followed your previous link to all select and clear the all check box.
even he just not all checked when the page loads.
Please help with this too.
Hi Maxence,
CORINE wrote:
Hello
Based on my previous thread how can I do the same task in classic report.
I followed your previous link to all select and clear the all check box.
even he just not all checked when the page loads.
Please help with this too.
The answer lies in the previous thread: Select the row column in report default heartbeat intractive all
I hope this helps!
Kind regards
Kiran
Functionality of the classic report checkbox column.
My requirement is
I have a classic report based on sql query in this 1st column is checkbox.
When I click on this check box, the value of the 2nd column is copied in the 4th column of the same rank.
Assume that the 2nd column value is 100 after you have clicked on the box of 100 control is copied into reports even line 4 column.
How can I do this?
You want to just copy the value of the of the sal to the text box column. Its simple javascript.
Looking at your page source I see that you call a function called spCheckChange. You use an application process in this function. Is this really necessary? The result is a heavy AJAX call.
You can simply use jQuery, if you create your report the right way i.e. add attributes to the checkbox and textbox which serve to identify which box would copy a value in what text box.
Here is a demo that I put in place.
https://Apex.Oracle.com/pls/Apex/f?p=53154:3:108154269628013:no
username: public_user
password: demo
You can take a look on how javascript code and attributes of the text box/box using your browser tools.
Kind regards
Aalami
Please check the response as helpful or correct if you find it then. Thank you!
Report view columns based on the selection of the month
Hello
I have an interactive report.
In my report, I show the columns below. Let's say the show for months salary of the EMP for this month
EmpID, ename, jan, Feb, mar, Apr, may, June, July, August, Sept, oct, nov, dec
I have two selection lists (to filter the report) in my interface. P1_MONTH and P1_YEAR. These have static LOVs.
Jan (Display) - 01 (Return)
(Display) - 02 Feb (Return) and so on.
I am facing problem while hiding under certain conditions the columns.
For example, if the user selects the month "Mar." Then the report should display
EmpID, ename, jan, Feb, mar
Another example, if the month is "Jun" then
EmpID, ename, jan, Feb, mar, Apr, may, June
So he must hide under certain conditions the columns based on selection.
I put the conditional 'view' in the column of the report for "expression of the ar-ticle/column value 1 = expression 2'.
P1_MONTH (in the expression 1)
+ 06,07,08,09,10,11,12 (in the expression for the month of June selection 2) +.
But doesn't the show/hide.
Am I missing something? Please correct me if I'm wrong.
I use APEX 4.1 & g 10 DB
Thank you in advance,
DanielThis
value of item/column expression 1 = expression 2
is equivalent to a PL/SQL expression, such as
:P1_MONTH = '06,07,08,09,10,11,12'
So maybe, select a PL/SQL expression condition and write something like that for the month of March - if I interpret correctly the your needs.
TO_NUMBER(:P1_MONTH) <= 3
Scott
Classic report - add the column "select box"?
I have a classic report and you want to add a column with a check box so that the user can select several lines and perform an action on all of the lines (delete selected, for example). Looks like it should be easy and maybe integrated features, but I don't find it. Is there a standard way to do this?
Steve
APEX 5.0
Hello
to add a box to your classic report using apex_item.checkbox like this API function:
select APEX_ITEM.CHECKBOX(p_idx=>1, p_value=>DEPTNO) as select_dept, DEPTNO as DEPTNO, DNAME as DNAME, LOC as LOC from DEPT
You can access the values checked (for example in a process page)
declare v_deleted_depts number := 0; begin FOR i in 1..APEX_APPLICATION.G_F01.count LOOP v_deleted_depts := v_deleted_depts + 1; delete from dept where deptno = APEX_APPLICATION.G_F01(i); END LOOP; :P1_DEPTCOUNT := v_deleted_depts; end;
P1_DEPTCOUNT (hidden) is just for later interaction with this procedure - for example, you want to present your users with a message of success and error custom as "Deleted & P1_DEPTCOUNT. departments. »
Maybe you would like to add an option to check all checkboxes at once. If so, read this blogpost Blog of Carl Backstrom: September 2007.
Kind regards
Pavel
Edit: don't forget to toggle the leak key for special characters not your column "checkbox.
Maybe you are looking for
-
"Jiggly" videos on different Web sites
It started suddenly two days ago! So far, the videos played perfectly. I have the latest version of Flash from Adobe and Mozilla. Suggestions welcome!
-
Satellite L - how to create a recovery disk?
Hey,. I accidentally uninstalled the program "Recovery Disc Creator". But the folder with Win Vista Recovery disc information are still in my computer. Now, I want you help me in creating a recovery disk. My system is very unstable. So I want to re i
-
In the management console Exchange 2013 why you cannot set limits of smaller than 1 GB mailboxes. Issue warning at (GB): Prohibit send at (GB): Prohibit send and receive at (GB): Does anyone know how to crush it. Thsnks Joe
-
Where can I download Vista Service Pack 1?
I had to reinstall vista 32 bit home premium to upgrade to windows 7. Windows 7 requires Vista SP1. Free download Vista SP1 is is MORE AVAILABLE. Help, please! * E-mail address is removed from the privacy *
-
Toolbars on the desktop.
The tools/ease of access bar bar went on the top of my screen. This bar still contained more quick ways to get email and IM chat and internet and the webcame integrated and much more. How can I get that back? And this isn't the sidebar with gadgets.