Results 1 to 7 of 7
  1. #1
    Goose is offline Novice
    Windows 7 64bit Access 2010 64bit
    Join Date
    Aug 2014
    Location
    Calgary, Canada
    Posts
    2

    HELP! Query output autoformats number in text format as dates

    I have a table with a series of ID's which I need to keep in text format. The ID's look something like this in the table:

    201111464


    201111474
    201111491

    When I run a query to find duplicates, the query outputs the same ID's in this format:

    12/1/2002
    12/1/2002
    12/1/2003

    it's autoformatting them into dates, how can I stop this?

  2. #2
    ItsMe's Avatar
    ItsMe is offline Sometimes Helpful
    Windows 7 64bit Access 2010 32bit
    Join Date
    Aug 2013
    Posts
    7,862
    What is the data type of the field in the table? What is your SQL for the SELECT query?

  3. #3
    Goose is offline Novice
    Windows 7 64bit Access 2010 64bit
    Join Date
    Aug 2014
    Location
    Calgary, Canada
    Posts
    2
    Data type is TEXT the SQL is simple:

    SELECT UniqueID_MASTER.[UniqueID], UniqueID_MASTER.[PCClassification], UniqueID_MASTER.[dataid]
    FROM UniqueID_MASTER
    WHERE (((UniqueID_MASTER.[UniqueID]) In (SELECT [UniqueID] FROM [UniqueID_MASTER] As Tmp GROUP BY [UniqueID] HAVING Count(*)>1 )))
    ORDER BY UniqueID_MASTER.[UniqueID];

  4. #4
    June7's Avatar
    June7 is offline VIP
    Windows 7 64bit Access 2010 32bit
    Join Date
    May 2011
    Location
    The Great Land
    Posts
    53,624
    I am confused. Why would UniqueID have multiple records in UniqueID_Master?

    I don't see anything in query to cause this issue.

    If you want to provide db for analysis, follow instructions at bottom of my post.
    How to attach file: http://www.accessforums.net/showthread.php?t=70301 To provide db: copy, remove confidential data, run compact & repair, zip w/Windows Compression.

  5. #5
    ItsMe's Avatar
    ItsMe is offline Sometimes Helpful
    Windows 7 64bit Access 2010 32bit
    Join Date
    Aug 2013
    Posts
    7,862
    June's correct. So far, there is not a reason for the symptom you describe. You must be looking at a textbox control that is formatted as Date. Perhaps create a new textbox control and then bind it to your dataid field, without formatting.

  6. #6
    Bob Fitz's Avatar
    Bob Fitz is offline Access Developer
    Windows 7 32bit Access 2003
    Join Date
    May 2011
    Location
    Essex UK
    Posts
    3,610
    Could this be caused by corruption. I can't see how the numeric data in OP can be changed to date values in the OP
    If this helped, please click the star at the bottom left of this posting and add to my reputation . Many thanks.
    Bob Fitzpatrick

  7. #7
    John_G is offline VIP
    Windows 7 32bit Access 2010 32bit
    Join Date
    Oct 2011
    Location
    Ottawa, ON (area)
    Posts
    2,615
    Did you check the format of that column in the query design? Right-click the column, then select Properties (that is for A2003 - A2010 might be different). What is the Format set to?

    John

Please reply to this thread with any new information or opinions.

Similar Threads

  1. Replies: 4
    Last Post: 04-23-2014, 04:35 PM
  2. Format Formula - Text as Number
    By Madmartigan in forum Queries
    Replies: 8
    Last Post: 03-04-2014, 03:23 PM
  3. Managing Text Output Format in Notepad
    By dynamictiger in forum Programming
    Replies: 1
    Last Post: 08-07-2013, 03:40 PM
  4. Replies: 1
    Last Post: 02-12-2013, 09:12 AM
  5. Replies: 10
    Last Post: 09-21-2012, 09:00 AM

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  
Other Forums: Microsoft Office Forums