Help - formula for date automatically displayed as per given frequency period
Details of report received date and delayed no of days in submission
S/No
Details of Report
Frequency
Date as per Frequency (Target Date)
Received up to as on
lapse of days
Fin per Day
Fine Amount
24.07.2014
(Rs.)
1
Cash book
Daily
24.07.2014
30.06.2014
24
10
240
2
DSR
Previous Day
23.07.2014
31.05.2014
53
10
530
3
Day book hard copy
Thursday & Monday
Formula Required latest date for Thursday or Monday and date with in cell E4
10
0
4
Asset stock
Fortnight
Formula Required latest date for 15 th day or last date of month and date with in cell E4
10
0
5
Labour approval
1st Day of Month
Formula Required 1st day date of month with in cell E4
10
0
6
Qty as per drawing
Every Quarter
Formula Required last day date of quarter of the year with in cell E4
10
0
Note: I want simply enter the date in E4 and the formula calculated the date in column D
do you want to calculate the date format directly? see the sample:
=DATEVALUE(TEXT(date,"d/m/yy"))
KR
Similar Messages
-
Dump in Value-Help Component for date
I created a Value-Help-Component for date fields. (I cannot use the standard value help, because I need the help to start in the month, the user is working on).
I am using the Date Navigator to select a date.
If I first change the month with an arrow of the date navigator and then select a date I get a dump in the method IF_WD_CONTEXT_ELEMENT~GET_ATTRIBUTE_REF in line
attr_info = me->node_info->if_wd_context_node_info~get_attribute( name_only ).
, because the element does not have a node_info.
If I just choose a date in the preselected month (without using the arrows of the date navigator) everything is fine.
Does anybody have an idea??
Many thanks in advance.I found the "solution" to the problem myself.
I used the method bind_structure in the component containing the date navigator.
After I replaced it by set_static_attributes it worked without producing dumps.
Very strange! -
Formula for dates back 7 days failing because of end of month?
HI I have a CR that has been working fine till now. it runs every Sunday late in the day and looks back past 7 days. it has formula for dates from and to.
tonumber(totext(CurrentDate,'yyyyMMdd'))-6
and tonumber(totext(CurrentDate,'yyyyMMdd'))
yet this past Sunday, it is not giving all previous 7 days. could it be related in any to the end of month? i cant think this is it. but perhaps.the date col is type = NUMBER and in YYYYMMDD.
WHen I ran this report manually by selecting on the dates needed it returns more data.Hi Paul,
The issue is when you convert a date to number a subtract 6 from it, it doesn't go 6 days back; it just subtracts 6 days from that converted number.
So, today, represented as a number would be 20140804 however, when you subtract 6 from this number you get : 20140798 which of couse is Not a date.
Your code (if the dates are stored as number in the database) should be :
tonumber(totext(CurrentDate-6,'yyyyMMdd'))
-Abhilash -
Use formula for date range instead of parameter?
I am designing a Crystal report that will always pull records for the next full week.
Example: Today is 8/4, so I need the report to pull data for dates 8/11 through 8/15.
Currently, I am using parameters each time to run this report.
Is there a formula that could automatically pull this date range without using parameters in my report?
Any help is appreciated.
Thanks.This is actually not too difficult. Assuming you want to be able to run this on any date and get the "Next Full Week" starting on Monday (based on your date range above), here's what you could do:
1. Create a formula that I'll call {@StartDate}
NumberVar dow := DatePart('w', CurrentDate, crMonday) - 1; //Day of week, starting on Monday.
NumberVar days := 7 - dow;
CurrentDate + days
2. Create a formula that I'll call {@EndDate}:
{@StartDate} + 7
3. In the Select Expert, manually edit the selection formula to use these date formulas instead of the parameters.
-Dell -
Mapping conversion help needed for date
Hi Experts,
I need help in message mapping convesion for date field
The source date field can have value '2010-06-04T02:09:59.610-07:00' or 2010-06-04T02:09:60.610-07:00
I have to change it to '2010-06-04T02:09:59.000-07:00'. ie, if the seconds are 59.XXX, or 60.XXX, then change to 59.000.
Please let me know the best way to do this
Thanks
MikeAgain, to make it more clear
The source date field can have any date value such as
2010-06-04T02:09:59.610-07:00 -
This needs to be changed to 2010-06-04T02:09:59.000-07:00
2010-06-04T02:09:60.610-07:00 -- This needs to be changed to 2010-06-04T02:09:59.000-07:00
2010-06-04T02:09:60.000-07:00 -- This needs to be changed to 2010-06-04T02:09:59.000-07:00
2010-06-04T02:09:59.000-07:00 - This need not be changed
2010-06-04T02:09:58.610-07:00 -- This need not be changed
2010-06-04T02:09:57.610-07:00 etc etc - These need not be changed.
The only change using date function is for the first two dates, in which 59.XXX and 60.XXX need to be replaced with 59.000
Using the above date function, all the seconds 59.XXX, 58.XXX, 60.XXX, etc etc,,, are converted to 59.000, 58.000 and 60.000
I dont need this as per the requirement. So looks like the UDF needs to be altered a little to accomodate my requirement.
Please help me.
Thanks
Mike -
OEM Capacity Planner - location of help definitions for data items
Does anyone know the location of the help definitions for the OEM Capacity Planner data items? In the GUI, these definitions are accessible individually from Help > Selected Item. The definition provides a description, source, and user action.
I would like to consolidate these into a glossary for our users of OEM C.P., as well as in a planning document.perhaps that information can be here:
Enterprise Manager Administrator's Guide Contents / Search / Index / PDF
Enterprise Manager Concepts Guide Contents / Search / Index / PDF
Enterprise Manager Configuration Guide Contents / Search / Index / PDF
Enterprise Manager Event Test Reference Manual Contents / Search / / PDF
Enterprise Manager Messages Manual Contents / Search / Index / PDF
http://otn.oracle.com/pls/db92/db92.docindex?remark=homepage
Joel P�rez -
How do you get fields to format for dates automatically?
I have Acrobat 9.0 and created a text field in a form for "date". I have set the format as date mm/dd/yyy but keep getting an error msg when I enter dates "Invalid date/time ...". I want to be able to enter 05161987 and have it format automatically as
05/16/1987.No, it does not. One needs to deal with international date format and sequences and users who do not want to enter leading zeros.
-
Dear All,
There is a requirement in which when the material (Not batch managed) is getting return from Non WM managed storage location to WM managed storage location than at the time of creating transfer order or after creation of transfer order would like to change LTAP-WDATU (GR date) automatically , So here i am unable to find the right user exit or BADI in which i can write the logic for same. Below is full description of the requirement.
Here we are following Removal strategy "FIFO" while picking the material (Not batch managed) from WM managed storage location (WMS1) & transferring to Non WM managed storage location (ODS) ( than from there it use to go to Production) , at certain times partial quantity use to come back from Non WM managed storage location (ODS) to WM managed storage location (WMS1) and while doing putaway of the same "GR date" use to change which was not the actual when the material 1st time comes to WM managed storage location (WMS1) (before getting transfer to Non WM managed storage location). So here i want the user exit or BADI in which i can write my logic so that GR date ( LTAP-WDATU) would automatically change while creating transfer order or after creation of transfer order as per the "GR date" of same material which last moved from WM managed Storage location (WMS1) to Non WM managed storage location(ODS) because as per FIFO material dated before that would not be exist in the warehouse.
Below is the flow of the material while transferring to production & returning from production.
WMS1 ( WM managed warehouse ) --> ODS ( Non WM managed warehouse) --> Production At the time of issue to production
Production --> ODS ( Non WM managed warehouse) --> WMS1 ( WM managed warehouse ) At the time of return from production
I hope i m clear on my requirement.
Thanks in advance.1. You have to get a key from SAP to modify the two includes in which the user exits are present.
2. You have to enter statement 'INCLUDE z**. ' in both user exits in the MV45* includes. Then save and activate the MV45** includes.
3. You have to figure out the code that carries out the functionality described in your specifications.
3. Write the code in includes Z** .
4. Now the code written by you will be executed when you run the relevant SD transaction
Message was edited by: Sudhir Bhate -
Help Required for date display & mutating trigger
Hai all..
I need clarification for 2 problems.
Problem 1
Is there a possibility to display the values with a date range.
I mean if there is no data for a particular date within the given range. it should display some null value.
Eg.
table name : sample
Sno Date1 Name desgn
1 1-may-2004 xyz engr
1 3-may-2004 xyz engr-1
1 4-may-2004 xyz engr-2
The query is
select * from sample where date1 between '01-may-2004' and '04-may-2004'.
The result of query will be
Sno Date1 Name desgn
1 1-may-2004 xyz engr
1 3-may-2004 xyz engr-1
1 4-may-2004 xyz engr-2
But i need the result to be displayed as
Sno Date1 Name desgn
1 1-may-2004 xyz engr
nil 2-may-2004 nil nil
1 3-may-2004 xyz engr-1
1 4-may-2004 xyz engr-2
Pls let me know how to achieve this.
Problem 2:
While i am updating a value using a trigger.
I am getting "mutating" error.
Is there a possibility to avoid the mutation.
The two triggers i am using is
Trigger 1
CREATE OR REPLACE TRIGGER TRIG_DURATION_UPDATED
AFTER UPDATE ON
TIMESHEET_DATA
FOR EACH ROW
DECLARE
ID_COUNT DATE;
A date;
NN NUMBER;
AA NUMBER;
NN1 NUMBER;
BEGIN
b_dur :=0;
IF UPDATING('PROGRESS') THEN
SELECT COUNT(1) INTO AA FROM TIMESHEET_DATA_PAUSE WHERE DATA_sNO = :OLD.DATA_SNO AND EMP_ID = :OLD.EMP_ID AND
ACNUM = :OLD.ACNUM AND DURATION IS NULL;
IF AA > 0 THEN
SELECT to_date(START_TIME,'DD-MON-YYYY HH:MI AM') into a FROM TIMESHEET_dATA_PAUSE WHERE
EMP_ID = :NEW.EMP_ID AND ACNUM = :new.acnum AND DATA_SNO = :new.data_sno AND pause_TIME IS NULL
AND DURATION IS NULL;
select to_date(sysdate,'DD-MON-YYYY HH:MI AM') into id_count from dual;
SELECT A - ID_COUNT INTO NN FROM DUAL;
SELECT round(TRUNC(NN*24),2) INTO NN1 FROM DUAL;
UPDATE TIMESHEET_dATA_PAUSE SET DURATION = NN1,PAUSE_TIME = SYSDATE WHERE
EMP_ID = :NEW.EMP_ID AND ACNUM = :new.acnum
AND DATA_SNO = :new.data_sno AND pause_TIME IS NULL AND DURATION IS NULL;
END IF;
END IF;
END;
Trigger 2
CREATE OR REPLACE TRIGGER TRIG_DURATION_UPDATED_PAUSE
AFTER UPDATE ON
TIMESHEET_DATA_PAUSE
FOR EACH ROW
DECLARE
ID_COUNT DATE;
A_COUNT NUMBER(10);
A date;
NN NUMBER;
AA NUMBER;
NN1 NUMBER(10,2);
BEGIN
IF UPDATING('DURATION') THEN
SELECT COUNT(1) INTO A_COUNT FROM TIMESHEET_DATA WHERE DATA_sNO = :new.data_sno AND EMP_ID =:new.EMP_ID
AND ACNUM = 'ACNUM' AND DURATION IS NULL;
IF A_COUNT >0 THEN
SELECT NVL(SUM(DURATION),0) INTO NN1 FROM TIMESHEET_DATA_PAUSE WHERE DATA_sNO = :new.data_sno AND EMP_ID =:new.EMP_ID AND ACNUM = :NEW.ACNUM;
UPDATE TIMESHEET_DATA SET DURATION = NN1 WHERE DATA_sNO = :new.data_sno AND EMP_ID =:new.EMP_ID AND ACNUM = :NEW.ACNUM AND DURATION IS NULL;
END IF;
END IF;
EXCEPTION WHEN DUP_VAL_ON_INDEX THEN
DBMS_OUTPUT.PUT_LINE ('CANNOT INSERT');
END;
Pls let me know the solutions for the two..
Thanks in Advance
Gaya3In future please start two threads when you have two questions to ask. Othewise it makes things difficult to follow and may well lead to some of your questions not getting an answer. Unlike some other sites there is no limit to the number of posts we can have :)
To answer your first question:
If you have Oracle9i you can do this using a PIPELINED function to act as a pivot table (in earlier versions you will have to have a table of some description - ALL_OBJECTS will do in a pinch).
CREATE OR REPLACE TYPE t_dates AS TABLE OF DATE
CREATE OR REPLACE FUNCTION f_dates
(st IN DATE, cnt IN INTEGER) RETURN t_dates
PIPELINED
AS
dd date;
BEGIN
FOR a IN 1..cnt LOOP
SELECT st + (a-1)
INTO dd
FROM dual;
PIPE ROW (dd);
END LOOP;
RETURN;
END f_dates;
/So, given this data...
SQL> select * from t57
2 /
COL1 COL2
3 05-MAY-04
4 06-MAY-04
5 07-MAY-04
6 12-MAY-04
8 15-MAY-04
5 rows selected.
SQL>...we can run this query...
SQL> SELECT nvl(to_char(t.col1), 'Nil'), dd.ndate
2 FROM t57 t
3 , ( select column_value AS ndate from table(cast(f_dates(trunc(SYSDATE), 11) AS t_dates))) dd
4 WHERE trunc(dd.ndate) = trunc(t.col2(+))
5 /
NVL(TO_CHAR(T.COL1),'NIL') NDATE
3 05-MAY-04
4 06-MAY-04
5 07-MAY-04
Nil 08-MAY-04
Nil 09-MAY-04
Nil 10-MAY-04
Nil 11-MAY-04
6 12-MAY-04
Nil 13-MAY-04
Nil 14-MAY-04
8 15-MAY-04
11 rows selected.
SQL> Obviously, you will want to tidy up the function to suit your needs.
Cheers, APC -
SQL Help for Date Range display
Gurus,
I have a sql statement like
select MIN(HIREDATE), MAX(HIREDATE) FROM EMP WHERE DEPTNO = 30My output looks like
MIN(HIREDATE) MAX(HIREDATE)
12/30/1998 12/30/2001Based on the values of MIN(HIREDATE) , MAX(HIREDATE) values
I need a SQL to generate the output like
12/30/1998
1/30/1999
2/28/1999
until Max(HIREDATE) value
In Feb we dont have 30th day, In that case take the last day of the month.
Thanks for great help
C 007With 10g.
Regards Salim.WITH t AS
(SELECT min(hiredate) min_hiredate,
max(hiredate) max_hiredate
FROM emp_test
where deptno=30)
SELECT min_hiredate dt
FROM t
model
dimension by ( 1 rn)
measures(min_hiredate,months_between(max_hiredate,min_hiredate) diff )
(min_hiredate[for rn from 1 to diff[1] increment 1]=add_months( min_hiredate[1],cv(rn)-1))
order by rn
SQL> WITH t AS
2 (SELECT min(hiredate) min_hiredate,
3 max(hiredate) max_hiredate
4 FROM emp_test
5 where deptno=30)
6 SELECT min_hiredate dt
7 FROM t
8 model
9 dimension by ( 1 rn)
10 measures(min_hiredate,months_between(max_hiredate,min_hiredate) diff )
11 (min_hiredate[for rn from 1 to diff[1] increment 1]=add_months( min_hiredate[1],cv(rn)-1))
12 order by rn
13 /
DT
1998-12-30
1999-01-30
1999-02-28
1999-03-30
1999-04-30
1999-05-30
1999-06-30
1999-07-30
1999-08-30
1999-09-30
1999-10-30
1999-11-30
1999-12-30
2000-01-30
2000-02-29
2000-03-30
2000-04-30
2000-05-30
2000-06-30
2000-07-30
2000-08-30
2000-09-30
2000-10-30
2000-11-30
2000-12-30
2001-01-30
2001-02-28
2001-03-30
2001-04-30
2001-05-30
2001-06-30
2001-07-30
2001-08-30
2001-09-30
2001-10-30
2001-11-30
SQL> -
HELP: Formula Item data is not saved to database
Hi:
I've added a formula in a database item but when i commit the form the data is not saved to the database. When i am working on form the item reflects the formula value, but when i commit the value is not stored in the database.
I need urgent help.
Thanks
Joao OliveiraIt is not clearly stated in the help file I agree. With a little PLSQL code you could copy the item to a hidden database field and have it be saved to the database. See Note 43012.1 on Metalink for details.
-
Help needed for data updation in User Defined Tables
Hello Experts,
I am developing one add-on in SAP B1 8.8 to input data in a User Defined Table described as under
Table Name
DriverMst UDT Type is No Object
Description
Stores the Driver master data which are used to get reference in Sale Delivery Form and Driver data management activity
User defined fields
Data Name
Data source
Size
Pane Level
Description
Driver Code
Code
Alphanumeric
0
No object table fixed field
System Name
Name
Alphanumeric
30
0
No object table fixed field
Full Name
FullName
Text
50
0
Father Name
FatherName
Text
50
0
Birth Date
BirthDate
Date
0
Phone Number
PhoneNo
Alphanumeric
50
0
Mobile No
MobileNo
Alphanumeric
13
0
I have created one form using screen painter displaying text boxes and bind them to the table.
This form is working absolutely fine when there are some data in table (i.e. Browse using navigation)
My problem is, when I click add button from tool bar the "OK" button turn to "Add" that means the form is set to Add mode, but when I click "Add" button after entering some data nothing happens and input data is not stored in Table. The same "OK" Button turned to "Update" when I do changes in loaded data, but my changes are not reflected to table after I click "Update".Thanks Nagarajan,
None.
There is no such query. The table fields is directly linked to Edit Box or Combo Box in form.
From the examples I learned that I have to do something like this to get my table updated
Dim oUsrTbl As SAPbobsCOM.UserTable
Dim Res As Integer
oUsrTbl = oCompany.UserTables.Item("DRIVERMST")
oUsrTbl.Code = oBPC.Value 'Item Specific of Driver Code Edit Box
oUsrTbl.Name = Left(oBPN.Value, 30) 'Item Specific of Name Edit Box
oUsrTbl.UserFields.Fields.Item("U_FullName").Value = oMFN.Value
oUsrTbl.UserFields.Fields.Item("U_FatherName").Value = oFTHN.Value
oUsrTbl.UserFields.Fields.Item("U_BirthDate").Value = oDOB.Value
oUsrTbl.UserFields.Fields.Item("U_PhoneNo").Value = oPHN.Value
(Similar For rest ofthe fields)
Res = oUsrTbl.Add()
Just let me know that is this necessary to do like above.. To be frank there are few more fields and matrices on the form which I didn't mentioned. I am just trying to get recovered from first step to proceed further.
Regards -
Help needed for Data Pump.
Hi,
I am using oracle 11g release2 and I am not able to find data pump utility in SQL developer.
Please let me know, if I need to install it. I am new to this utility.
Thanks.I do not believe SQL Developer would have DataPump utility.
As the name implies, SQL Developer is intended to be used as a tool to facilitate development (typically of SQL code), as well as provide additional features to assist developers in their daily routines.
DataPump, is more of a DBA tool used for extracting logical copies of data from an existing database and/or port to another database. To use this utility, you would typically need to be in the dba group (although not necessary if configured properly). But at least on the same server as the datapump utility software resides.
There are many options and features to using datapump, including network_link which allows extraction of data from a remote database to another database on a different server without ever creating a file on the operating system.
If I recall correctly, I believe in older versions of Oracle client (e.g., 8.x), the Oracle client provided the export/import utility. But those days are long gone now. With datapump, it is primary a DBA tool. -
Help ! for date column type
Hi,
I am having two tables tdz12 and tdf31. TDF31 is a date field. and TDZ12 is transactions history table. If I do
11:30:39 SQL> alter session set nls_date_format='DD-MON-RRRR HH24:MI:SS';
11:30:57 SQL> select c65201 from tdf31;
C65201
30-NOV-2006 00:00:00
11:46:48 SQL> select distinct a9000 from tdz12 where a9000 >= '01-NOV-06';
A9000
01-NOV-2006 00:00:00
02-NOV-2006 00:00:00
03-NOV-2006 00:00:00
04-NOV-2006 00:00:00
06-NOV-2006 00:00:00
07-NOV-2006 00:00:00
08-NOV-2006 00:00:00
09-NOV-2006 00:00:00
10-NOV-2006 00:00:00
11-NOV-2006 00:00:00
13-NOV-2006 00:00:00
14-NOV-2006 00:00:00
15-NOV-2006 00:00:00
16-NOV-2006 00:00:00
17-NOV-2006 00:00:00
18-NOV-2006 00:00:00
20-NOV-2006 00:00:00
21-NOV-2006 00:00:00
22-NOV-2006 00:00:00
23-NOV-2006 00:00:00
24-NOV-2006 00:00:00
25-NOV-2006 00:00:00
27-NOV-2006 00:00:00
28-NOV-2006 00:00:00
29-NOV-2006 00:00:00
30-NOV-2006 00:00:00
26 rows selected.
If I do
11:26:39 SQL> select sum(a9060)
11:27:52 2 from tdz12
11:27:52 3 where A9000>=(select to_date(to_char(C65201,'YYYYMM')||'01','YYYYMMDD') FROM TDF31);
SUM(A9060)
0
Why I am getting 0 records ? ( Pl tell me the reason, not alternate way to get records )
thanks & regards
PJPTRUNC(c65201,'MONTH')is a simpler alternative to
TO_DATE(TO_CHAR(c65201,'YYYYMM')||'01','YYYYMMDD')although it will give the same result here. -
I have to search the database for a month and year. When using the following sql statement i get error message ORA-01843 not a valid month. What am i doing wrong.
select creation_date,customer_id from apps.cs_incidents_all_b
WHERE to_date(creation_date,'MM') = to_date('10','MM')I figured it out. Thanks
select creation_date,customer_id from apps.cs_incidents_all_b
WHERE to_char(creation_date,'mm') = '10'
and to_char(creation_date,'yyyy') = '2004'
Maybe you are looking for
-
Cancellation of multiorder delivery document.
Hi Experts, I have generated one delivery document from ten sales orders by using the collective processing ( VL10A ). Now when I am going to cancel the delivery document from the T-code- 'VL09', system is not allowing me to do it. Can any one please
-
I am not sure if it is a iTunes, AppleTv, Airplay or Time Capsule issue – or a combination of them all. But i am experiencing alittle annoying issue, which i hope to fix. I am playing music from iTunes 11.0.5 and i Airplay it to my AppleTv it plays w
-
XML and Class Implementation?
Hey everyone, I'm new to this forum and pretty new to AS. I've created a fairly simple navigation bar. SWF Sample What I'd really like to do make this entirely dynamic by loading the images, tab names and hyperlink via XML (or an array). That way, I
-
How to change the name of the Tab "Additional Data B" in VA02 Tcode?
Hi All, I have enhanced the VA02 Header screen, and placed another Tab called DATA A. Here I have two requirements I want to change the name of the Additional Data B to some other name say DATA B 2. I have to add these two tabs in the menu Go to->He
-
InDesign CS3 will not open for second user
I am running InDesing CS3 on a iMac 10.4.11. InDesign, Photoshop and Illustrator all open for my admistrative user account. I recently created a second user account that is unable to open InDesign even though Photoshop and Illustrator open just fi