Date Field Masks

Collapse
This topic is closed.
X
X
 
  • Time
  • Show
Clear All
new posts
  • andrew@playdar.co.uk

    Date Field Masks

    Hi,

    I am trying to develop a database that will store dates in the format -
    21.02.2006 rather than the standard 21/02/2006.

    This is because of the SAP feeds that i am pulling in - since SAP
    stores dates as dd.mm.yyyy

    I would just store the dates as text but this makes processing the data
    much harder.

    Does anyone have any suggestions?

    Regards

    Andrew Paton

  • Tanis

    #2
    Re: Date Field Masks


    andrew@playdar. co.uk wrote:
    Hi,
    >
    I am trying to develop a database that will store dates in the format -
    21.02.2006 rather than the standard 21/02/2006.
    >
    This is because of the SAP feeds that i am pulling in - since SAP
    stores dates as dd.mm.yyyy
    >
    I would just store the dates as text but this makes processing the data
    much harder.
    >
    Does anyone have any suggestions?
    >
    Regards
    >
    Andrew Paton
    You can use a custom format for the dates.

    SELECT tblTableName.Fl dDates, Format([FldDates],"dd\.mm\.yyyy" ) AS
    NewDate
    FROM tblTableName;

    Comment

    • Patonar

      #3
      Re: Date Field Masks

      Ok,

      Its not the displaying that was the problem - it was mainly the problem
      of inputting the data - see all of our staff use SAP on a regular basis
      so it is second nature to type the date in the format dd.mm.yyyy -
      whereas it will be stored in the database int the format dd/mm/yyyy - i
      cant get an input mask to give me the right result! Any ideas?


      Tanis wrote:
      andrew@playdar. co.uk wrote:
      Hi,

      I am trying to develop a database that will store dates in the format -
      21.02.2006 rather than the standard 21/02/2006.

      This is because of the SAP feeds that i am pulling in - since SAP
      stores dates as dd.mm.yyyy

      I would just store the dates as text but this makes processing the data
      much harder.

      Does anyone have any suggestions?

      Regards

      Andrew Paton
      You can use a custom format for the dates.
      >
      SELECT tblTableName.Fl dDates, Format([FldDates],"dd\.mm\.yyyy" ) AS
      NewDate
      FROM tblTableName;

      Comment

      • Tanis

        #4
        Re: Date Field Masks


        Patonar wrote:
        Ok,
        >
        Its not the displaying that was the problem - it was mainly the problem
        of inputting the data - see all of our staff use SAP on a regular basis
        so it is second nature to type the date in the format dd.mm.yyyy -
        whereas it will be stored in the database int the format dd/mm/yyyy - i
        cant get an input mask to give me the right result! Any ideas?
        >
        >
        Tanis wrote:
        andrew@playdar. co.uk wrote:
        Hi,
        >
        I am trying to develop a database that will store dates in the format -
        21.02.2006 rather than the standard 21/02/2006.
        >
        This is because of the SAP feeds that i am pulling in - since SAP
        stores dates as dd.mm.yyyy
        >
        I would just store the dates as text but this makes processing the data
        much harder.
        >
        Does anyone have any suggestions?
        >
        Regards
        >
        Andrew Paton
        You can use a custom format for the dates.

        SELECT tblTableName.Fl dDates, Format([FldDates],"dd\.mm\.yyyy" ) AS
        NewDate
        FROM tblTableName;
        If you are not bothered by the format, I would stick having an input
        mask for short date. The users won't know any difference when inputting
        as the input mask takes care of the placeholder. Change the format of
        the field to Short Date and select Short Date as the input mask. You
        can try to create your own input mask, but I have not been successful.

        Comment

        Working...