Setting the filter to restrict the data based on processing period
Hi all,
Hope someone might be able to help me - OBIEE 11.1.1.5 - I have an RPD very simple just two tables (nothing coomplex).
Here is the scenario - after every month end close the user will run the report from the dashboard by selecting the processing period like 20111130 (NOV close) processing period is a varchar(8) in the table, once the user selects the 20111130 i need to get the dataset for the last 12 months which is based on a different field called EMP HIRE DATE (this field includes the data values from 2005 onwards but i only need last 12 months) in this example l need to set the filter so that i only get the data from DEC 2010 - I was able to get this done using the SQL in TOAD against oracle 11 - but i am not sure how to set this as a filter in BI answers/dashboard
The below is my filter in TOAD but not sure how i can accomplish this in OBIEE - PROCESSING_PERIOD is VARCHAR(8) , EMP_HIRE_DT is DATE
EMP_HIRE_DT BETWEEN ADD_MONTHS(TO_DATE(SUBSTR(PROCESSING_PERIOD,1,6),'YYYYMM'),-11) AND LAST_DAY(TO_DATE(SUBSTR(PROCESSING_PERIOD,1,6),'YYYYMM'))
i really appreciate any help
Thanks.
I also found that what was happening is that the state was being correctly set, but the List was overriding the state with its built in selected and hovered state. The renderer would have a stepper, but as soon as the mouse moved over it it would change state. I even tried deleting all the states in the states array except "normal" and "stepper" , but it would still change out of "stepper".
Also, the buttons on the item renderer would also cause the item renderer to change states when their states changed.
So, for this case, to get it done I changed from a states model to a visibility model, and that works fine:
// if a recipe is a cocktail, switch state to display numeric stepper
if (XML(data).@course == "cocktails") {
stepperGroup.visible = true;
stepperGroup.includeInLayout = true;
doubleItGroup.visible = false;
doubleItGroup.includeInLayout = false;
} else {
stepperGroup.visible = false;
stepperGroup.includeInLayout = false;
doubleItGroup.visible = true;
doubleItGroup.includeInLayout = true;
Similar Messages
-
How to set the Data Synchronisation mode for ADF BC component?
Hi All,
How to set the Data Synchronisation mode for ADF BC component
Thanks
RaghavendraCan you clarify what you mean by the data synchronization mode?
If you mean the Sync Mode, then in 10.1.3 you set this property by:
1. Selecting your DataBindings.cpx file
2. Expanding the "Data Control Usages" section in the structure window
3. Selecting the ADFBC-based data control
4. Setting the "syncMode" property in the property inspector. -
Trying to programmatically set the data-source for a Crystal reports report.
I've got the following existing procedure that I need to add to in order to programmatically set the data-source (server, database, username, and password) for a Crystal reports report.
I added the connectionInfo parts, but can’t figure out how to attach this to the existing
this._report object.
This is currently getting the connection data from the report file, but I now need to populate this connection data from a 'config.xml' text file.
Am I trying to do this all wrong?
using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using CrystalDecisions.CrystalReports.Engine;
using WGS.Reports.Reports;
using CrystalDecisions.Shared;
using WGS.Reports.Forms;
namespace WGS.Reports
public class ReportService
ReportClass _report;
ParameterFields paramFields;
ConnectionInfo connectionInfo; // <- I added this
public ReportService()
public void DisplayReport(string reportName, int allocationNo)
if (reportName.ToLower() == "allocationexceptions")
this._report = new AllocationExceptions();
PrepareConnection(); // <- I added this
PrepareAllocationExceptionReport(allocationNo);
this.DisplayReport();
private void PrepareConnection() // <- I added this
//test - these will come from the config.xml file
this.connectionInfo = new ConnectionInfo();
this.connectionInfo.ServerName = "testserv\\test";
this.connectionInfo.DatabaseName = "testdb";
this.connectionInfo.UserID = "testuser";
this.connectionInfo.Password = "test";
this.connectionInfo.Type = ConnectionInfoType.SQL;
private void PrepareAllocationExceptionReport(int allocationNo)
this.paramFields = new ParameterFields();
this.paramFields.Clear();
ParameterField paramField = new ParameterField { ParameterFieldName = "@AllocationNo" };
ParameterDiscreteValue discreteVal = new ParameterDiscreteValue { Value = allocationNo };
paramField.CurrentValues.Add(discreteVal);
paramFields.Add(paramField);
private void DisplayReport()
frmReportViewer showReport = new frmReportViewer();
showReport.ReportViewer.ReportSource = this._report;
showReport.ReportViewer.ParameterFieldInfo = paramFields;
showReport.ShowDialog();
showReport.Dispose();
Any help would be much appreciated.Hi Garry,
Please post SAP Crystal Reports questions in their own forums here:
SAP Crystal Reports, version for Visual Studio
We don't provide support for this control now. Thanks for your understanding.
We are trying to better understand customer views on social support experience, so your participation in this interview project would be greatly appreciated if you have time. Thanks for helping make community forums a great place.
Click
HERE to participate the survey. -
How can I set the data binding between Web Dynpro & Database table
Dear friend,
I am a beginner of Web Dynpro. I want to develop my simple project like these:
1. Create my own database table via Dictionary Project such as TAB_USER and have 3 fields: USER_ID, USER_NAME, USER_POSITION and I have already deployed & archived it.
2. Create my own Web Dynpro Project, and create the input fields as User ID, User name, User position and icon 'Save' on the selection screen and I have deployed it already.
For the process, I want to input data at the screen and save the data in the table, please give me the guide line like these:
1. How can I set the data binding between Web Dynpro and Database table ?
2. Are there any nescessary steps that I will concern for this case?
Sorry if my question is simple, I had try to find solution myself, but it not found
Thanks in advances,
SeMsHi,
You can write your own connection class for establishing the connection with DB.
Ex:
public class ConnectionClass {
static Connection con = null;
public static Connection getConnection() {
try{
Context ctx = new InitialContext();
DataSource ds = (DataSource) ctx.lookup("jdbc/TSPAGE");
con = ds.getConnection();
return con;
}catch(Exception e){
return null;
You can place the above class file in src folder and you can use this class in webdynpro.
You can have another UserInfo class for reading and writing the data into the DB .
Regards, Anilkumar
PS : Refer
https://www.sdn.sap.com/irj/servlet/prt/portal/prtroot/com.sap.km.cm.docs/library/webas/java/simple java bean generator for database.pdf
Message was edited by: Anilkumar Vippagunta -
On the initial set up for apple tv it just sits there trying to set the date and time . it is a wireless setup and the ipaddress and router address is correct . I can't get by this screen. The setting is on automatic and I have picked a city in my time zone yet it still tries to set a time and date but fails.
thanksMake sure router is up to date. Try ethernet to rule out any wifi issues. Reboot ATV and router.
-
How do I programatically set the date and time of my FP-2000 in LabVIEW RT?
I checked out the following knowledgebase document which has a tool for setting the system time, but I also need to set the date:
http://zone.ni.com/devzone/explprog.nsf/ 6c163603265406328625682a006ed37d/ 37175dbc3696a1ac86256a850051097d?OpenDoc ument
How can I do this?
-JimThat is great, Steven. I also found a solution using GetSystemTime and SetSystemTime which are functions in kernel32.dll that get and set the system date-time. This function call worked on the FP-2000 that I have and should work on RT-Embeded systes, as well.
-Jim
Attachments:
GetSystemTime.vi 16 KB
SetSystemTime.vi 14 KB -
How can i set the date time year to my i pod
how can i set the date time year to my i pod touch
Hello Theodora,
You can do this via your iPod's Settings application.
B-rock -
How to split the data based on one column
Dear All,
I have the table data like this.
type quantity revenue_mny count country
a 10 10 2 India
a 20 12 3 India
b 30 15 1 India
a 35 20 2 US
b 20 10 1 US
b 60 15 1 US
I woulkd like to split the date based on type column.
For each country, for Type "a" get the sum of revenue count quanity ans same for b
and all shuld come in on row for each country.
output should be like
country revenue_mny(For a) quantity(for a) count(For a) revenue_mny(for b) quantity(for b) count(For b)
India 22 30 5 15 30 1
US 20 35 2 25 80 2
I tried the below query . its not splittng the date for each country in one row.
select country,
sum(case when type='a') then revenue_mny else 0 end ) revenue_mny_a,
sum(case when type='b' then revenue_mny else 0 end ) revenue_mny_b
sum(case when type='a' then quantity else 0 end) quantity_a,
sum(case when type='b' then quantity else 0 end) quantity_b from
test
group by country
Please need your heloLike this?
with t as
select 'a' type, 10 quantity, 10 revenue_mny, 2 cnt, 'India' country from dual union all
select 'a', 20, 12, 3, 'India' from dual union all
select 'b', 30, 15, 1, 'India' from dual union all
select 'a', 35, 20, 2, 'US' from dual union all
select 'b', 20, 10, 1, 'US' from dual union all
select 'b', 60, 15, 1, 'US' from dual
select country,
sum(case when type='a' then revenue_mny else 0 end ) revenue_mny_a,
sum(case when type='a' then quantity else 0 end) quantity_a,
sum(case when type='a' then cnt else 0 end) cnt_a,
sum(case when type='b' then revenue_mny else 0 end ) revenue_mny_b,
sum(case when type='b' then quantity else 0 end) quantity_b ,
sum(case when type='b' then cnt else 0 end) cnt_b
from t
group by country;result:
COUNTRY REVENUE_MNY_A QUANTITY_A CNT_A REVENUE_MNY_B QUANTITY_B CNT_B
India 22 30 5 15 30 1
US 20 35 2 25 80 2Or you can do it with a decode instead of case. The result will be the same:
with t as
select 'a' type, 10 quantity, 10 revenue_mny, 2 cnt, 'India' country from dual union all
select 'a', 20, 12, 3, 'India' from dual union all
select 'b', 30, 15, 1, 'India' from dual union all
select 'a', 35, 20, 2, 'US' from dual union all
select 'b', 20, 10, 1, 'US' from dual union all
select 'b', 60, 15, 1, 'US' from dual
select country,
sum(decode(type,'a',revenue_mny,0)) revenue_mny_a,
sum(decode(type,'a',quantity,0)) quantity_a,
sum(decode(type,'a',cnt,0)) cnt_a,
sum(decode(type,'b',revenue_mny,0)) revenue_mny_b,
sum(decode(type,'b',quantity,0)) quantity_b,
sum(decode(type,'b',cnt,0)) cnt_b
from t
group by country;(I changed tablename from TEST to T and columnname from COUNT to CNT, because you should not use reserved words as tablename or columnname.)
Edited by: hm on 09.10.2012 06:17 -
PreparedStatement set date sometimes sets the date one day behind
I have a PreparedStatement that sometimes sets the date a day behind. I am saving to a MSSQL DB with a field datetime. I have two identical PreparedStatments, one for insert and one for update. When either is executed, it will sometimes set the date back one day. It's not everytime. Every other or every third one, but it's not consistent. Any help would be appreciated.
ps.setDate(1, Util.parseSqlDate(getParam("CHARGED")));
public class Util {
public static java.sql.Date parseSqlDate(String datestr) {
DateFormat sdf = null;
if (datestr == null)
return null;
if (datestr.length() > 8) {
sdf = new SimpleDateFormat("MM/dd/yyyy");
else {
sdf = new SimpleDateFormat("MM/dd/yy");
java.util.Date d = null;
try {
d = sdf.parse(datestr);
} catch (ParseException e) {
return null;
if (d != null) {
Calendar cal = Calendar.getInstance();
cal.setTime(d);
return new java.sql.Date(cal.getTimeInMillis());
return null;
protected String getParam(String name) {
return (getParamArray(name)== null) ? null : getParamArray(name)[0];
protected String[] getParamArray(String name) {
return (String[])params.get(name);
}traigo wrote:
The database is a datetime field. Then you should be using the appropriate java jdbc time/date methods to access it rather than strings.
We are only storing the date portion. Saving with today's date should produce '2009-12-28 00:00:00.000'.
I just want to set the date to an absolute date (no time value) provided without timezones.Impossible. Since the database datatype is datetime that means that a timezone is always involved.
And java always uses timezones. Ignoring the problem doesn't make it go away. -
I've to extract the data based on the sysdate...like today dd is 11,
BM_PERF is the table name and
BM_PERF_YR,BM_PERF_MONTH,BM_NOP_CT_1........BM_NOP_CT_31 are the column names.
I've to extract the data based on the sysdate...like today dd is 11
so i've to get data from BM_NOP_CT_11 and the column names changes dynamically based on the sysdate. don't use any procedures and functions.You could always pivot it into a more convenient form for querying:
WITH t1 AS
( SELECT 2008 AS yr, 4 AS mnth
, 20 AS dy1
, 10 AS dy2
, 15 AS dy3
, 1 AS dy4
, 17 AS dy5
, 99 AS dy6
, 55 AS dy7
, 45 AS dy8
, 33 AS dy9
, 22 AS dy10
, 74 AS dy11
, 35 AS dy12
, 62 AS dy13
, 24 AS dy14
, 85 AS dy15
FROM dual )
, t2 AS
( SELECT yr
, mnth
, sys.DBMS_DEBUG_VC2COLL
(dy1,dy2,dy3,dy4,dy5,dy6,dy7,dy8,dy9,dy10,dy11,dy12,dy13,dy14,dy15)
AS day_data
FROM t1 )
SELECT t2.yr, t2.mnth, sys_op_ceg(t2.day_data,5) day_value
FROM t2;
YR MNTH DAY_VALUE
2008 4 17
1 row selected.Note that SYS_OP_CEG (first discovered by Padders) is undocumented and unsupported - for production code you'd need to pick the collection row using a WHERE clause, and for that you'd need a custom object and collection type with an attribute to hold the day number.
Message was edited by:
William Robertson
...like this:
CREATE TYPE id_value_ot AS OBJECT
( id INTEGER, val NUMBER );
CREATE TYPE id_value_tt AS TABLE OF id_value_ot ;
WITH t1 AS
( SELECT 2008 AS yr, 4 AS mnth
, 20 AS dy1
, 10 AS dy2
, 15 AS dy3
, 1 AS dy4
, 17 AS dy5
, 99 AS dy6
, 55 AS dy7
, 45 AS dy8
, 33 AS dy9
, 22 AS dy10
, 74 AS dy11
, 35 AS dy12
, 62 AS dy13
, 24 AS dy14
, 85 AS dy15
FROM dual )
, t2 AS
( SELECT yr
, mnth
, id_value_tt
( id_value_ot(1,dy1)
, id_value_ot(2,dy2)
, id_value_ot(3,dy3)
, id_value_ot(4,dy4)
, id_value_ot(5,dy5)
, id_value_ot(6,dy6)
, id_value_ot(7,dy7)
, id_value_ot(8,dy8)
, id_value_ot(9,dy9)
, id_value_ot(10,dy10)
, id_value_ot(11,dy11)
, id_value_ot(12,dy12)
, id_value_ot(13,dy13)
, id_value_ot(14,dy14)
, id_value_ot(15,dy15) )
AS day_data
FROM t1 )
SELECT yr, mnth, dd.val
FROM t2, TABLE(t2.day_data) dd
WHERE dd.id = 5;
YR MNTH VAL
2008 4 17
1 row selected. -
How to pick the data based on customer number
Hi All ,
greets....
i have a requirement to select the data based on customer number and then do furthur processing .
example:
this is some 10 dcouments in customer nr:v1000
and 20 documents in customer v2000 in a internal table how to select that,
thank s in advance.thier is an internal table which is having some 1000records.
and their is 6 customers.
in which i should pick the data based on customer number.
how to write a code for that? -
how to set the date and time in apple tv?
Welcome to the Apple Community.
Assuming this is not the first time you have used your Apple TV
You might try restarting the Apple TV by removing ALL the cables for 30 seconds.
Also try restarting the router. (Also try removing it’s power cord for at least 30 seconds)
If the problem persists, try a restore, you may want to try the previous procedures several times before doing this.
If restoring from the Apple TV doesn't help, try restoring from iTunes using a USB cable.
If this is a new Apple TV, in addition to trying the above, it may also be that your network router is not allowing access to the timeserver, check that your router allows access over port 123. -
Setting the date and time on my Verve 450 answerin...
I have set the time and date on all the handsets, but when we pick up a voicemail, the date and time on the message bears no relation to reality! The instructions do not provide any advice on setting the date and time on the answering machine.
Well after i change it it seems fine, but when i use it another time it has been changed.
-
How to set the date picker to display only months?
I am trying to set the date picker in SSRS 2012 to allow the user just to select the months: and when I run my store procedure I get a can't convert data type from nvarchar to datetime. If I don't comment out of the Where Clause, nothing
is returned if I leave the Where Clause in.
Alter
PROCEDURE RollingReportList
AS
BEGIN
SET NOCOUNT
ON;
SELECT
distinct
[ItemDescription]
,[QuantityOrdered]
,QuanitityCost
= [QuantityOrdered]
* [Price]
,Convert(datetime,(CONVERT(CHAR(4),PE.[LastUpdated],107)
+ '-'
+ (right(CONVERT(CHAR(4),PE.[LastUpdated],112),2))))
as CurrentMonth
,Convert(datetime,(CONVERT(CHAR(3),Datename(MONTH,DATEADD(MONTH,1,PE.LastUpdated)),107)
+ '-'
+ (right(CONVERT(CHAR(4),PE.[LastUpdated],112),2))))
as NextMonth
,Name
FROM
[HQStore].[dbo].[PurchaseOrderEntry]
as PE
inner join
[HQStore].[dbo].[PurchaseOrder]
as PO
on PE.[PurchaseOrderID]
= PO.[ID]
inner join
[HQStore].[dbo].[Store]
as ST
on PE.[storeid]=ST.ID
Where
(@Start
= '01/01/2009'
and @Last
= '12/31/2010')
End
Go
Exec
RollingReportList
Any Help?Try the below....
Where (@Start = '20090101' and @Last = '20101231')
SELECT FORMAT(getdate(), 'MM')
02
Best Regards,Uri Dimant SQL Server MVP,
http://sqlblog.com/blogs/uri_dimant/
MS SQL optimization: MS SQL Development and Optimization
MS SQL Consulting:
Large scale of database and data cleansing
Remote DBA Services:
Improves MS SQL Database Performance
SQL Server Integration Services:
Business Intelligence -
HT1551 Is setting the date and time a one-time process?
Is setting the date and time a one-time process?
What exactly do you mean? You don't know how to set the time? You set the time but something changes it?
Maybe you are looking for
-
Can anybody tell me how to easy way to solve problem with icon in forms 9i. Please write me a way in step by step Thanks
-
Payment block R , not stopping while payment to Vendor
While making MIRO, invoice has been blocked with 'R', but without releasing block system is accepting payment. What might be the reason.
-
Embedding pdf or show notes into a podcast in iweb
Is it possible to embed show notes or a pdffor download into a podcast using iweb? Either through Garage band or by editing the RSS and XML or some other way??
-
How to download Oracle 10g database (for Windows XP)
Please give me the Oracle 10g download link. So that I can download and install oracle 10g on Windows platform(windows XP)
-
Re-installing Photoshop Elements 11 for OS 10.9.4
I recently had to replace my hard drive on my Mac and now am not able to download Photoshop Elements 11 for OS 10.9.4. I am getting the error message that there is no application available to open the file. I purchased the software as a download from