A value that indicates a particular day and time, such as a timestamp.

learn more… | top users | synonyms

2
votes
0answers
15 views

How to enter Seconds into Datetime fields using the standard UI

Say you have a datetime field Start__c on a pagelayout. Now try to enter a date (we have DE locale enabled, but should be similar in EN): 31.08.2014 14:53 ==> works 31.08.2014 14:53:38 ==> doesn't ...
0
votes
1answer
14 views

Duration as difference betweed to Datetime fields does not respect Seconds

It seems that Seconds are ignored in formula fields if you create the difference between Datetime/Time fields. Say you have two Datetime fields: End__c and Start__c Take a formula field Duration__c ...
2
votes
3answers
54 views

How to convert Date Format of NOW() to MM-DD-YYYY in Formula Editor

I have a requirement to convert the DATE FORMAT of NOW() to MM-DD-YYYY in formula editor. By doing using DATETIME.format() i can do it in APEX Classes, but i cannot get the same value in FORMULA ...
4
votes
0answers
23 views

Filter empty date field in SF analytics api

Using the analytics rest api we need to add a filter to a date field to get only the records where this field is empty. In json: { "column": "Account.Date_Field__c", ...
2
votes
2answers
46 views

Workaround for Possible Datetime.format() Framework Bug

I am generating a set of date-based keys by looping over a start date and adding successive months to the initial Datetime object. I seem to have run into a bug in the format() method of the Datetime ...
1
vote
1answer
26 views

Check Date is within THIS_WEEK

I have to check whether "mydate" is in within the current week or not. DateTime mydate= DateTime.newInstance(Date.Today().Year(),obj.Birthdate.Month(),obj.Birthdate.Day()); if(mydate==THIS_WEEK){ ...
2
votes
2answers
36 views

Calculate days between DateTime field and Now()

I am trying to create a formula in my custom report to show number of days between CUSTOM_FIELD (datetime field) and NOW(). How can I do this?
0
votes
1answer
159 views

Error: Compile Error: unexpected token: public at line 1 column 0

I need some help, this is my trigger. i have created a custom field on the user object called lastlogindate__c . i am trying to get the value from lastlogindate populated in the lastlogindate__c i ...
0
votes
1answer
22 views

Extract logindate from user object and populate a new field in a custom object via batch apex

I would like to apologise if any spelling mistakes , in currently posting this on an iPhone whilst I commute home I found a link online which I think meets my requirements As we are all aware ...
0
votes
0answers
20 views

Grab Date via Apex from Inbound Email

When using Salesforce for Outlook, we'd like to somehow pass the date/time the original email was sent, so we can track exactly how long a case / response took. I know there are many items that can ...
2
votes
1answer
77 views

How Do I populate the Last Login Date from User object into a custom object/field?

Aim – Pull the last login date from the user object into my custom object and populate a particular field Now I am under the impression that LastLoginDate on the user object is not accessible through ...
1
vote
1answer
89 views

Formula to calculate time between two dates, Salesforce example broken

I'm aware the question "How do I calculate the time difference between two date/times?" has been asked a lot, and not just on here. After doing the recommended thing and looking on this page (right ...
3
votes
1answer
33 views

Jitterbit time format issue

I am using Jitter bit to load the data into SFDC. I have the separate fields for date(Field1) and time(Field2) in my text file. I have the upsert query and I did the mapping for salesforce like this, ...
0
votes
1answer
52 views

How to calculate the time between to DateTimes?

I know that you can use daysBetween() for two Date objects, but what would I use to calculate the elapse time in seconds between two DateTime objects?
2
votes
1answer
49 views

Create a new date

Ok why isnt this working? it keeps saying Variable does not exist DateTime on the second to last line? String svalue = '2014-06-06T04:00:00.000+0000'; DateTime tempDate; try { tempDate = ...
2
votes
1answer
66 views

Datetime won't save using correct time zone

Ok so I've been trying to sort this out all day and I've not made a single bit of progress. I have a set up a site on Salesforce as a web service endpoint. A client's system sends an HTTP request ...
1
vote
1answer
59 views

Why is the date saving as an hour later?

The company default time zone is GMT (+00:00), and a date sent using the API is coming through like this: 09:16:37.032 (32355740)|USER_DEBUG|[17]|DEBUG|Date/Time: 2014-06-19T10:16:00.977 It ...
3
votes
0answers
108 views

Inline editing error: “Value cannot exceed 0 characters”

I'm experiencing a strange error with Salesforce's Inline Editing in a custom visualforce page. I have a sObject with a date field called Start_Date__c, and I have inline editing set up in the ...
2
votes
1answer
34 views

What is wrong with this date?

Can anyone explain what is so erroneous about this date? Class.SMSCallbackController.doGet: line 42, column 1 14:55:07.039 (39781770)|FATAL_ERROR|System.TypeException: Invalid date/time: ...
3
votes
1answer
66 views

Can Date Field have only Month & Year

I am trying to get Attendance Records where Date's are in selected month. I have create picklist on VF page for months and year, but this doesn't seem logically true ! I think that we should have ...
1
vote
1answer
52 views

Non editable fields in the runtime, can that somehow be overcome?

I try to do my dynamic filtering on the form based on an object values, entered by a user using apex:inputField. The object stays in memory and never gets inserted to the DB. When I try to assign ...
0
votes
1answer
45 views

Storing time from input field

I am working on a form that has to contain a time input, maybe something like this figure. The problem is that there's no data type such as time, and I tried to use bootstrap timepicker but it ...
0
votes
2answers
524 views

How to convert date string to DateTime type without GMT?

I have a string = '11/6/2014 '. I want to convert it to a DateTime DateTime dt = DateTime.parse('11/6/2014'); this causes an error, so I run the code below and it does work: DateTime dt = ...
0
votes
1answer
168 views

Converting external datetime or timestamp formats using existing methods?

I'm making an API callout that returns a date/time in the following format: "Thu May 8 1:21 PM EDT" as well as a timestamp in the following format (millis since unix epoch): "1399569719024" ...
1
vote
1answer
67 views

How to produce correct DateTime Format in Apex: Outputlink / Apex: Param

I am using a visualforce page email template in which Recipient is a Contact, relatedTo is an Event, it dynamically generates an *.ical Attachment. That works just fine by using <apex:outputText ...
1
vote
1answer
37 views

How does SystemDatetoLocalDate work in ET?

Using AMPscript to try and allow our sales staff to enter items in UCT but have them display elsewhere in local time. I understand that the server uses CST which like UCT doesn't shift to or from ...
1
vote
1answer
98 views

Query Activity in ExactTarget - getting date out of datetime

Using ExactTarget queries to retrieve data, i found that the regular 'Date' function that should extract only the date, without time from a column, is not working. Is there any workaround or something ...
1
vote
1answer
77 views

DateTime stored in salesforce at GMT -03:30 or at GMT +0

i have a custom object i stored startdatetime__c and enddatetime__c field.during storing i stored 4/28/2014 8:00 AM as startdatetime__c and enddatetime__c at 4/28/2014 4:00 PM but when i try to ...
1
vote
2answers
53 views

Formatting Date in Visualforce - Complex version

I have this code <font face="Arial">Invoice Date: <apex:repeat value="{!Opportunity.Invoices__r}" var="line2"> {!line2.Invoice_Date__c} </apex:repeat> </font> which ...
2
votes
1answer
315 views

Convert DateTime to Date

I want to Convert DateTime into Date I have been trying this out ..below is the code snippet public void searchSFDC() { DateTime lastModDate ; for(sObject resultSet : searchResults[0]) { // ...
1
vote
1answer
62 views

False Error during migration: Date Modified earlier than Date Created

When I try to insert some records, it throws back an Error report telling me that some of the records have a modified date before the created date. When I look at the corresponding field, this is not ...
1
vote
1answer
45 views

Date Stamp on one criteria within Picklist

I need some help Aim – When stage = ’Declined’ populate a field called “Declined date” with the date that declined was selected Field: Stage Data type : Picklist I know how to create a workflow on ...
1
vote
1answer
163 views

How to Apply a DateTime Filter when using SOQL via REST API

I'm working on a ASP.NET application which is calling our salesforce org via REST API. There is a feature to search data based on time period(DateTime field) as follows. Today Yesterday Last 7 days ...
2
votes
1answer
238 views

Manipulating the date/time field

I have a problem in manipulating my date/time fields, here is the problem: I have two date/time field for my time_off__c custom object: Start_date__c, End_date__c and a formula field number type ...
5
votes
2answers
228 views

JSON.serialize is mucking with my datetime objects. How do I fix this?

I feel that the following assertion should be true, but it is not: DateTime testDate = DateTime.now(); System.assertEquals('"' + testDate.format('yyyy-MM-dd\'T\'hh:mm:ss.SSS\'Z\'' + '"'), ...
5
votes
2answers
44 views

Is there a way to set SystemModstamp on a newly created SObject in a unit test?

I need to create a SObject in a unit test with the SystemModstamp set. I've been using Opportunities in my unit test, but I am not tied to that specific SObject. I also am not tied down to ...
3
votes
0answers
49 views

Parsing the datetime field in Site.com for pick lists

I am creating pick lists that contain months and years on an event list page in Site.com. The page brings in data for the events using a data-repeater. One of the fields being used is datetime which ...
2
votes
2answers
83 views

how to avoid picking old date in datetime picker in inline vfpage

I have a date time picker as a calendar. is there anyway that i avoid backdating in the calendar ? It should be only pick today and future dates. Thank you all.
1
vote
1answer
85 views

TIME display issues

I am using Startdatetime_c custom field as a Date/Time data type, when am inserting a record in salesforce as Startdatetime_c = 26/03/2014 10:00.This record is inserting as per my request, but when ...
0
votes
3answers
439 views

Datetime.now.getTime() not returning correct value

I am getting a timestamp for current datetime using the following code public Static String getGenerateTimeStamp() { system.debug('Datetime : '+ DateTime.now()); system.debug('timestamp : '+ ...
3
votes
2answers
119 views

Fetching the TIMEVALUE from Date/Time datatype

My Scenario is, I am having two fields as Startdatetime_c(date/time) & LastDatetime(date/time). Here another one field Nextdatetime_c(date/time Formula field) i want the Date from ...
1
vote
2answers
84 views

Can the AMPscript DatePart(D1, S1) isolate AM or PM?

I see here that S1 = The part of the date to retrieve. Valid values include year (Y), month (M), monthname, day (D), hour (H), and minute (MI). I don't see a script to isolate the part of the ...
5
votes
1answer
420 views

Clarification about Timezone Conversion in DateTime

There are lots of posts regarding DateTime format. But I have things that I still can't find a solid answer for. 1). I Noticed that datetime field values are converted into UTC and that converted ...
1
vote
1answer
349 views

ExactTarget Date and Time guidelines in AMPscript

Want to address the fact that Kelly's answers below did get me to the point of resolving this date/time challenge within AMPscript and ExactTarget. There was considerable effort involved in mastering ...
4
votes
1answer
446 views

SOQL: converting Date functions return values to specific timezone

SOQL Date functions CALENDAR_YEAR and CALENDAR_MONTH return values as UTC Timezone values. How to convert those values to specific Timezone, like Europe/Berlin ? Example time: 2014.07.01 00:00 , ...
1
vote
1answer
75 views

Suggested date & time pickers for ExactTarget Landing Pages using AMPscript?

We're trying to determine an easy and usable solution to allow our administrators to have a date & time selector (almost certainly jquery or javascript based) available for forms built in ...
2
votes
1answer
174 views

Created Date time difference

So I have a visualforce page displaying a query. But when it is being display on a force.com sites page. The created dates are different. Visualforce page inside sandbox: Visualforce page on ...
0
votes
2answers
252 views

Changing date format

I am inserting one record to Custom_object__c that object contains the DateTime field,here am a russian user to insert.If i use a date format as "Startdate:22.02.2014"(JSON request) means its accept, ...
0
votes
1answer
286 views

How to Change Time of Date/Time Field

When I am trying to save the Date/Time Field of an Object,the time should saved by round off to some fixed time e.g. when I am selecting date as 2/26/2014 the time automatically comes as the present ...
11
votes
1answer
333 views

It appears that > behaves like >= in a soql query. Why?

The query: SELECT systemmodstamp, id FROM Lead WHERE SystemModstamp > 2013-12-03T01:13:09Z AND SystemModstamp < 2014-02-11T12:18:41Z ORDER BY SystemModstamp ASC ALL ROWS returns several ...