Conditional Label in Reports Margin
dear friends, can I assign a conditional report label on its header margin. the values of label will be based on database fields and it will be determined by a database field. for example there r two tables, one contains values for label( say UNITS table having fields like Unit_Name, address, Phone#) and other one is INVOICE table whose invoice number will determine the values picked from UNITS table. e.g if Invoice_No is "1001" then unit_name and other values displayed in label will be "XYZ Corporation,N.Y,USA", else if invoice number is "2001" then label will be something like "ABC Corporation,WA,USA". I hope that I've given u a good understanding of my problem n u'll reply me quickly, thanx.
Hi,
It is possible to do this. Create a formula column that returns char. This should be in the query group. Make sure you have selected the fields on which the label value is based, in the report query. You can then use this column as your label.
The code will be something like
IF :invoice_no = '1001' THEN
RETURN 'XYZ';
ELSE
RETURN 'ABC';
END IF;
Hope this helps,
Monica
Similar Messages
-
Crystal report - margins problem
I have a problem with top and bottom margins in my report. In the designer view - File>Page Setup - I have the paper size (A4 210X297 cm). Both the top and bottom margins are set to 2 cm which, If I understand it correctly, printing should start exactly 2 cm from the top and end at 2 cm from the bottom of a page.
However, no matter what I do, it starts printing 1.5 cm from the top and ends at 3 cm from the bottom of a page.
I have the 'Dissociate Formatting page size and printer paper size turned off so that should not influence anything and even if it's turned on makes no difference.
In Designer view when I look at the ruler the Report Header - it is exactly 25.5 cm in length. For some reason unknown to me I can't make it any longer. If I add even 1 or 2 mm to the length, the printing spills over to a new page.
I'm printer to a HP laser printer - nothing fancy - other programs like Word prints to the same printer with no margin issues whatsoever.
I will appreciate it so much if someone can point me in the right direction, please.
Regards
DanieHi Danie,
the problem is not inside CR, not your printer, but how SBO print engine handles paper sizeing and margin. (for just one simple thing: set the margin inside SBO, and you'll notice nothing changes).
This is especially problematic with CR margins.
On load the print engine gets the paper sizes from windows, and sticks to them. In my experience, it handles the margins as CR:
fixed 2cm-s of any paper size ( this was my main problem, imagine it: printing on a 4,5*3,5 label, with 2cm margins =S, every other application did it right, from CR it was right, from CR to PDF to print it was right, from SBO PLD it was right, from SBO>CR>PDF>Print it was right, but no matter what i did, the SBO>CR>Print was using wrong margins).
Try dissociating the papersize in CR and setting custom sizes/margins, sometimes, after many trial and error that works.
I had made to date ~10 special sized/print scenario solution in CR (along many other standard sized reports), sometimes the above stated can achieved, but mostly i just add a corrected paper size to windows, set it as default and the ~100 trial and error falls back to ~15 rounds..
I'm sorry to hear your disappointed in CR, sometimes i'm also feel like that, and i completely agree that it is overrated, but i think it is a great solution for things. It's not a miracle tool, but it handles well in most default situation, and you can construct insanely complex reports with relative ease (if you lear how to utilize SQL inside CR along with Crystalsyntax). But i agree, handling papersizes it is.. well.. you know.
Lets hope will get the neat 2011 version someday to SBO..
Regards,
Daniel -
Issue in using presentation variable as filter condition in the reports
Hi,
I have an issue in using presentation variable as filter condition in my reports the details are as follows:
Details :
We want to implement the Max and Min variables through Presentation variables only.we do not want to implement it through session variables in this case.
We have two variables MIN and MAX to be used as Presentation Variables,for a column of the report (which is a quantity),so that the user wants to see the data for this column within a particular range.i.e the Min and the Max.This part has been implemented well . The issue is when the user wants to see the full data.In that case we will not pass any values to these two Presentation Variable or in other words we are not restricting the report data so we are not passing any value to the variables,this is when the report is throwing the error. we want to leave this variables blank in that case.but this is giving error.
Please suggest how can I overcome this issue.
Thanks in Advance.
Regards,
Praveeni think you have to use guided navigation for this. create two reports first is the one you are having currently and second is the one in which remove the presentation variable from the column formula. i.e. the same report with no aggregation applied.
Now create a dummy report and make it return value only when the presentation variable value is not equal to max or min. guide the report to navigate between the first and second report based on the result of the dummy report. -
Condition in the report!!! URGENT
Hi Gurus,
I am filtering a charectaristic in the report by A, B, C and D. If the characteristic type is A or B, then, the key figure has to be negative.How to achieve this using conditions in the report????
I already tried using conditions in the query, but it doesnt work. Is there any possibilities using Formula variable or replacement path variable???if so, how can I do that???
Any Help appreciated with points.
Regards,
PNK
Edited by: pnk on Mar 27, 2008 6:17 PMHi PNK,
Create a restricted key figure based on your key figure restricting the characteristics tO A and B.
Hide this restricted key figure in display properties.
Based on this restricted key figure create a formula multiplying the same by (-1).
Hope this helps,
Ajay -
can we have condition type wise report of all billing documents executed
thanks
srinivasanSee u r prices are in KONV & Billing Tables are VBRK & VBRP
VBRK is Header Table
VBRP is Detail table
Now enter billing document number in VBELN field of VBRK & extract KNUMV i.e Document Condition.
Also enter billing document number in VBELN field and material number in field of MATNR & extract Item Number POSNR,
So now u are having Document condition & item number
Put this two things in KNUMV & KPOSN fields of KONV & u will get all values in KWERT according to Condition Type.
I hope this will help u.
Regards
SWAPNIL -
How to Use MAX condition using Query Report
Hi SAP Abap Expert,
Can we use the MAX condition in Query Report (SQ01/SQ02) ?
I have created one sample query using table VBRP and VBRK then i need to use max condition to get the MAX record in VBELN.
Please Help ???Hi Ashishsingh,
According to your description, you want to know how to use MAX function in SQL Server Analysis Services MDX Query, right? In this case, please refer to the link below which describe the syntax and sample of MDX function.
http://technet.microsoft.com/en-us/library/ms145601.aspx
http://www.mdxpert.com/Functions/MDXFunction.aspx?f=64
Hope this helps.
Regards,
Charlie Liao
TechNet Community Support -
Customize the report margin while rendering
I want to customize the report margin while rendering. I am using ReportExecution2005.ReportExecutionService webservice to render report. how to customize the report margin?
I try to use deviceinfo for this and set the below device info, it is not work out. It always render the report with design time margin. Is it right approach? Are there any issue on below deviceinfo?. Thanks in advance.
<DeviceInfo><PageWidth>11in</PageWidth><PageHeight>8.5in</PageHeight><MarginTop>.25</MarginTop><MarginBottom>.25</MarginBottom><MarginLeft>.25</MarginLeft><MarginRight>.25</MarginRight></DeviceInfo>
Best Regards
Senthil
DeveloperI found the solution. Device info have has the value without metric. The below device info is correct one. Thanks to all ;)
<DeviceInfo><PageWidth>11in</PageWidth><PageHeight>8.5in</PageHeight><MarginTop>.25in</MarginTop><MarginBottom>.25in</MarginBottom><MarginLeft>.25in</MarginLeft><MarginRight>.25in</MarginRight></DeviceInfo>
Developer -
Hi,
My problem is: The paper size is 4"x2" and I've design the report
to print with no margin in report builder,
but when I print the report from the printer, the margin is added.
I would like to know how to set the report margin to 0.
If you know, please tell me asap.
Thanks in advance,There will always be some margin, since printers can only print to the edge of their printable areas (i.e., a printer cannot print to the very edge of a piece of paper).
Regards,
Danny -
Can anyone please tell me how to change the report margins so that it prints landscape.
I have changed the page setup, but this does not seem to work for the body of the report..
Thank you.Hi Tammy
Change the "Orientation" property of secion and see if it solves your problem.
Regards
Sriipathy -
How to change the label of a link based on a condition in a report.
Hi all,
I have a report, in which i created a link.
i want the the label of the link to change based on a column value.
for eg. i created report based on emp table which has a link on empno .
if the deptno of the employee is 10 i want the link to be displayed as "employee of deptno 10".
if the deptno of employee is 20 or 30 i want the link to be displayed as "others"
Thanks in advance.One way I've found to do this is to put the condition part into the select statement. Use a decode to determine which link text you want to display, e.g.,
select '<a href="yourlinkhere?employee=' || empno || '">' || decode(deptno,10,'employee of deptno 10','others') || '</a>' emplink from emp; -
Setting Margins for Mailing Labels in Reports 6i
I would like to know how to configure the margins (vertical/horizontal properties) for different mailing label formats. I am unable to correctly set them to use for Avery labels. MS Access has a great label wizard that brings up a variety of mailing label formats and allows you to choose from the list. I have found nothing similar in Oracle Reports. Have been a DBA/developer of Oracle Applications for 20+ years. Help!
Where you set the measurement ?
Did you follow this ?
@ Report Object Navigator
1. Select Layout Model >> Main Section then properties
set Width, Height and Orientation under Section
Adjust your layout and
Try...
Hope this works.. -
Localization of CrossTab row and column label Crystal Report RPT file
Dear all,
Does anyone know how to support multiple locale texts (English and French) in CrossTab Row and Column Header labels and grand total labels? Is there a way to parameterize text objects CrossTab in one single Crystal Report RPT file to use some sort of locale resource file containing text string for different languages based on the users of RPT at runtime? The idea is to use one single RPT file to generate report for different locale text for CrossTab Row and Column abels and grand total labels instead of creating RPT files per locale?Hi,
Does the database have a column that identifies the language? If it does, then you could create two separate cross-tabs and place them in different sections and conditionally suppress the section depending on the language from the database.
That's the only thing that can be done in my opinion.
-Abhilash -
Conditional formula in report painter.
Hello.
I create new CO-PA report in KE31 transaction which is based on a form.
In transaction KE35 I define the new form and in this form I want to create formula.
This formula should be conditional. How to define conditional formula in that kind of form.
I can also define key figure scheme in transaction KER1 but in this transaction I also don't see possibility to define
conditional formula.
Conditional formula means that some value fields should be summ and some value fields should be substract
depending on the value of characteristics.
How to solve this problem in R/3 4.6C?
I am waiting for help.
Best regards
BogdanHi,
I don't think that we can put the conditional formula. but we can do the calcualtion by row wise or column wise.
Thanks. -
Conditional links on report w/ search
I know there has a number of thread on this topic, but I could not find any addressing my issue.
I have a report with a conditional link built into the SQL:
select DECODE(LL_ACCESS, 'edit',
'<img src="/i/edit.gif" border="0" alt="Edit Icon">',
'<img src="/i/view.gif" border="0" alt="View Icon">') LL_ACCESS
,DIVISION
,LL_DATE
,CUSTOMER
,PROGRAM
,PROCESS
,MATERIAL
,PART_DESC
,DEFECT
,PROBLEM
,ROOT_CLAUSE
,SOLUTION
,COMMENTS
,ATTACHMENTS_YN
from LESSONS_LEARNED_V;
Which "links" to either an update page or a view only page based on a user ACL.
My problem arises when I'm adding a search feature to the report. I have change the report to be base on a PL/SQL statement:
declare
l_sql varchar2(4000);
begin
l_sql := '
select DECODE(LL_ACCESS, ''edit'',
''<img src="/i/edit.gif" border="0" alt="Edit Icon">'',
''<img src="/i/view.gif" border="0" alt="View Icon">'') LL_ACCESS
,LL_ID
,DIVISION
,LL_DATE
,CUSTOMER
,PROGRAM
,PROCESS
,MATERIAL
,PART_DESC
,DEFECT
,PROBLEM
,ROOT_CLAUSE
,SOLUTION
,COMMENTS
,ATTACHMENTS_YN
from LESSONS_LEARNED_V';
IF :P2_REPORT_SEARCH is NOT NULL THEN
l_sql := l_sql ||' where ';
l_sql := l_sql ||' (
upper("DIVISION") like ''%''||upper(:P2_REPORT_SEARCH)||''%'' or
upper("LL_DATE") like ''%''||upper(:P2_REPORT_SEARCH)||''%'' or
upper("CUSTOMER") like ''%''||upper(:P2_REPORT_SEARCH)||''%'' or
upper("PROGRAM") like ''%''||upper(:P2_REPORT_SEARCH)||''%'' or
upper("PROCESS") like ''%''||upper(:P2_REPORT_SEARCH)||''%'' or
upper("MATERIAL") like ''%''||upper(:P2_REPORT_SEARCH)||''%'' or
upper("PART_DESC") like ''%''||upper(:P2_REPORT_SEARCH)||''%'' or
upper("DEFECT") like ''%''||upper(:P2_REPORT_SEARCH)||''%'' or
upper("PROBLEM") like ''%''||upper(:P2_REPORT_SEARCH)||''%'' or
upper("SOLUTION") like ''%''||upper(:P2_REPORT_SEARCH)||''%'' or
upper("COMMENTS") like ''%''||upper(:P2_REPORT_SEARCH)||''%'' or
upper("ROOT_CLAUSE") like ''%''||upper(:P2_REPORT_SEARCH)||''%''
END IF;
if :P2_VALUE IS NOT NULL then
l_sql := l_sql ||' and ('||:P2_CHART_FILTER||' = :P2_VALUE) ';
end if;
return l_sql;
end;
It almost works, except the pk value (in this case LL_ID)is not being returned in the link. I have tried every possible combination of #,&,||,'," to get it to work but with no luck. Does anyone know the correct syntax to get this to work?
BTW, I'd like to thank all who have posted to this forum, it has been a create help to this old oracle forms guy.Hi Rob,
Try this
declare
l_sql varchar2(4000);
begin
l_sql := '
select DECODE(LL_ACCESS, ''edit'',
''<img src="/i/edit.gif" border="0" alt="Edit Icon">'',
''<img src="/i/view.gif" border="0" alt="View Icon">'') LL_ACCESS
,LL_ID
,DIVISION
,LL_DATE
,CUSTOMER
,PROGRAM
,PROCESS
,MATERIAL
,PART_DESC
,DEFECT
,PROBLEM
,ROOT_CLAUSE
,SOLUTION
,COMMENTS
,ATTACHMENTS_YN
from LESSONS_LEARNED_V ';
IF :P2_REPORT_SEARCH is NOT NULL THEN
l_sql := l_sql ||' where ';
l_sql := l_sql ||' (
upper("DIVISION") like ''%''||upper(:P2_REPORT_SEARCH)||''%'' or
upper("LL_DATE") like ''%''||upper(:P2_REPORT_SEARCH)||''%'' or
upper("CUSTOMER") like ''%''||upper(:P2_REPORT_SEARCH)||''%'' or
upper("PROGRAM") like ''%''||upper(:P2_REPORT_SEARCH)||''%'' or
upper("PROCESS") like ''%''||upper(:P2_REPORT_SEARCH)||''%'' or
upper("MATERIAL") like ''%''||upper(:P2_REPORT_SEARCH)||''%'' or
upper("PART_DESC") like ''%''||upper(:P2_REPORT_SEARCH)||''%'' or
upper("DEFECT") like ''%''||upper(:P2_REPORT_SEARCH)||''%'' or
upper("PROBLEM") like ''%''||upper(:P2_REPORT_SEARCH)||''%'' or
upper("SOLUTION") like ''%''||upper(:P2_REPORT_SEARCH)||''%'' or
upper("COMMENTS") like ''%''||upper(:P2_REPORT_SEARCH)||''%'' or
upper("ROOT_CLAUSE") like ''%''||upper(:P2_REPORT_SEARCH)||''%''
END IF;
if :P2_VALUE IS NOT NULL and :P2_REPORT_SEARCH is not null then
l_sql := l_sql ||' and ('||:P2_CHART_FILTER||' = :P2_VALUE) ';
elsif :P2_VALUE IS NOT NULL and :P2_REPORT_SEARCH is null then
l_sql := l_sql ||' where ('||:P2_CHART_FILTER||' = :P2_VALUE) ';
end if;
return l_sql;
end;
I changed the refrenece from #LL_ID# to a direct sql reference. Also I modified your last if condition.
Hope this Helps
Vivek -
Get condition from interactive report
Hi all!
I have an interactive report.
After the user has set some filter conditions I would like to write the ID's of the selected datasets into a table.
This should take place in an "after-submit-process" in pl/sql.
Something like:
INSERT INTO #OWNER#.log_table (OBJT_ID) VALUES (SELECT ID FORM #OWNER#.source_table WHERE
":APEX_REPORT_CONDITION");
My question:
Is there an apex-object like ":APEX_REPORT_CONDITION"?
Thanks for your help!
KaiHi Jari,
thank you for your reply. But I need s.th. different:
If I load my report-page and display "Debug" the SQL behind the report looks like:
select
null as apxws_row_pk,
+"ID",+
+"NUMBER",+
+"TITLE",+
+"ENTRY_DATE",+
+"PRIOPRITY",+
+"PROBABILITY",+
count(*) over () as apxws_row_cnt
from (
select * from (
select
r.ID,
r.NUMBER,
r.TITLE,
r.RPRI_NAME,
r.ENTRY_DATE,
r.PRIORITY,
r.PROBABILITY
from #OWNER#.MY_TABLE r
where r.usr_name = :APP_USER
+) r+
where ("PROBABILITY" = :APXWS_EXPR_1*
and "PRIORITY" = :APXWS_EXPR_2)*
+) r where rownum <= to_number(:APXWS_MAX_ROW_CNT)+
+0.44: binding: ":APP_USER"="APP_USER" value="USER"+
+0.44: IR binding: ":APXWS_EXPR_1"="APXWS_EXPR_1" value="(10-50%)"+
+0.44: IR binding: ":APXWS_EXPR_2"="APXWS_EXPR_2" value="Hoch"+
+0.44: IR binding: ":APXWS_MAX_ROW_CNT"="APXWS_MAX_ROW_CNT" value="10000"+
As we can see, apex put an own select-statement around the original statement.
What I need is the part in bold letters and the APXWS_EXPR_x-values. How can I get it?
Has anyone any ideas? Thanks in advance!
Kai
Edited by: user610935 on Nov 25, 2009 11:27 PM
Edited by: user610935 on Nov 25, 2009 11:27 PM
Maybe you are looking for
-
My iphone deleted all my music and wont let me download it again how can i fix this?
i tried plugging it into another computer and the songs do show up under music for my phone but they r gray and i cant listen to them if i click them a gray circle with an exclamation point shows up next to it
-
if i used the same apple id and email to set up both my ipad and ipod what can i do to be able to use face time to call from one device to the other
-
EJB problem (Seam 2.1.2 + WLS 10.3)
Hi, I'm having some problems getting the EJB version of the booking example in Seam 2.1.2 working with WebLogic 10.3, and I'm hoping that someone here might have some advice. I followed the instructions in Chapter 39 of the Seam documentation for bui
-
How to use ApplicationModule custom methods in JSP?
I have an ApplicationModule for which I have defined several custom methods (in the ApplicationModuleImpl class). I wish to invoke these methods from a JSP. I'm having trouble getting a scriptable reference to the application module object in the JSP
-
Issue with condition editor in integration process
Hi, Now there is the chance to use this feature for the first time. Seems to be very easy.... No, it isnt! Variable RETURN (type string) referencing to a field of a message structure is used for this condition: RETURN!="I001" So, if the variable doe