Search Results

Search found 12481 results on 500 pages for 'date picker'.

Page 2/500 | < Previous Page | 1 2 3 4 5 6 7 8 9 10 11 12  | Next Page >

  • Finding date between start date and end date

    - by Pankaj Khurana
    Hi, I want to check whether a date is between start date and end date. i have added a where class where datepaid between '2010-04-01' AND '2010-04-15' but the problem is that it excludes '2010-04-15'. It should include end date also how can i do this? Please help me on this Regards, pankaj

    Read the article

  • Solr date field tdate vs date?

    - by user550178
    So I have a question about Solr's field date types which is pretty straight forward: what's the difference between a 'date' field and a 'tdate' one? The schema .xml claims that 'For faster range queries, consider the tdate type' and 'A Trie based date field for faster date range queries and date faceting. ' Fair enough... but what's the precisionStep="6" all about? should i change this? does it change the way i would create the query in case I use the tdate? What's the real advantage or what does Solr do that makes it better? P.S went through google, Solr manual, solr wiki and the java docs without any luck so I'd appreciate a kind and explanatory answer :)... Also checked: http://www.lucidimagination.com/blog/2009/05/13/exploring-lucene-and-solrs-trierange-capabilities/ http://web.archiveorange.com/archive/v/AAfXfqRYyLnDFtskmLRi

    Read the article

  • How to maintain a file's 'last modified' date ?

    - by Will.
    I'm copying files and folders over from one filesystem to another (both are ext3) via cp in the terminal. The 'date modified' on all of the files are being changed to the current time although I am not modifying the folder or the files. I'd like for them to keep their existing 'last modified date' which vary within the past 5 years. I am not interested in changing them to a specific date as described this previous question, but to maintain the existing 'last modified' date. I'm using 12.04.

    Read the article

  • Mapping java.util.Date to xs:date instead of xs:dateTime in JAX-WS

    - by Larsing
    Hi all, We hav an EJB, jws-anotated as a web service. It has a pretty complex pojo-model that generates an equally complex xsd. The pojos contain numerous java.util.Date. These all map to xs:dateTime. This service is used as "business service" in Oracle(BEA) OSB(AquaLogic). We also have a "proxy service" which we map to the BS with XQuery (the OSB/AquaLogic way). The proxy service's xsd has xs:date for the corresponding fields. For some reason, Oracle's implementation of XQuery does not support casting from xs:date to xs:dateTime(!). I could solve this by casting to xs:string and concat:ing with "T00:00:00", however, i would rather try to get JAX-WS to generate an xsd with xs:date instead. Only, I can't find any info on how to do this (anotations?). Can anyone give me a hint? Kind regards, Lars

    Read the article

  • Checking date against date range in Python

    - by Flowpoke
    I have a date variable: 2011-01-15 and I would like to get a boolean back if said date is within 3 days from TODAY. Im not quite sure how to construct this in Python. Im only dealing with date, not datetime. My working example is a "grace period". A user logs into my site and if the grace period is within 3 days of today, additional scripts, etc. are omitted for that user. I know you can do some fancy/complex things in Python's date module(s) but Im not sure where to look.

    Read the article

  • Ubuntu one changes 'Date modified' to time and date of sync

    - by Philippe
    I'm wondering why ubuntu one changes the date of the synced files. Instead of leaving the actual date and time of modification it updates the time and date to the sync time. So, e.g., if I change and save a file today at july 26 2 pm and I go home and sync my home-pc with u1 tomorrow at 10 the 'Date modified' of that file will reflect the syncdate which might be July 27, 10am. I don't like that behavior and I don't understand if this is a bug or if that is actually intended?

    Read the article

  • how to store a date, and then check to see if another date matches that date

    - by user797963
    I'm trying to figure out dates in Java and am completely lost. Do I use Date? Use epoch time? Gregorian Calendar? Let's say I have a want to store a date, then later compare it to other dates. For example, I've stored a date "10/27/2013". Then, I want to later compare it to dates entered later to see if a later date is identical to "10/27/2013", or if just the day, year, or month matches? What's the best way to do this?

    Read the article

  • Wrong date with ruby Date.today and DateTime.now

    - by Rob
    I've installed ruby-1.8.6-p383 with RVM. System ruby is 1.9.1_p378-1 I'm getting the wrong date from Date.today and DateTime.now when using ruby 1.8.. Whereas Time.now is correct: irb(main):002:0> DateTime.now.to_s => "2126--1-10618T11:23:43+00:00" irb(main):004:0> Date.today.to_s => "2126--1-10618" irb(main):005:0> Time.now => Thu Jan 28 11:55:27 +0000 2010 All is well if I switch to ruby 1.9: irb(main):003:0> DateTime.now.to_s => "2010-01-28T11:58:51+00:00" irb(main):004:0> Date.today.to_s => "2010-01-28" irb(main):005:0> Time.now => 2010-01-28 11:59:05 +0000 Any advice on how to get DateTime to work properly in ruby 1.8 would be most appreciated!

    Read the article

  • Inconsistency between date-time in terminal and clock

    - by Franck
    I can't figure out why I have 5 hours difference between GUI clock and date command in terminal. My bios clock is set to GMT... Any ideas ? franck@franck-ThinkPad-T61:~$ date mercredi 11 avril 2012, 02:48:47 (UTC-0500) franck@franck-ThinkPad-T61:~$ sudo dpkg-reconfigure tzdata Current default time zone: 'Europe/Paris' Local time is now: Wed Apr 11 09:49:02 CEST 2012. Universal Time is now: Wed Apr 11 07:49:02 UTC 2012. franck@franck-ThinkPad-T61:~$ tail /etc/timezone Europe/Paris franck@franck-ThinkPad-T61:~$ date mercredi 11 avril 2012, 02:49:21 (UTC-0500) franck@franck-ThinkPad-T61:~$ sudo dpkg-reconfigure --frontend noninteractive tzdata Current default time zone: 'Europe/Paris' Local time is now: Wed Apr 11 09:49:27 CEST 2012. Universal Time is now: Wed Apr 11 07:49:27 UTC 2012. franck@franck-ThinkPad-T61:~$ date mercredi 11 avril 2012, 02:49:30 (UTC-0500) franck@franck-ThinkPad-T61:~$ sudo cat /etc/default/rcS # # /etc/default/rcS # # Default settings for the scripts in /etc/rcS.d/ # # For information about these variables see the rcS(5) manual page. # # This file belongs to the "initscripts" package. TMPTIME=0 SULOGIN=no DELAYLOGIN=no UTC=yes VERBOSE=no FSCKFIX=no franck@franck-ThinkPad-T61:~$ sudo hwclock --show mer. 11 avril 2012 07:49:48 CDT -0.555705 secondes

    Read the article

  • One Linux server has two timer

    - by garconcn
    The time on one of our Linux box is very weird. Whenever I call date 3 times, the 4th call will give a wrong time(usually 1 hour later). I have setup cron to sync with ntp server. We have 20+ similar servers, only this one has this problem. Any idea? Thanks. Linux 2.6.18-6-686 #1 SMP Thu Aug 20 21:56:59 UTC 2009 i686 GNU/Linux :~# date Fri Jun 11 17:00:51 PDT 2010 :~# date Fri Jun 11 17:00:52 PDT 2010 :~# date Fri Jun 11 17:00:53 PDT 2010 :~# date Fri Jun 11 18:14:12 PDT 2010 :~# date Fri Jun 11 17:00:55 PDT 2010 :~# date Fri Jun 11 17:00:56 PDT 2010 :~# date Fri Jun 11 17:00:56 PDT 2010 :~# date Fri Jun 11 18:14:15 PDT 2010 :~# date Fri Jun 11 17:00:58 PDT 2010 :~# date Fri Jun 11 17:00:58 PDT 2010 :~# date Fri Jun 11 17:00:59 PDT 2010 :~# date Fri Jun 11 18:14:18 PDT 2010 :~# date Fri Jun 11 17:01:01 PDT 2010 :~# date Fri Jun 11 17:01:01 PDT 2010 :~# date Fri Jun 11 17:01:02 PDT 2010 :~# date Fri Jun 11 18:14:21 PDT 2010 :~# date Fri Jun 11 17:01:03 PDT 2010 :~# date Fri Jun 11 17:01:04 PDT 2010 :~# date Fri Jun 11 17:01:05 PDT 2010

    Read the article

  • Jquery Date Picker: Append Start Date to End Date and display dates in the future only.

    - by Tim
    Hello, I am using Jquery Date pickers to get Start and End Dates for an application I am building. I have two datepickers, one for a start date and one for an end date. When someone clicks a date in the start date picker I need that date to be appended automatically to the end date picker. I also need the end date picker to select future dates only from the date that has been appended to it. There are two demos on the jquery datepicker site that do what I want, but I am unsure how to combine them to both do what I want. Example One: This example shows how you can tie two date pickers together so that the date selected in one influences the dates that can be selected in the other $(function() { $('.date-pick').datePicker() $('#start-date').bind( 'dpClosed', function(e, selectedDates) { var d = selectedDates[0]; if (d) { d = new Date(d); $('#end-date').dpSetStartDate(d.addDays(1).asString()); } } ); $('#end-date').bind( 'dpClosed', function(e, selectedDates) { var d = selectedDates[0]; if (d) { d = new Date(d); $('#start-date').dpSetEndDate(d.addDays(-1).asString()); } } ); }); Example Two: An example showing inline date pickers which are linked together and trigger behaviour in each other... $(function() { $('#date-view1') .datePicker({inline:true}) .bind( 'dateSelected', function(e, selectedDate, $td) { $('#date1').val(selectedDate.asString()); $('#date-view2, #date-view3').dpSetSelected(selectedDate.addDays(3).asString()); } ); $('#date-view2') .datePicker({inline:true}) .bind( 'dateSelected', function(e, selectedDate, $td) { $('#date2').val(selectedDate.asString()); } ); $('#date-view3').datePicker(); $('#form-check') .bind( 'click', function() { alert('date1=' + $('#date1').val() + '\n' + 'date2=' + $('#date2').val()); } ); }); I have tried many combinations of the codes listed above, but I have not been able to get the desired results. Thanks for all your help, Tim

    Read the article

  • Implement date picker and time picker in button click and store in edit text boxes

    - by user3597791
    Hi I am trying to implement a date picker and time picker in button click and store in edit text boxes. I have tried numerous things but since i suck at coding I cant get any of them to work. Please find my class and xml below and i would be grateful for any help import android.app.Activity; import android.content.Intent; import android.database.Cursor; import android.graphics.BitmapFactory; import android.net.Uri; import android.os.Bundle; import android.provider.MediaStore; import android.view.View; import android.view.View.OnClickListener; import android.widget.Button; import android.widget.EditText; import android.widget.ImageView; import android.widget.Toast; public class NewEvent extends Activity { private static int RESULT_LOAD_IMAGE = 1; private EventHandler handler; private String picturePath = ""; private String name; private String place; private String date; private String time; private String photograph; @Override protected void onCreate(Bundle savedInstanceState) { super.onCreate(savedInstanceState); setContentView(R.layout.new_event); handler = new EventHandler(getApplicationContext()); ImageView iv_user_photo = (ImageView) findViewById(R.id.iv_user_photo); iv_user_photo.setOnClickListener(new OnClickListener() { @Override public void onClick(View arg0) { Intent intent = new Intent(Intent.ACTION_PICK, android.provider.MediaStore.Images.Media.EXTERNAL_CONTENT_URI); startActivityForResult(intent, RESULT_LOAD_IMAGE); } }); Button btn_add = (Button) findViewById(R.id.btn_add); btn_add.setOnClickListener(new OnClickListener() { @Override public void onClick(View arg0) { EditText et_name = (EditText) findViewById(R.id.et_name); name = et_name.getText().toString(); EditText et_place = (EditText) findViewById(R.id.et_place); place = et_place.getText().toString(); EditText et_date = (EditText) findViewById(R.id.et_date); date = et_date.getText().toString(); EditText et_time = (EditText) findViewById(R.id.et_time); time = et_time.getText().toString(); ImageView iv_photograph = (ImageView) findViewById(R.id.iv_user_photo); photograph = picturePath; Event event = new Event(); event.setName(name); event.setPlace(place); event.setDate(date); event.setTime(time); event.setPhotograph(photograph); Boolean added = handler.addEventDetails(event); if(added){ Intent intent = new Intent(NewEvent.this, MainEvent.class); startActivity(intent); }else{ Toast.makeText(getApplicationContext(), "Event data not added. Please try again", Toast.LENGTH_LONG).show(); } } }); } @Override protected void onActivityResult(int requestCode, int resultCode, Intent data) { super.onActivityResult(requestCode, resultCode, data); if (requestCode == RESULT_LOAD_IMAGE && resultCode == RESULT_OK && null != data) { Uri imageUri = data.getData(); String[] filePathColumn = { MediaStore.Images.Media.DATA }; Cursor cursor = getContentResolver().query(imageUri, filePathColumn, null, null, null); cursor.moveToFirst(); int columnIndex = cursor.getColumnIndex(filePathColumn[0]); picturePath = cursor.getString(columnIndex); cursor.close(); Here is my xml: <?xml version="1.0" encoding="utf-8"?> <RelativeLayout xmlns:android="http://schemas.android.com/apk/res/android" android:layout_width="match_parent" android:layout_height="match_parent" android:orientation="vertical" android:padding="10dp"> <TextView android:id="@+id/tv_new_event_title" android:layout_width="wrap_content" android:layout_height="wrap_content" android:text="Add New Event" android:textAppearance="?android:attr/textAppearanceLarge" android:layout_alignParentTop="true" /> <Button android:id="@+id/btn_add" android:layout_width="match_parent" android:layout_height="wrap_content" android:text="Add Event" android:layout_alignParentBottom="true" /> <ScrollView android:layout_width="match_parent" android:layout_height="match_parent" android:layout_below="@id/tv_new_event_title" android:layout_above="@id/btn_add"> <LinearLayout android:layout_width="fill_parent" android:layout_height="wrap_content" android:orientation="vertical"> <ImageView android:id="@+id/iv_user_photo" android:src="@drawable/add_user_icon" android:layout_width="100dp" android:layout_height="100dp"/> <TextView android:layout_width="wrap_content" android:layout_height="wrap_content" android:text="Event:" /> <EditText android:id="@+id/et_name" android:layout_width="match_parent" android:layout_height="wrap_content" android:ems="10" android:inputType="text" > <requestFocus /> </EditText> <TextView android:layout_width="wrap_content" android:layout_height="wrap_content" android:text="Place:" /> <EditText android:id="@+id/et_place" android:layout_width="match_parent" android:layout_height="wrap_content" android:ems="10" android:inputType="text" > <requestFocus /> </EditText> <TextView android:layout_width="wrap_content" android:layout_height="wrap_content" android:text="Date:" /> <EditText android:id="@+id/et_date" android:layout_width="match_parent" android:layout_height="wrap_content" android:ems="10" android:inputType="date" /> <Button android:id="@+id/button" style="?android:attr/buttonStyleSmall" android:layout_width="wrap_content" android:layout_height="wrap_content" android:text="Button" /> <requestFocus /> <TextView android:layout_width="wrap_content" android:layout_height="wrap_content" android:text="Time:" /> <EditText android:id="@+id/et_time" android:layout_width="match_parent" android:layout_height="wrap_content" android:ems="10" android:inputType="time" /> <Button android:id="@+id/button1" style="?android:attr/buttonStyleSmall" android:layout_width="wrap_content" android:layout_height="wrap_content" android:text="Button1" /> <requestFocus /> </LinearLayout> </ScrollView> </RelativeLayout>

    Read the article

  • get date from string php - UK date

    - by julio
    Hi-- I have a UK date in the format "06/Apr/2010 13:24" that I need to insert into a mysql db date field. The PHP strtotime function can't handle this string-- has anyone got any ideas other than writing a custom function? Thanks!

    Read the article

  • Validate a date range within MySQL query

    - by fishcracker
    (This question may seem easy or kind of noobish, by that I pardon my ignorance.) I used PDO query to use SELECT then fetch some values, it comes to a point that I need to fetch only some entries that within its start date and end date. My database +----------+-----------------+----------------------+--------------------+ | id (INT) | title (VARCHAR) | start_date (VARCHAR) | end_date (VARCHAR) | +----------+-----------------+----------------------+--------------------+ | 1 | buddy | 2012-11-26 | 2012-11-30 | | 2 | metro | 2012-12-05 | 2012-12-20 | | 3 | justin | 2012-11-28 | 2012-12-01 | +----------+-----------------+----------------------+--------------------+ My query is as follows: $query = "SELECT title, start_date, end_date FROM debts WHERE start_date >= CURDATE() AND end_date >= CURDATE()"; What I want to achieve is whenever the start_date is today or greater but not exceeding the end_date it will be valid. This will return the row for id 1, however if I change the start_date to 2012-11-25, it will fail due to the first condition on AND. I'm really confuse on this since I am new to this, is there any built-in function to handle this kind of situation?

    Read the article

  • iPhone SDK Objective-C __DATE__ (compile date) can't be converted to an NSDate

    - by Janice
    //NSString *compileDate = [NSString stringWithFormat:@"%s", __DATE__]; NSString *compileDate = [NSString stringWithUTF8String:__DATE__]; NSDateFormatter *df = [[[NSDateFormatter alloc] init] autorelease]; [df setDateFormat:@"MMM d yyyy"]; //[df setDateFormat:@"MMM dd yyyy"]; NSDate *aDate = [df dateFromString:compileDate]; Ok, I give up. Why would aDate sometimes return as nil? Should it matter if I use the commented-out lines... or their matching replacement lines?

    Read the article

  • JQuery "Any Row" Picker

    - by Eli
    Hi All, I'm looking for a generic "Row Picker" for JQuery. We've all seen the cool "Picker" tools like date pickers, color pickers, time pickers, etc, where you click in a text box and a little calendar or color palate or clock or something comes up. You select something (like a date) and the text box is then populated with a value. I really need an all-purpose "row picker" where you can populate something (a table, divs, etc) with some rows of data (say a list of timezones). This would be linked to a text field and would pop up when the user clicks in the field. They would click a row (say a timezone), and the timezone id would be passed back to the field. Anyone know of anything that does this? Thanks!

    Read the article

  • Get Current QuarterEnd for a given FYE Date

    - by Rohit Gupta
    Here is the code to get the Current Quarter End for a Given FYE Date: 1: public static DateTime ThisQuarterEnd(this DateTime date, DateTime fyeDate) 2: { 3: IEnumerable<DateTime> candidates = 4: QuartersInYear(date.Year, fyeDate.Month).Union(QuartersInYear(date.Year + 1, fyeDate.Month)); 5: return candidates.Where(d => d.Subtract(date).Days >= 0).First(); 6: } 7:  8: public static IEnumerable<DateTime> QuartersInYear(int year, int q4Month) 9: { 10: int q1Month = 3, q2Month = 6, q3Month = 9; 11: int q1year = year, q2year = year, q3year = year; 12: int q1Day = 31, q2Day = 31, q3Day = 31, q4Day = 31; 13:  14: 15: q3Month = q4Month - 3; 16: if (q3Month <= 0) 17: { 18: q3Month = q3Month + 12; 19: q3year = year - 1; 20: } 21: q2Month = q4Month - 6; 22: if (q2Month <= 0) 23: { 24: q2Month = q2Month + 12; 25: q2year = year - 1; 26: } 27: q1Month = q4Month - 9; 28: if (q1Month <= 0) 29: { 30: q1Month = q1Month + 12; 31: q1year = year - 1; 32: } 33:  34: q1Day = new DateTime(q1year, q1Month, 1).AddMonths(1).AddDays(-1).Day; 35: q2Day = new DateTime(q2year, q2Month, 1).AddMonths(1).AddDays(-1).Day; 36: q3Day = new DateTime(q3year, q3Month, 1).AddMonths(1).AddDays(-1).Day; 37: q4Day = new DateTime(year, q4Month, 1).AddMonths(1).AddDays(-1).Day; 38:  39: return new List<DateTime>() { 40: new DateTime(q1year, q1Month, q1Day), 41: new DateTime(q2year, q2Month, q2Day), 42: new DateTime(q3year, q3Month, q3Day), 43: new DateTime(year, q4Month, q4Day), 44: }; 45:  46: } The code to get the NextQuarterEnd is simple, just Change the Where clause to read d.Subtract(date).Days > 0 instead of d.Subtract(date).Days >= 0 1: public static DateTime NextQuarterEnd(this DateTime date, DateTime fyeDate) 2: { 3: IEnumerable<DateTime> candidates = 4: QuartersInYear(date.Year, fyeDate.Month).Union(QuartersInYear(date.Year + 1, fyeDate.Month)); 5: return candidates.Where(d => d.Subtract(date).Days > 0).First(); 6: } Also if you need to get the Quarter Label for a given Date, given a particular FYE date then following is the code to use: 1: public static string GetQuarterLabel(this DateTime date, DateTime fyeDate) 2: { 3: int q1Month = fyeDate.Month - 9, q2Month = fyeDate.Month - 6, q3Month = fyeDate.Month - 3; 4:  5: int year = date.Year, q1Year = date.Year, q2Year = date.Year, q3Year = date.Year; 6: 7: if (q1Month <= 0) 8: { 9: q1Month += 12; 10: q1Year = year + 1; 11: } 12: if (q2Month <= 0) 13: { 14: q2Month += 12; 15: q2Year = year + 1; 16: } 17: if (q3Month <= 0) 18: { 19: q3Month += 12; 20: q3Year = year + 1; 21: } 22:  23: string qtr = ""; 24: if (date.Month == q1Month) 25: { 26: qtr = "Qtr1"; 27: year = q1Year; 28: } 29: else if (date.Month == q2Month) 30: { 31: qtr = "Qtr2"; 32: year = q2Year; 33: } 34: else if (date.Month == q3Month) 35: { 36: qtr = "Qtr3"; 37: year = q3Year; 38: } 39: else if (date.Month == fyeDate.Month) 40: { 41: qtr = "Qtr4"; 42: year = date.Year; 43: } 44:  45: return string.Format("{0} - {1}", qtr, year.ToString()); 46: }

    Read the article

< Previous Page | 1 2 3 4 5 6 7 8 9 10 11 12  | Next Page >