Display NULL values in iGrids as space?
Is there any way to tell the iGrid, that it should show columns containing DB NULL simply blank (e.g. one SPACE or anything else which is unvisible)? Actually NULL values are shown as "NA" for numbers resp. "---" for strings, which is rather annoying.
Hi Bodo,
Use this code to replace NULL values like "NA" or "---" with SPACE -
for (i=0; i<=objGrid.getGridObject().getRowCount(); i++)
for (j=0; j<=objGrid.getGridObject().getColumnCount(); j++)
if (objGrid.getGridObject().getCellValue(i, j) == "" ||
objGrid.getGridObject().getCellValue(i, j) == "---" ||
objGrid.getGridObject().getCellValue(i, j) == "NA")
objGrid.getGridObject().setCellValue(i, j, " ");
Another way is if you are using a stylesheet then you can modify the stylesheet to handle NULL.
Regards,
Anil
Similar Messages
-
A page is using PL/SQL script to display data. There are 2 display variables. Instead of bringing initial set of data, it displays NULL values. It "fixes" itself after changing variable values from a drop down menu. Why is that and how to fix it?
If you plan on performing all of the work under the Click event, then you won't need to worry about assigning a Script scope to the variables, but if you are planning on using those variables outside of the Event, then David's answer is the way to go.
Another option is to use a hash table as it also works around the issue with variable scope in a UI Event.
#Define at beginning of script
$hashtable = @{}
$OKButton.Add_Click({$hashtable.SelectedTemplate=$Something})
Boe Prox
Blog |
Twitter
PoshWSUS |
PoshPAIG | PoshChat |
PoshEventUI
PowerShell Deep Dives Book -
Need to display null values against table
Hi All,
I have one table in which I only need to display null values along with the rest of columns. for example
ename sal date
scott 2000 15/07/06
Michal
now my query should return---
ename sal date
michal
hare krishna
AlokMaybe it is something like this?:
michaels> select column_name || ' contains ' ||
dbms_xmlgen.getxmltype ('select sum(nvl2(' || column_name || ',0,1)) c from ' || table_name ).extract ('//text()').getnumberval() ||
' NULL values' null_columns
from cols
where table_name = 'EMP'
and dbms_xmlgen.getxmltype ('select sum(nvl2(' || column_name || ',0,1)) c from ' || table_name ).extract ('//text()').getnumberval() > 0
NULL_COLUMNS
MGR contains 1 NULL values
COMM contains 10 NULL values -
Grouping to display null values for all the missing dates
Hi SAP,
I am trying to display '0.00' value for all the missing dates in my crystal reports as follows:
17-Jan-14 40.00
18-Jan-14 0.00
19-Jan-14 0.00
20-Jan-14 80.00
However, my crystal report is showing as follows:
17-Jan-14 40.00
18-Jan-14 0.00
19-Jan-14
20-Jan-14 80.00
The missing dates with no data are group together and my '0.00' value is not. Kindly advise me the solution. The formula is shown as per attached.
Thank you.
Regards.Hi,
Thanks for your reply.
Fyi, I am using a formula field in crystal report to display "0.00" for days in between as follows:
whileprintingrecords;
if Days_Between({Command.DocDate},next({Command.DocDate}),'dd-MMM-yy') = "" then "" else "0.00"
There is another formula field in crystal report to display the missing dates in between as follows:
whileprintingrecords;
Days_Between({Command.DocDate},next({Command.DocDate}),'dd-MMM-yy')
Below is my report custom functions:
Function Days_Between (datefield as datetime, nextdatefield as datetime, format as string)
' This function is only used to display what data is missing within a specified date range...output type is text
dim thisdate as date
dim nextdate as date
dim output as string 'output is the text display
dim daysbetween as number
dim looptimes as number
looptimes = 0
daysbetween = 0
output = ""
thisdate = datevalue(datefield) + 1
nextdate = datevalue(nextdatefield)
if nextdate - thisdate > 1 then daysbetween = nextdate - thisdate else daysbetween = 1
do
if nextdate - thisdate > 1 _
then output = output + totext(thisdate, format) + chr(10) _
else _
if nextdate - thisdate > 0 _
then output = output + totext(thisdate, format)
looptimes = looptimes + 1
thisdate = thisdate + 1
loop until looptimes = daysbetween
Days_Between = output
End Function
The issue arise when when there is more than one missing dates in between but the null values ("0.00") displayed is only for the first missing dates and not for all the missing dates.
Regards,
Ting Wei -
Cannot display NULL values as 0
I am trying to display a count by dates (which I am grouping by), but when the value is null, nothing displays and the dates are not displayed either. I want to display every date in the range entered in the prompt and its respective count, even if the count is '0', I want to see a '0'.
I have tried every suggestion posted on this forum for that same issue and nothing has worked.
I have checked the boxes under Report Options for 'Convert Database NULL values to Default' and 'Convert Other NULL Values to Default'. I had also created a formula for the count and had selected 'Default Values For Nulls', and that didn't work either.
Can someone suggest something else I may need to check on my report? I can't find any solution,and I'm desperate at this point.
Thanks.You can do so but using a stored procedure.I have done this...since I have got the same requirement.
I am pasting a sample of the stored procedure.This stored procedure is created in Oracle.
create or replace procedure call_as_all_dates(
allDates IN OUT PKG_PCI_Compliance.allDates,
bDate IN solidcor.AS_SS_EVENTS.EVT_TIMESTAMP%TYPE,
eDate IN solidcor.AS_SS_EVENTS.EVT_TIMESTAMP%TYPE
as
dateDiff number;
begin
dateDiff :=TRUNC(TO_NUMBER(SUBSTR((eDate-bDate),1, INSTR(eDate-bDate,' '))));
open allDates FOR select rownum,0 as custID,to_char(null) as gName,to_char(null) as hName,trunc(bDate+ rownum) AS_DATE,to_char(null) as uName,to_char(null) as
evtName,to_char(null) as evtObject from sys.all_objects where rownum<dateDiff
union all
select rownum,asCust.ID,asGroup.NAME,ssEvents.HOST_NAME,ssEvents.evt_timestamp,ssEvents.evt_username,ssEvents.EVT_DISPLAY_NAME,ssEvents.EVT_OBJECT from solidcor.as_solidifier_groups asGroup inner join solidcor.as_ssgrp_ss_assoc ssGrpAssoc on (asGroup.GROUP_ID= ssGrpAssoc.GROUP_ID) right outer join solidcor.as_solidifiers asSf on (ssGrpAssoc.SS_ID=asSf.SS_ID) right outer join solidcor.as_ss_events ssEvents on (asSf.UUID=ssEvents.HOST_UUID) right outer join solidcor.AS_CUSTOMERS asCust on (ssEvents.CUSTOMER_ID=asCust.ID) where ssEvents.EVT_NAME in ('FILE_ATTR_SET_UPDATE', 'FILE_ATTR_CLEAR_UPDATE', 'ACL_MODIFIED', 'ACL_MODIFIED_UPDATE', 'FILE_CREATED', 'FILE_DELETED', 'FILE_MODIFIED', 'FILE_ATTR_MODIFIED', 'FILE_RENAMED', 'FILE_CREATED_UPDATE', 'FILE_DELETED_UPDATE', 'FILE_MODIFIED_UPDATE', 'FILE_ATTR_MODIFIED_UPDATE', 'FILE_RENAMED_UPDATE', 'FILE_SOLIDIFIED', 'FILE_RESOLIDIFIED', 'FILE_UNSOLIDIFIED', 'FILE_ATTR_CLEAR', 'FILE_ATTR_SET');
end;
Regards,
Amrita -
Am writing a 3 tier program. I am using java applets and mysql. One of the functions is to display values from the table in an applet. The condition is to display fields from the table that are null. I have been able to disply not null values (but not in an applet) but not null values. Can someone please tell me if it is possible and if so how. Sample code would be soooo helpful.
thanxhttp://forum.java.sun.com/thread.jsp?thread=503983&forum=48&message=2386043
-
hi how can i display the null value in th following query , where c512 got null value in position column
SELECT par.c_code,tab_to_string(cast(COLLECT(per.lastname) AS t_varchar2_tab)) AS lastname,Tab_to_string(cast(COLLECT(ATYPE.NAME) AS t_varchar2_tab)) AS POSITION
FROM SMS_PARTIES per,
SMS_ORGANISATION_CONTACTS con,
SMS_PARTIES par,
SMS_AFFILIATION_TYPES atype
WHERE per.id = con.per_id
AND par.ID = con.ORG_ID
AND ATYPE.ID = CON.ATYPE_ID
AND par.C_CODE IN ('C512','C70')
GROUP BY par.c_code
C_CODE LASTNAME POSITION
C70 Meyer,McPherson Chairperson,Treasurer
Edited by: user603350 on 2011/07/13 12:27 AM
Edited by: user603350 on 2011/07/13 12:27 AMuser603350 wrote:
i try this
SELECT par.c_code,Tab_To_String(cast(COLLECT(NVL(per.lastname,' ')) AS t_varchar2_tab)) AS lastname,
Tab_To_String(cast(COLLECT(NVL(ATYPE.NAME,' ')) AS t_varchar2_tab)) AS POSITION
FROM SMS_PARTIES per,
SMS_ORGANISATION_CONTACTS con,
SMS_PARTIES par,
SMS_AFFILIATION_TYPES atype
WHERE per.id = con.per_id
AND par.ID = con.ORG_ID
AND ATYPE.ID = CON.ATYPE_ID
AND par.C_CODE IN ('C512','C70')
GROUP BY par.c_code
but stil does not show null column it only show the c70 columnwhere is that c70 column?
do you mean this, c_code column which contains c70 data?
AND par.C_CODE IN ('C512','C70') If I understand you correctly: you want to display c_code column with null values, 'C512', and 'C70'.
AND nvl(par.C_CODE, 'C512') IN ('C512','C70') -
Keeping table description on change and not displaying NULL values
I have the table grouped by BFY and then showing by fund. I can only get the description section to show up for the first fund and then when it changes funds nothing shows up. Then when the year changes again it appears.
ex.
BFY: 2005: 0100AXXXXD
but when the fund changes from 0100AXXXXD........nothing shows up.
Also I wanted to not include any funds/years that are null. I had the following code in but it isn't stopping the null values.
<?if: SEC_ZERO_INDICATOR !=0?>
Thanks for any help.Need to see your xml data structure. Can you send me the xml and RTF file to [email protected]? I will take a look.
Thanks,
Bipuser -
Display null value:Report Filter using Show/hide report filter
Hi,
Is there any documentation from SAP BO that says "Report Filters don't display nulls."?
Report Filter as in by clicking the Show/Hide Report Filter in the Infoview toolbar.
Please help.
Thank you.Hai
u r Thread is similar to
http://www.forumtopics.com/busobj/viewtopic.php?p=848982&sid=2a66a2348c7042773baaf7bfd10241b2 -
Display null values in crosstab report.
I have a crosstab that will be sparsely populated. The datatype of the cells in the crosstab are numeric. I would like to have the cells that contain no data to have no value, but Crystal Reports inserts a zero there instead.
Is there anyway to tell CR that I want nulls to be treated as nulls and not zeros?
Thanks.
Regards,
ThanhThere is a Display String formula for fields, accessed by right-clicking the field and selecting Format Field. This is used to tell Crystal exactly what should be displayed for the field. Add the following logic (basic syntax):
if CurrentFieldValue = 0 then
formula = ""
else
formula = cstr(CurrentFieldValue, "0.00")
end if
This will cause all zero values to display as blank. I added the "0.00" parameter to the cstr() function to show that's how you tell cstr() how you want the number formatted. See the online help for cstr() for details.
HTH,
Carl -
How to display null values in the graphs, when i select a date range?
Hi,
Can you please help me in achieving the below requirement:
We have a date promt, i have selected the date range from 12-Oct-2009 to 15-Oct-2009 and clicked on the go button.
In the above date range, data is only availabe on 14-Oct-2009. here the requirement is to display as all the records (12th, 13th , 14th & 15th) in the bar graph.
Currently the graph view is displaying the data only for 14-Oct-2009 in the bar graph.
If data is not available it should display in the bar graph as empty for that particular dates.
Help is highly apprieciated.
Thanks in Advance.Check out [this post|http://obiee101.blogspot.com/2009/04/obiee-showing-zero-in-bargraph.html].
-
Cannot Save NULL value to database
I cannot save a null value through the data tab in the multi-row updates pane. It always gives me an error such as "Invalid number". It works fine through normal SQL update statement. Is there a preference somewhere to turn this on?
thanks in advance
Paul PHi Paul,
Just use the backspace key to obliterate any existing value -- that makes it null. Afterwards, if you refresh or close/reopen the object, the data tab will display any null as the value set in Tools | Preferences | Database | Advanced | Display Null Value As .
Regards,
Gary
SQL Developer Team -
Validations: Null value for LOVs
See http://htmldb.oracle.com/pls/otn/f?p=24317:239
I have a "Item is not null" validation on that LOV item. The item has "Display null value" set to Yes and a LOV of STATIC2:1,2,3
If I leave the Null return value for the item to blank, the engine defaults it to %null% and the validation "knows" that this is really the same as a null value and so it kicks in (good).
But if I change the Null return value to something like %, the validation doesn't complain, it thinks that this is a not-null value.
Why the inconsistency? Does this mean that we are expected to use the default value of the Null return value i.e. leave it blank and let the engine put in %null%?
Comments? ThanksVikas - The declarative not null validation types recognize "actual" null or %null% as null values. This equivalence holds in numerous other situtations during page processing. Why does %null% get special treatment? A convention was chosen and that's it. And it works for almost everybody in almost all situations. In other words, it's useful, if not perfect. If you want a different value, you can specify one in the LOV (as you described). Then you can recognize and convert these values to null or %null% in an after-submit computation so that validations and other mechanisms work normally. (Perhaps it would help if the Builder created such a computation for items having LOVs with specified null values.) One use case for using a specified null return value might be where you want to distinguish a POSTed "actual" null value from the selected "null" value for which you have specified a null return value. Then you can tell if the value was selected from the LOV or whether it got a null value from the item's cache or source methods.
Scott -
How to display empty space in place of null values
Hi all,
In my application, i am reteiving values from db and printing thm in a jsp page. Right now, when there is a null value in db for a particular column, i am getting the same null value in my jsp page also. I don't want to print this null value and want to keep those particular fields as blank.Where should i make this change. Can anyone help me out.Use JSTL c:out tag for that.
Try to omit scriptlets as much as possible. Use JSPs for view only and load the data using a servlet and DAO class. To display data and doing some conditional logic, you can use the JSTL tag library for that. -
Not to display the null values from data base
Hiiii.
In a jsp file i have ten check boxes.The jsp file is mapped to a servlet file for parameter requesting and to
store it in DB.
The unchecked box values has null values.All the values are store in a Mysql DB table.
Again i have to display it in a jsp page from table.
The problem am facing was,how can i display only the values in a row.it must not display the null values and the crresponding column name.
Or any other way is their like below
How i can retrieve only the selected check boxes from tht jsp file.and store in backend.
Thanks in Advance
regards,
satheesh kannanHere is a rough example that may give you some ideas:
On the JSP page:
<%if(myData.getFirstName()!=null){%>
Your First Name'
<input type="text" name="firstName" value="<%=myData.getFirstName()%>">
<%}%>
In the servlet:
String firstName= request.getParameter("firstName");
if(firstName!=null){
//write it to the database
}
Maybe you are looking for
-
Open Sales orders and delivery orders are updating credit exposure
Hi Can anyone please tell where is the setting in config in FSCM Credit management by which we can determine that even open order and deliveries(that is before accounting doc gets created) getting updated in credit exposure. Thanks a lot.
-
Dear Experts I have to create a Vendor History Report. is there any standard report for the same? if yes pls let me know. Thanks in advance Regards
-
I record on my PB G4, with Garage Band. I run instruments to a board, then to the m-audio fast track. the files are saved on a Seagate 300GB External FireWire Drive, from which i record. I understand it is caused due to the high number of tracks with
-
WGM creates new home folders with _unknown user/group, SA can't change it
A little background: In our school we've got an xserve (about 1.5 yrs old), that was having issues last year. (the OD database pretty much ate itself). in august we did a clean install of 10.5, and updated to 10.5.3 (after suffering through the AFP/O
-
This problem has just started about a week ago or so it worked fine before this Firefox works fine without Adobe I just don't know why this has happened I need Adobe I don't like to change to Google Chrome because I would have to install all my progr