How to select 1st and 15th of every month
hello,
what is the select statement to get 1st and 15th of every month from todays date till the end of current fiscal year (sep 30th)
ex:
June 15th - 06/15/2008
July 1st - 07/01/2008
July 15th - 07/15/2008
sep 1st - 09/01/2008
sep 15th - 09/15/2008
SELECT
TO_CHAR(The_Date, 'FMMonth DdTH')
|| ' - ' || TO_CHAR(The_Date, 'MM/DD/YYYY')
FROM
WITH
Months
AS
(SELECT Level M FROM Dual CONNECT BY Level <= 9)
SELECT
TO_DATE(M, 'MM') The_Date
FROM
Months
UNION ALL
SELECT
TO_DATE(M, 'MM') + 14 The_Date
FROM
Months
WHERE
The_Date > SysDate
ORDER BY
The_Date
Similar Messages
-
Finding the 15th of Every Month
Hi,
I have declared expiration start date and end date variables. The expiration Start Date always start from 1st of the Month or 15th of the Month. Right now I am incrementing the expiration start date by one Month :
for example if my exp start date : 2010-01-01
and exp end date : 2010-04-01
I dissect the dates from start date :
2010-01-01
2010-02-01
2010-03-01
2010-04-01
Instead of incrementing the start date by 1 month as am currently doing I would want to increment by 1st and 15th of every month :
2010-01-01
2010-01-15
2010-02-01
2010-02-15
2010-03-01
2010-03-15
2010-04-01
I tired directly to add days but that does not work. Please suggest is there a way to increment my exp_start_date variable so that it increments by exaclty 1st or 15th of the month.
Below is the code :
declare
exp_start_date varchar2(15):='2010-01-01';
exp_end_date varchar2(15) :='2010-04-01';
v_exp_start_dt date := to_date(exp_start_date,'yyyy/mm/dd');
v_exp_end_dt date := to_date(exp_end_date,'yyyy/mm/dd');
v_tmp integer;
begin
while v_exp_start_dt <= v_exp_end_dt loop
select nvl(sum(dc.daily_count),0) into v_tmp
from daily_counts_summary dc
where
and dc.expiration_dt = v_exp_start_dt
and v_exp_start_dt between v_exp_start_dt and v_exp_end_dt
v_exp_start_dt := add_months(v_exp_start_dt,+1) ;
end loop;
end;Thanks,
evaHi,
I finally got close on finding the 1st and 15th of every month :
Below is the code that works with the sysdate object :
SELECT days
FROM (SELECT SYSDATE + ROWNUM AS days
FROM DUAL
CONNECT BY LEVEL <= TO_DATE ('01-SEP-2011', 'DD-MON-YYYY') - SYSDATE)
WHERE TO_CHAR (days, 'dd') IN (1, 15)Instead of using the sysdate object I want to use variable which I have in the query . The variable is of data type date.
I tired various combination's but I am unable to replace the sysdate with my query variable.
here is the code I am trying :
SELECT days
FROM (SELECT TO_CHAR('01-FEB-2011', 'dd-Mon-yyyy') + ROWNUM AS days
FROM DUAL
CONNECT BY LEVEL <= TO_DATE ('01-MAY-2011', 'DD-MON-YYYY') - TO_CHAR('01-FEB-2011', 'dd-Mon-yyyy'))
WHERE TO_CHAR (days, 'dd') IN (1, 15)It always throws the erorr : ORA00092- Inconsistent Datatypes expected a number and got DATE.
Please advice as am very close to the solution.
Thanks,
eva -
Scheduling process chain in 1st and last of the month
Hello ,
Can some one help in scheduling the process chain at the starting of the month and the end of the month ?
The chain has to start on 1 st and 28th of every month.
Help me with the informations please!
Points will be assigned!
Thanks in Advance
Ram!Have your process chain to start "After event". Then create an ABAP program to call function module BP_EVENT_RAISE. There are numerous postings in this forum on how to do this.
Next create two monthly jobs (one scheduled on the 1st and the other on the 28th) using SM36, and the only step in the job is to call the program to trigger (raise) the event. By triggering the event, your process chain will execute.
Check these links:
Re: scheduling process chain 3 specific times a day -
GR to be created between 14th and 20th of every month as per planng calndr
Hi Freinds,
I have a requirement that PR or PO should be created only betwen 14th and 20th of every month.
How can i configure the planning calendar and lot size for this requireent.
Thanks in advance
Shailesh.hI,
If you are question is not GR but to cerate MRP proposals inspecific period, yes it is possibel with Periodic lot size and planning calendor respectively.
You will need to define your planning calendors in MD25 and assign the lot size in material master.
Serch forum on this topic, there are ample threads available. -
I subscribed to National Geographic and get billed every month for it but never have been able to find where to download my purchases what am I missing?
1. Reboot iPad
2. Reboot router
Note: Make sure your printer is on the same network as your iPadr (run CD to setup network printer) -
Selection 1st to 15th and 16th to 31th of a month in the query designer 3.x
I am searching for help, because of my report i need the possibility to get the keyfigures for the first half of the month and for the second half of the month. I haven't any idea how I can get it. Please help me!!!!!
Hi,
Create a restricted key figure as follows.
select KF and 0calmonth into details of selection in restricted key figure.
Create a variable on 0calmonth
Right click on 0calmonth and choose restict
Choose Value range from show and choose Between option from drop down box and select the variable which you have created on 0calmonth in the below two boxes.
Move to right side and right click on it and choose Set offset for variable.
Give 15 and 0 and save the resticted key figure.
Like this create another RKF for 16 to 31.
Thanks,
Ashok -
How to select usr_login and him resource, it resource, login in this resource OIM
Hello im need help in how to select in database sql usr_login and him resource, it resource, login in this resource OIM&
It is your only option if you want to get rid of that other user account. It seems the system is Hard Set to boot to that account. How and why I have not Idea but the first thing you should of done was Restoring it to the Original OS, if it was not Mt Lion to begin with, in doing so getting rid of all other accounts and files from that other account.
Time to Bit the Bullet and Erase the drive completely and reinstall the original shipping version of OS X on that system.
Anton Mironenko wrote:
Reinstalling the OS would be too extreme. I already have many programs installed, and I tuned a lot of params. Data migration is another pain.
I hope, it is possible to solve this issue in another way. -
How to select text and pictures together in word processing mode?
Hello,
I have written about 20 chapters of a book in word processing mode. Each chapter has many pictures, carefully positioned within the text.
Each chapter is a separate pages file.
Now i want to put them together into one single document and have a big problem.
When i press cmd+A to select everything in one document in order to copy and paste it into another document, i can either select the text OR the pictures, not both together.
In Layout mode it is possible, but not in word processing mode.
Does anybody know how to select both in word processing mode or how to transform a word processing document into a layout mode document?
Or is there a way to put together a word processing document from a number of single documents?
Thanks in advance
funthomasI still use word processing for just about everything. The first two versions of Pages only had word processing. I think all of the complaints/requests about the "always-present" text layer led the developers to add page layout. I think they would have been better off adding another application (like AppleWorks' draw module compared to AppleWorks' word processing module.
-
How to select copy and paste an image that has a layer mask
Hi,
when I select, copy and paste the image it still has the content that I removed using the layer mask.
I want to paste it over another psd whilst maintaing the transparency.
Any help would be much appreciated.
PSD is at
http://sdrv.ms/16DoRft
The small jpg is because I don't know what you will see in the skydrive psd
MichaelWow that was so easy!
Thanks!
I spent at least half and hour trying to figure out why it wouldn't work.
Michael -
How to calc the begining and end of every month (leap year)
Hi all,
I'm looking for a method that returns the begining and end of next month.
example:
today is 2005-10-04
so the method suppose to return:
2005-11-01
2005-11-31 //as it ends on the 31
I came up with the code below - but I don't like it as I can't get the end of month + it's not safe.
any suggestions.
Thanks
Peter
Calendar gcToday = Calendar.getInstance();
int month = gcToday.get(Calendar.MONTH);
int year = gcToday.get(Calendar.YEAR);
month+=2;
if(month>12) //beacuase of month+=2;
year++;
month=1;
String nextMonth;
if (month<10)
nextMonth=year+"-0"+month+"-01";
else
nextMonth=year+"-"+month+"-01";Look at using the methods getActualMaximum() and getActualMinimum() in the Calendar class. Basically what I would do is set the calendar to the 15th of the month (well, really anything between 1 and 28) and then add() one to the current month. The Calendar will roll over the dates as needed.
-
ERP sales order additional fields: how to select data and edit it.
Hi Gurus,
I need to add in the CRM Web UI SAP ERP fields like VBAK-TAXK1. I followed the steps as described in the SAP note nr 1224179.
The field is present in the CRM WEB UI, but there is not the selection list and it is not editable.
I checked the field in the structure TDS_HEAD_COMV, TDS_HEAD_COMC and it is in the table LORD_MAPPING with this entries:
OBJECT : HEAD
FIELD : TAXK1
FIIELD_INTERNAL: VBAK-TAXK1
REPID: SAPMV45A
DYNNR: 4440
I have also checked the values of these two parameters in the VA transaction:
CALL_FUNCTION equal blank
CALL_ACTIVITY equal blank
In the CRM system I created the custom field and I renamed it with the same name of ERP field in the structure:
INCL_EEW_ERP_ADMINH_V
INCL_EEW_ERP_ADMINH_V_X
Thanks for the Help
Daniele
Edited by: Daniele Piazza on Jan 24, 2011 3:17 PMHi,
Call transaction SFW5 on ERP system, click Continue on POP-UP.
Check if ENTERPRISE_BUSINESS_FUNCTIONS->LOG_SD_SIMP_02 is active. If it is not active, select it and go to the menu->Activate .
Edited by: Daniele Piazza on Apr 1, 2011 9:19 AM -
Giving access to the planners for the 1st 2 weeks of every month to plan
Hi Friends
I m implementing a BPC 7 MS rolling forecast planning.
Now the base member of the Time Dimensionis Month.
my requirement is ,
A Planner will be get a alert to at the end of every month to start the process of Monthly planning for the next month.
And the planner will only get 2 weeks of a month to plan the quantity . After that that particular planner will not able to plan any further for that particular month.
In my planning application, the secured dimensions are ENTITY, CATEGORY & PRODUCT and in the Ownership Dimension is used in the PRODUCT DIMENSION, becuase planning process is driven by the Brand.
The same process shoud repeat for all the coming months.
And also is there any way to automate the above process.
RegardsFor example, your workstatus settings have the following settings:
Entity, Time and Category are the dimensions on which workstatus is checked.
You application is called Planning, so the table where the workstatus is maintained is dbo.tblPlanningLock.
The table has the following columns (I don't know this by heart and have nowhere to check right now, so check on you own system!):
- StatusCode (The code corresponding to the status column in dbo.tblStatusCode)
- Category (The locked category member)
- Entity (The locked entity member)
- Time (The locked time member, for correct syntax check your own system, because i am not sure but I think you should put TimeID here from the membertable)
- TimeName (The locked time member again, but with the memberID from the time dimension. Again you should check this in your own system as I am nog 100% sure about the syntax here and cannot check right now.)
- Lastupdate (the date of the update. For exact syntax again check your own system)
- Updateby (user which updated the workstatus)
What you want to do now is to create a file to load new records into this table. This could for example be a csv file. This file can be imported using the DATAFLOW task in SQL Business Intelligence Development Studio. This csv file should have the following format (or if you want to use another you have to create a mapping to):
(For example purposes I assumed that the code for locked is 2)
Statuscode,Category,Entity,Time,TimeName,Lastupdate,UpdateBy
2,BUDGET,E0001,20100100,2010.JAN,14-01-2010,DOMAINNAMEUSERNAME
This can be done by running the package from BPC or by scheduling it on the server. There is a how to guide on how to create SSIS packages on SDN. This is the link:
[How to Build SSIS Packages for Business Planning and Consolidation 5.0|http://www.sdn.sap.com/irj/scn/index?rid=/library/uuid/2027ebee-a928-2a10-4485-b88c926f5e24|]
This link is for 5.0 but the proces in BPC 7 is quite similar.
Edited by: Tim Vierhout on Jan 7, 2010 4:46 PM -
Why am I charged twice with two different orders every month for one package of 800 mins. Are they giving me 1600 minutes! I need only 800 minutes please, so please refund these extra order charges please. I just noticed this thing month today and on checking order history find that same practice has been followed for all my previous months transcations!
Hello and welcome to the Skype Community.
The duplicate charge has been reversed and the funds will be returned to you. -
Is it possible to do "1st and 3d" week of month events?
I'd like to have a recurring event that happens 1st and 3d Monday of the month. The custom option for recurring events doesn't seem to allow this ... but is there a way?
Tahm,
It appears to me that you will have to create an event and use "Custom" to repeat the first Monday:
...and then create a second event on the third Monday. -
More and more money every month
Been having problems with BT account for months now tried to set up a direct debit as had a problem with bank account and had to cancel and re set up, every time I try this it tells me I need to make a payment first which I do, this was £73 the first month then asked for more which I just can't afford the next month asked for £76 which I paid then £88 and asked for more and wont let me set up direct debit until payments made this month they asked for £176 I don't have this kind of money and I'm now thinking of going back to sky as they r a lot cheaper I chose bt as it was easier to have all it one place but now it's just causing undue stress I'm in tears every month please can someone help me sort this out.
try online chat and see if they can help
live chat http://bt.custhelp.com/app/contact/c/2902/?s_intcid=con_intban_sanda_contact_us_chat_from_forums
If you like a post, or want to say thanks for a helpful answer, please click on the Ratings star on the left-hand side of the post.
If someone answers your question correctly please let other members know by clicking on ’Mark as Accepted Solution’.
Maybe you are looking for
-
I reset and erased my iphone 4 and now I can`t reinstall it! After I choose a language, region. and wifi, it says Please, try again later or contact customer care. I tried to do with iTunes, and iTunes even sees this iphone, but it`s like blank, ther
-
HT1533 How can I switch back to Mac OS X from Windows 7 Bootcamp?
I'm having problem switching back to Mac OS on my Macbook Air. It's currently running Windows 7 bootcamp without a Mac OS installed with it. I tried booting up on Mac OSX installer disc (Snow Leopard) on the external CDROM drive but it boots to Win
-
Tab Page Errors out after migration to new instance
Hi All, Tab Pages are running well in test instance but when I migrate it to dev instance then On click of a particular tab that page errors out. ERROR STACK ## Detail 0 ## java.lang.NullPointerException at exl.oracle.apps.per.eexit.webui.Employ
-
How to use create_sort_rule? Please help!
Hi Experts, I want to craete a sort rule for a field. There is a method called create_sort_rule in IF_SALV_WD_SORT interface. It has following parameters: inputs: SORT_ORDER : LIKE IF_SALV_WD_C_SORT=>SORT_ORDER DEFAULT IF_SALV_WD_C_SORT=>
-
Do i need a codec for avi files to play in flv
i have no mpeg moves files on my computer so when it says browse for your flv file it shows me nothing right. i have to have flv files already encoded for them to view on my computer right.