Results 1 to 6 of 6
  1. #1
    R3mix3r is offline Novice
    Windows 7 32bit Access 2010 32bit
    Join Date
    Sep 2011
    Posts
    3

    Stop Access Changing My Data

    HI,
    I have an Access 2000 database in which i am importing some data programmatically through VB6
    However for some reason Access is changing the data that i am sending it (i know it's access doing it as a manual import does the same thing)

    Example data (dashes signify different columns 4 total)



    8/31/11 - 08:30:45 - 1 - 003

    this gets changed by access to

    8/31/11 - 8:30:45 AM - 1 - 3

    Note it changed the time to am/pm format and my 003 became 3
    I have all the database fields set as TEXT and not numbers / date & time so I would think that it would treat the data literally however that is not the case and my data gets messed up.

    How do i tell access to stop messing with the data and treat it literally and not change anything ?

    Thanks in advance !
    Pete

  2. #2
    RuralGuy's Avatar
    RuralGuy is offline Administrator
    Windows 7 64bit Access 2010 32bit
    Join Date
    Mar 2007
    Location
    8300' in the Colorado Rocky Mountains
    Posts
    12,922
    The data you are importing are not strings in your source so Access is guessing DateTime and numbers (usually Double). FYI you can display these values any way you want regardless of how they are stored on the table using the Format() function.

  3. #3
    R3mix3r is offline Novice
    Windows 7 32bit Access 2010 32bit
    Join Date
    Sep 2011
    Posts
    3
    Quote Originally Posted by RuralGuy View Post
    The data you are importing are not strings in your source so Access is guessing DateTime and numbers (usually Double). FYI you can display these values any way you want regardless of how they are stored on the table using the Format() function.
    The Data is being transferred into access from a CSV file using VB6 Code .. it should be being treated as strings, when i go to display the data in VB6 i am displaying it in a flexgrid which for the amount of records i have will take a long time for it to format the data in the columns, i'd rather not have to format the data and have access import it without making changes to the data, is there a way to do this ???

  4. #4
    RuralGuy's Avatar
    RuralGuy is offline Administrator
    Windows 7 64bit Access 2010 32bit
    Join Date
    Mar 2007
    Location
    8300' in the Colorado Rocky Mountains
    Posts
    12,922
    I would think that this would be handled in VB6.

  5. #5
    R3mix3r is offline Novice
    Windows 7 32bit Access 2010 32bit
    Join Date
    Sep 2011
    Posts
    3
    o.k. i fixed this, it was an access issue if you hit ADVANCED when doing an import of a text file there are 2 boxes one is for a date qualifier and one is for a time qualifier ... in this case the date qualifer was set to / and the time qualifier set to :
    i deleted both of these and saved the setup specs
    In VB6 i can recall those specs during the import process
    Problem solved

  6. #6
    RuralGuy's Avatar
    RuralGuy is offline Administrator
    Windows 7 64bit Access 2010 32bit
    Join Date
    Mar 2007
    Location
    8300' in the Colorado Rocky Mountains
    Posts
    12,922
    Excellent! Thanks for posting back with your success and solution.

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

Similar Threads

  1. stop access from auto adding records
    By svcghost in forum Forms
    Replies: 2
    Last Post: 10-21-2010, 05:25 PM
  2. changing data in many records
    By cforce in forum Programming
    Replies: 1
    Last Post: 07-22-2010, 02:30 PM
  3. Replies: 2
    Last Post: 11-29-2009, 12:00 PM
  4. Changing data in excel from access
    By ricardo9211 in forum Import/Export Data
    Replies: 1
    Last Post: 08-26-2009, 01:46 AM
  5. Replies: 3
    Last Post: 04-27-2009, 02:29 PM

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