Combine two type dates into one

I have two type dates that I get from my database : Date : 2017-01-28 || Time : 12:59 And I want to combine it into a one Date variable. this is the origin of the two variables : @Temporal(value = TemporalType.DATE) @Future @DateTimeFormat(pat...
more »

2017-01-19 23:01 (3) Answers

javascript : Error for increment seconds

<html> <head> <script> function startTime() { var st = "January 19, 2017 18:33:31" var today = new Date(st); var montharray = new Array("Jan","Feb","Mar","Abr","May","Jun","Jul","Ogu","Sep","Oct","Nov","Des"); var h...
more »

2017-01-19 16:01 (1) Answers

change date format in javascript

I have date format like 24.1.2017 00:00:00 as result I want 2017/01/24 I wrote this function to change date to format what I want. Date.prototype.yyyymmdd = function() { var mm = this.getMonth() + 1; // getM...
more »

2017-01-19 13:01 (3) Answers

Create date object and compare to todays date

I have an object containing time. For example x.time = 10:20:00. I want to take the current time minus my objects time. This is my code so far, but i get the error message ="Invalid Date": for(var i = 0; i<x.length; i++){ nowDate = new Date(...
more »

2017-01-19 13:01 (3) Answers

Search data between two timestamp in oracle

I am trying to search data between two dates, but it retrieving old data where not in the range i gave? kindly advice me how to re-write the below query logic select * from Users where TO_CHAR(Users.lastloggedindate,'dd-MON-yy HH.MI.SS') between '1...
more »

2017-01-19 08:01 (1) Answers

R plotting table of incomplete dates

Novice R question: given a number of observations over a range of dates, e.g., obs <- as.Date(c("2001-08-02","2001-08-02", "2001-08-02","2001-08-03", "2001-08-04", "2001-08-04", "2001-08-07", "2001-08-07")) I can plot the frequ...
more »

2017-01-18 22:01 (2) Answers

Bash - number of hours in given day

Using Bash shell on Linux, and given a datetime, how can I determine how many hours there are on that particular day? The datetime pertains to some time zone with daylight saving, e.g. MET. ...
more »

2017-01-18 19:01 (2) Answers

Rolling sums for groups with uneven time gaps

Here's the tweak to my previously posted question. Here's my data: set.seed(3737) DF2 = data.frame(user_id = c(rep(27, 7), rep(11, 7)), date = as.Date(rep(c('2016-01-01', '2016-01-03', '2016-01-05', '2016-01-07', '2016-01-10', '2016-01-1...
more »

2017-01-18 13:01 (4) Answers

Subtracting dates using date()

I am wondering how can I do this: Subtract two different dates that are obtained trough the date method. Basically, it is for a game I am making that requires a certain amount of time to perform an action. So let's say the user clicks a button, a que...
more »

2017-01-18 13:01 (2) Answers

Wrong date saving

I have a form in which I have integrated calender field : Publish date and Unpublish date When I am sbmitting this form I have Publish date = 1/18/2017 and unpublish date = 1/19/2017; In Controller i am making custom time $pubdate = strtotime...
more »

2017-01-18 13:01 (1) Answers

Java 8 LocalDateTime and Strange Zone Behaviour

I'm a bit confused when using the LocalDateTime from Java8. What I'm trying to do I have a Date (java.util) object I want to convert it to a LocalDateTime I want to format the LocalDateTime to get the time as HH:mm What I have done LocalDateTim...
more »

2017-01-18 10:01 (2) Answers

gembox.spreadsheet date gets converted to int

I am loading an Excel 97-2003 XLS file into C# using GemBox.Spreadsheet version One cell has the value 13-01-2017 (Formatted: 20170113) and the datatype "Date" with custom formatting "YYYYMMDD". After Gembox.Load(new XlsLoadOptions( ...
more »

2017-01-18 10:01 (0) Answers

Frequency table with R (from raw time series)

I have a .csv file with a time series. I am trying to use ts(), and to plot it! But my initial dataset is one row for one action. So I want to do a table, with the frequencies. I've done that, but for the (existing) days I don't have data for, I'd li...
more »

2017-01-18 00:01 (1) Answers

Member Data between date ranges

I have a table in SQL Server 2014 named [Membership] containing personal member data and two date fields named [member from date] and [member to date]. I need to summarise the monthly membership. A member is counted in a given month only if they are...
more »

2017-01-17 21:01 (3) Answers

Overflow when using DateAdd Excel VBA

I currently have an Excel sheet with a series of dates and a cell in a different sheet with the date when we last ran this macro. I need to write a macro which checks if today's date is at least 32 days after the day we last ran the macro. If so, ...
more »

2017-01-17 16:01 (0) Answers