Including the Date Range Criteria as part of the Title
I am using LastFullMonth (great function) as part of my criteria for a report, and want to include this data as part of the title - "Bla Bla Report for the Following Dates: mm/dd/yyyy to mm/dd/yyyy". I am sure I will need to create a custom formula, but I can't figue out how to convert the evaluation of LastFullMonth to a string, so that I can concantinate it to the rest of the title.
Much TIA
Jim Cook
I created a formula - maximum(LastFullMonth), which gave me the last day of the month, then formated it to show "Month, Year".
Similar Messages
-
In iPhoto, how can I export images with the metadata — including the title and caption information — intact as part of the image?
Check those boxes in the export dialogue - Exporting From iPhoto
LN -
How to include a date range in Search Help
Hi All,
I need to include a range for a date field in a Search help.
That is I have to add From Field and To Field for the same field in the search help.
Please advise.
Regards.If you are going to add an entirely new field (not existing in the SAP standard search), try using EEWB and for the query on that field would be a modification to the Model access class.
Regards,
Shailaja -
Hello. In an older verson of iPhoto I could includ a title or description with the photo image in an email. With the Cloud and old Mobile Me emailing directly from iPhoto ('11) I can't find a way to do it.
Any help.Use the old way and set Mail as your email client of choice in the iPhoto Preferences.
-
I can't find out how to turn on and off the window above the iTunes list that includes the title of the song, name of artist, and time remaining to a song. It seems to appear rather randomly on my iMac.
You can download a complete iPad User Guide here: http://manuals.info.apple.com/en/ipad_user_guide.pdf
Also, Good Instructions http://www.tcgeeks.com/how-to-use-ipad-2/
Apple - iPad - Guided Tours
http://www.apple.com/ipad/videos/
Watch the videos see all the amazing iPad apps in action. Learn how to use FaceTime, Mail, Safari, Videos, Maps, iBooks, App Store, and more.
You can download this guide to your iPad.
iPad User Guide for iOS 5
http://itunes.apple.com/us/book/ipad-user-guide-for-ios-5/id470308101?mt=11
Cheers, Tom -
iPad Air iOS 8.1 Stock Photo App. 14000 Photos. Overlapping date ranges in Moments. What is the criteria used for deciding after import where photos are included in Moments. I was expecting each day to have its own exclusive slot for example, not 26 - 27 January 2007 with 8 photos then 27 January 2007 1 photo. Why is there not two seperate slots, one for the 26th and one for 27th?? This makes locating photos by day more arkward than it need be and seems to follow no logic. This occurs over 150 times and is very confusing. Is this an issue or expected behaviour?
iPad Air iOS 8.1 Stock Photo App. 14000 Photos. Overlapping date ranges in Moments. What is the criteria used for deciding after import where photos are included in Moments. I was expecting each day to have its own exclusive slot for example, not 26 - 27 January 2007 with 8 photos then 27 January 2007 1 photo. Why is there not two seperate slots, one for the 26th and one for 27th?? This makes locating photos by day more arkward than it need be and seems to follow no logic. This occurs over 150 times and is very confusing. Is this an issue or expected behaviour?
-
I want to make sure that I do not have unnecessary software updates in my packages and SUGs so should I include the "Required" criteria and configure it as greater than or equal to "1"?
ThanksI concur with Peter. Using Required as a criterion is being reactive instead of proactive. Security should be proactive.
Additionally, if you do use Required, other systems could come onto the network missing older updates that you've never made available before and thus they, depending upon the exact criteria you use, may never get that update.
Jason | http://blog.configmgrftw.com | @jasonsandys -
Creation of internal table dynamically based on the Date Range entered
Hi SAPgurus,
I have been facing one issue i.e creation of internal table dynamically based on the date range entered in the selection screen. For example the date range I am giving as 06/2006 to 08/2006, it should display the Fieldcatelog dynamically, this part i have completed but the only issue I am facing is to populate the sales data into that fields.
Right now my program is displaying the ALV like this.
Ex:
<b>CSR District 06/2006 07/2006 08/2006 totals</b>
Shiva New York 10.00
Shiva new york 30.00
Shiva new york 40.00
but it should display like this
<b>CSR District 06/2006 07/2006 08/2006 totals</b>
Shiva New York 10.00 30.00 40.00
80.00
Please help me in this scenario, how to acheive like this..
Thanks & Regards,
Sivaram KandulaHi Sivaram,
I also got the same requirement . i saw rich and your code whatever you have uploaded.i have created dynamic internal table but i am facing the issue to populating the data to my dynamic internal table.
Sivaram, can you please explain your code after this.
*<dyn_table>
*tab_item.
LOOP AT tab_item.
ASSIGN COMPONENT 1 OF STRUCTURE <dyn_wa> TO <dyn_table>.
ASSIGN COMPONENT 2 OF STRUCTURE <dyn_wa> TO <dyn_table>.
* <dyn_wa> = tab_item-bztxt.
* <dyn_wa> = tab_item-total.
* APPEND <dyn_wa> TO <dyn_table>.
** <dyn_wa> = tab_item-total.
** ASSIGN tab_item-bezei TO <dyn_wa>.
* APPEND <dyn_table>.
ENDLOOP.
how you are puting the loop at tab_item. but tab_item is already commented.
can you send me the code after that.
i am sending some part of my code.
CALL METHOD cl_alv_table_create=>create_dynamic_table
EXPORTING
it_fieldcatalog = gt_fCAT1
IMPORTING
ep_table = new_table.
ASSIGN new_table->* TO <dyn_table>.
create data new_line like line of <dyn_table>.
assign new_line->* to <dyn_wa>.
select vbeln
fkart
vkorg
vtweg
fkdat
spart
fksto
from vbrk
client specified
into table gt_vbrk
where mandt = sy-mandt
and fkart in ('ZF5','ZFR')
and vkorg = '1100'
and vtweg = '20'
and fkdat in s_fkdat
and spart = '06'
and fksto = ' '.
if gt_vbrk[] is not initial.
select vbeln
fkimg
prsdt
netwr
matnr
arktx
werks
mwsbp
from vbrp
client specified
into table gt_vbrp
for all entries in gt_vbrk
where vbeln = gt_vbrk-vbeln
and werks in s_werks
and matnr in s_matnr.
endif.
select mnr ltx spras from t247
into table it_t247
where spras = 'E'.
data: lv_month1 type vbrp-prsdt,
name1(3) type c,
s_month type string,
s_month1 type string,
s_month2 type string.
* lv_netwr1 type vbrp-netwr,
* lv_mwsbp1 type vbrp-mwsbp.
loop at gt_vbrp into gs_vbrp.
gs_final2-matnr = gs_vbrp-matnr.
gs_final2-arktx = gs_vbrp-arktx.
gs_final2-fkimg = gs_vbrp-fkimg.
lv_month1 = gs_vbrp-prsdt.
read table it_t247 into wa_t247 with key mnr = lv_month1+4(2).
if sy-subrc eq 0.
name1 = wa_t247-ltx.
endif.
concatenate name1
lv_month1(4) into s_month SEPARATED BY '_' .
CONCATENATE S_MONTH 'QTY' INTO S_MONTH1 SEPARATED BY ''.
CONCATENATE S_MONTH 'VALUE' INTO S_MONTH2 SEPARATED BY ''.
gs_final2-month = s_month.
lv_netwr1 = gs_vbrp-netwr.
lv_mwsbp1 = gs_vbrp-mwsbp.
gs_final2-MONTH_QTY = S_MONTH1.
GS_FINAL2-MONTH_VAL = S_MONTH2.
gs_final2-value = lv_netwr1 + lv_mwsbp1.
append gs_final2 to gt_final2.
clear: gs_final2. "lv_name2.
endloop.
if gt_final2[] is not initial.
sort gt_final2 by matnr month ascending .
loop at gt_final2 into gs_final2.
gs_final2_01 = gs_final2.
collect gs_final2_01 into gt_final2_01.
endloop.
endif.
ENDIF..
Regards
Ankur -
Displaying different sums in the same row based on date ranges
Say I had a table like this
DECLARE @t1 TABLE (RowId INT PRIMARY KEY IDENTITY(1,1), BusinessType VARCHAR(100), SalesPerson VARCHAR(100), Category VARCHAR(100), OrderAmount DECIMAL(10,2), OrderDate DATETIME )
Now I want to get a result that is grouped first by BusinessType, then SalesPerson and include derived columns that are sums based on different date ranges.
Month-to-date = from the start of the current month to today
Month-to-date previous year = from the start of the current month to today 1 year ago
DECLARE @today DATETIME
DECLARE @today_prev_year DATETIME
DECLARE @year_start DATETIME
DECLARE @year_prev_start DATETIME
DECLARE @month_start DATETIME
DECLARE @month_prev_start DATETIME
SET @today = GETDATE();
SET @today_prev_year = DATEADD(YEAR,-1,@today)
SET @year_start = CAST('01/01/' + CAST(DATEPART(YEAR,GETDATE()) AS VARCHAR(10)) AS DATETIME);
SET @year_prev_start = DATEADD(YEAR,-1,@year_start)
SET @month_start = DATEADD(month, DATEDIFF(month, 0, @today), 0); --gets the first of the current month
SET @month_prev_start = DATEADD(YEAR,-1,@month_start); --gets the first of the current month
SELECT t.BusinessType,t.SalesPerson,t.Category
SUM(CASE WHEN o.OrderDate > @month_start AND ac.DocumentDate < @today THEN o.OrderAmount ELSE 0 END) AS MTDActualAmount
SUM(CASE WHEN o.OrderDate > @month_prev_start AND ac.DocumentDate < @today_prev_year THEN o.OrderAmount ELSE 0 END) AS MTDPrevActualAmount
FROM @t1 t
Hope this is clear as to what Im trying to do. Im ultimately going to pull this into an SSRS report, so im wondering if I can do this different SUM values in the report and handle the grouping there.
Thoughts?Based on your example (with a group by added) it should work.
However, if you incorperated a calendar table (http://social.technet.microsoft.com/wiki/contents/articles/29260.tsql-calendar-functions-and-tables.aspx)
you could lose all those manually set parameters:
DECLARE @t1 TABLE (RowId INT PRIMARY KEY IDENTITY(1,1), BusinessType VARCHAR(100), SalesPerson VARCHAR(100), Category VARCHAR(100), OrderAmount DECIMAL(10,2), OrderDate DATETIME, DocumentDate DATETIME)
INSERT INTO @t1 (BusinessType, SalesPerson, Category, OrderAmount, OrderDate, DocumentDate) VALUES
('A','Joe','CatA',10,'2015-01-01','2015-01-01'),('A','Joe','CatB',10,'2015-01-02','2015-01-01'),('A','Joe','CatA',30,'2015-01-03','2015-01-04'),('A','Joe','CatB',40,'2015-01-04','2015-01-01'),('A','Joe','CatA',100,'2015-02-01','2015-02-01'),
('A','Joe','CatB',100,'2015-02-02','2015-02-01'),('A','Joe','CatA',300,'2015-02-03','2015-02-04'),('A','Joe','CatB',400,'2015-02-04','2015-02-01'),('A','Bob','CatA',1,'2015-01-01','2015-01-01'),('A','Bob','CatB',1,'2015-01-02','2015-01-01'),
('A','Bob','CatA',3,'2015-01-03','2015-01-04'),('A','Bob','CatB',4,'2015-01-04','2015-01-01'),('A','Bob','CatA',10,'2015-02-01','2015-02-01'),('A','Bob','CatB',10,'2015-02-02','2015-02-01'),('A','Bob','CatA',30,'2015-02-03','2015-02-04'),
('A','Bob','CatB',40,'2015-02-04','2015-02-01'),('B','Joe','CatA',10,'2015-01-01','2015-01-01'),('B','Joe','CatB',10,'2015-01-02','2015-01-01'),('B','Joe','CatB',40,'2015-01-04','2015-01-01'),
('B','Joe','CatA',100,'2015-02-01','2015-02-01'),('B','Joe','CatB',100,'2015-02-02','2015-02-01'),('B','Joe','CatA',300,'2015-02-03','2015-02-04')
SELECT t.BusinessType,t.SalesPerson,t.Category,
SUM(CASE WHEN OrderDate >= monthStart AND DocumentDate < today THEN OrderAmount ELSE 0 END) AS MTDActualAmount,
SUM(CASE WHEN OrderDate BETWEEN prevMonthStart AND prevMonthENd AND DocumentDate >= yearStart THEN OrderAmount ELSE 0 END) AS MTDPrevActualAmount
FROM @t1 t
INNER JOIN calendar c
ON today = CAST(CURRENT_TIMESTAMP AS DATE)
Group by t.BusinessType,t.SalesPerson,t.Category -
Where are the facilities to add custom date ranges, indexable by Spotlight
The Finder is meant to be just that... A way to find files right?
Well lets look at a simple business scenario. I get a bill from a supplier, I pay the bill, I receive an invoice, I process the invoice through my accounting package. Now with paperless offices these days bills and invoices come electronically or are scanned electronically.
While iTunes mp3s are able to be categorised by custom date ranges such as when the album was released why cant I find files based on custom date ranges such as "Date Paid", "Date Due", "Date Received". I cant find any solution for this anywhere. There are many file tagging systems out there such as Yep and Tags which are meant to be using OpenMeta... But all they enable you to do is tag them by commonly used key words such as "Invoice" or "Bill". What if I want a custom field to put an Invoice number so that I can track it down using spotlight?
This would enable me to completely manage my office files in one clean sweep. I cant be the only one out there would would find this solution useful... Is it the case that spotlight/finder is designed in such a way that it is not possible to add custom date meta data?{quote}
What if I want a custom field to put an Invoice number so that I can track it down using spotlight?
Why wouldn't you just type in the Invoice number and have spotlight find it for you? Spotlight indexes all of the text in most type of documents. In my case, I use some Excel spreadsheets, with unique invoice numbers. I type in the number and Spotlight shows the document.
I can also type in the clients name and be shown a list of all the documents, emails, etc to or from or that mention that client. Included in the list of documents is every invoice that has that clients name in the text of the document.
If I'm looking for a particular invoice and know the clients name I type it and also something about the particular invoice that I'm looking for (like "John Smith video card") and that invoice shows up in the search.
If I'm looking for an invoice for a certain person during a certain year I just type: John Smith 2010 and those documents show up in the list at the top. -
Regarding date ranges in search criteria in oracle forms
I am using employee number,name, person type, and date ranges as search criteria in custom form.
when I enter employee number, hit the find button, I am getting the exact info in the result block.
Result block contains
employee name,personid,emp numb,org,start_date.
Similarly when I enter employee number,dept, I am getting correct values.
My question here is, when I enter date range. Iam unable to filter data.
When i enter START_DATE between nvl(:BLOCKNAME.START_DATE,'01-JAN-1901') and nvl(:BLOCKNAME.END_DATE,'31-DEC-4712') at where clause in the result block. I got data for the date range also.
if I give condition in the where clause, results are taking so much time when i search with employee name,number,dept,person type.
If i query with date, persormance is good.
Do u any know,how to prevent START_DATE between nvl(:BLOCKNAME.START_DATE,'01-JAN-1901') and nvl(:BLOCKNAME.END_DATE,'31-DEC-4712') when we search with employee name,number,dept,person type.Initailly Ididnt given any code in the where clause of the result block. I got data in the result block when i search with employee name,number,person type,dept etc except date range.
If i give date range, irrespective of the date, getting all the data.
after that i added code to the where clause of the result block. Now i am getting data for everything.
like, when i query with employee name,number,even date range also.
My question here, performance.
when I query with date range, data is coming in expected time in the result block.
when i query with dept, taking much time since date range logic exist in the where clause of the result block.
I need to restrict the where clause only to the data ranges. Where clause should not necessary for employee number,name,person type dept search criteria
Tahnks for your reply -
MDM ABAP API query to pass the date range
Hi
I want to retrieve certain data from MDM repository based on filter criteria by date stamp.
Not sure how to do it to pass the select option value in the query.
select-options: s_cdate for sy-datum obligatory .
DATA wa_query TYPE mdm_query.
DATA: v_search_date1 TYPE MDM_CDT_DATE_TIME.
data: v_datestamplow1 type string.
data: v_datestamplow type TZNTSTMPL.
concatenate s_cdate-low '000000' into v_datestamplow1
v_datestamplow = v_datestamplow1.
clear wa_query.
wa_query-parameter_code = 'Changed_On '. "Field code ( Field name )
wa_query-operator = 'EQ'.
wa_query-dimension_type = mdmif_search_dim_field. "Field search
wa_query-constraint_type = MDMIF_SEARCH_CONSTR_DATE. "Date serach
I am able to get the data when I just pass the low value from selecct option. But I dont how to pass the date range.
v_search_date1-CONTENT = v_datestamplow.
ET REFERENCE OF v_search_date1 INTO wa_query-value_low.
APPEND wa_query TO gt_query.
CALL METHOD cl_api->mo_core_service->query
EXPORTING
iv_object_type_code = 'Vendors'
it_query = gt_query
IMPORTING
et_result_set = gt_result.
II could see the below operator types . Although EQ says "Like standard select-options parameter" not sure how to pass the value.
EQ Equal to (like standard select-options parameter)
NE Not equal to (like standard select-options parameter)
LT Less than (like standard select-options parameter)
LE Less than or equal to (like standard s-o parameter)
GT Greater than (like standard select-options parameter)
GE Greater than or equal to (like standard s-o parameter
SW Starts with (MDM specific parameter)
Thanks,
Krishna.Hi,
To get the date range for select options, pass the low value with 'GE' operator and another query option with 'LE' operator for high value.
select-options: s_cdate for sy-datum obligatory .
DATA wa_query TYPE mdm_query.
DATA: v_search_date1 TYPE MDM_CDT_DATE_TIME.
data: v_datestamplow1 type string.
data: v_datestamplow type TZNTSTMPL.
concatenate s_cdate-low '000000' into v_datestamplow1
v_datestamplow = v_datestamplow1.
clear wa_query.
wa_query-parameter_code = 'Changed_On '. "Field code ( Field name )
wa_query-operator = 'GE'.
wa_query-dimension_type = mdmif_search_dim_field. "Field search
wa_query-constraint_type = MDMIF_SEARCH_CONSTR_DATE. "Date serach
GET REFERENCE OF v_search_date1 INTO wa_query-value_low.
APPEND wa_query TO gt_query.
concatenate s_cdate-high '235959' into v_datestamphigh1
v_search_date2 = v_datestamphigh1.
clear wa_query.
wa_query-parameter_code = 'Changed_On '. "Field code ( Field name )
wa_query-operator = 'LE'.
wa_query-dimension_type = mdmif_search_dim_field. "Field search
wa_query-constraint_type = MDMIF_SEARCH_CONSTR_DATE. "Date serach
GET REFERENCE OF v_search_date2 INTO wa_query-value_low.
APPEND wa_query TO gt_query.
CALL METHOD cl_api->mo_core_service->query
EXPORTING
iv_object_type_code = 'Vendors'
it_query = gt_query
IMPORTING
et_result_set = gt_result.
Thanks. -
Hi,
I have a table that records the leave for employees. Like employee id , leave start date, leave end date and total hours. I need to find out , if the start date or end date was on weekend , or if the date range includes weekends . And there is one more table that stores public holidays. I also need to check if the leave start date or end date was on the public holiday or the range includes any public holidays.
ThanksHi,
Assuming the time of day for all the dates involved is the same (e.g., if they are all TRUNCated DATEs, where the time is 00:00:00), that leave_start_date <= leave_end_date, and that the weekend consiists of Saturday and Sunday, you can do something like this:
SELECT leave_start_date
, leave_end_date
, CASE
WHEN TRUNC (leave_start_date, 'IW') < TRUNC (leave_end_date + 2, 'IW')
THEN 'Includes Saturday or Sunday'
ELSE 'No weekend'
END AS weekend
, CASE
WHEN EXISTS (
SELECT 1
FROM holiday_table
WHERE holiday_date BETWEEN m.leave_start_date
AND m.leave_end_date
THEN 'Leave includes at least 1 holiday'
ELSE 'No holidays'
END AS holiday
FROM leave_table m
;This does not depend on your NLS settings.
I hope this answers your question.
If not, post a little sample data (CREATE TABLE and INSERT statements, relevant columns only) for both tables, and also post the results you want from that data, as Andy requested.
Explain, using specific examples, how you get those results from that data.
Always say which version of Oracle you're using. -
Include weekends in date range
Hello,
I have a query that aggregates a value based on a date range and excludes business hours. I need to INCLUDE Saturday and Sunday based on the date range. I am stuck and I think I am at that time of day where your brain decides to quit. Time for some coffee :)
Here is what I have so far and as always, thank you all very much for your help!
declare @StartDate datetime, @EndDate datetime
set @StartDate = '6/1/2013'
set @EndDate = '6/30/2013'
Select sum(abncalls)
from TABLE
where date between @StartDate) and (@EndDate)
and starttime not in (800,830,900,930,1000,1030,1100,1130,1200,1230,1300,1330,1400,1430,1500,1530,1600,1630)
Dave SQL DeveloperSomething like this you are looking for
Declare
@beginDate Date,
@EndDate Date
set @beginDate = '1/15/2014'
set @EndDate = '1/30/2014'
Declare @Calendar Table
(CalendarDate Date Primary key, IsWeekend Bit)
While @beginDate <= @endDate
Begin
Insert Into @Calendar
Select
@beginDate As CalendarDate
,(Case When DATEPART(Weekday, @beginDate) In (7, 1) Then 1 Else 0 End) As IsWeekend
Set @beginDate = DateAdd(Day, 1, @beginDate)
End
Select CalendarDate From @Calendar Where IsWeekend = 1
Select sum(abncalls)
from TABLE
where date in(Select CalendarDate From @Calendar Where IsWeekend = 1 )
and starttime not in (800,830,900,930,1000,1030,1100,1130,1200,1230,1300,1330,1400,1430,1500,1530,1600,1630)
-Prashanth -
LX25 displays wrong data for the entered date range
System says "Inventory not executed" status for the bins even if Inventory is executed for the bins in the date range provided in the selection screen.
For e.g.
I execute report for Warehouse XYZ. I specify date range as 01.04.2014 to 31.03.2015.
I get some bins in the status "No Inventory executed".I presume that Inventory is not executed for these bins within this period.
But when I go to each bin in the status "No Inventory executed" I find that The bins are counted on the dates 24.09.2014 and then on 05.04.2015.
Then I changed the date in the selection screen to 01.04.2014 to 05.04.2015.
Those bins which were earlier in the status of "No inventory status executed" are now not present in this status.
Does this mean that LX25 report is based on the Last counted date? Or the report is not displayed correctly for the date range provided?
I want to know the criteria based on which the LX25 report works.
Thanks In Advance.Hi Jurgen,
Below information I found from the LX25 report info in SAP.
Inventory status
Description
This report provides information on the stock in the storagae bins and presents this on the screen. You can limit your selection by warehouse number, storage type and storage bin, or choose the following criteria:
Total number of bins
Number of inventoried bins in the selection period
Bins with active inventory
Bins with planned inventory
Bins without executed inventory
From this list, you can obtain a plan of the individual storage bins with further detail information within a storage type, by clicking on the relevant line total.
It clearly shows that the report should be able to show the number of inventoried bins in the selection period, which it doesn't. Does it mean that system is not working as expected?
Regards
Soumya
Maybe you are looking for
-
Hello all, The Wi-Fi 1.0 patch will not install on a 10.7.4 Mac OSX even though the Wi-Fi loss bug is still there, every now and then (the iMac does not detect any wi-fi network). Are there any other solutions regarding this issue ? kind regards
-
Getting following error: Alert - Couldn't contact Spell Checker
This is a document from the new PC version of Office (.docx). But I can see everything just fine, and the formatting seems to be intact. The only thing is that there are a load of spelling errors, but none of them are showing up. I tried saving the f
-
How to make CC recognizes the #include declarations ?
HI all, On most header files, the #include are indicated by a relative path, like GL/gl.h for example, and not #include "/usr/X11/include/GL/gl.h". For me on Sol10, CC (and also g++) recognizes only the absolute path, not the relative. One solution i
-
Issues after Update to V7.2.0.35
I just updated iTunes under Windows XP-Pro to the new version (7.2.0.35) and when I play a tune either in the full Music list or a library it just stops when finished rather than continuing to the next tune. How can I get it to keep playing tunes the
-
By using Itunes Match I get an error message 4010
Windows 7, with 4 devices running on a same iTunes account, since 24 hours I get the 4010 error code and no download of updated music. Does anyone has somse workabel advice? Thanks