Results 1 to 3 of 3
  1. #1
    New Lounger
    Join Date
    Jun 2004
    Posts
    22
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Data Types (Access 2000)

    Can you create a macro that changes a data type? Currently, I have a table with a column that has a data type of text and I need the data type to be number. Can this be done in a macro? If yes, what action or function would I need to use?

  2. #2
    Plutonium Lounger
    Join Date
    Mar 2002
    Posts
    84,353
    Thanks
    0
    Thanked 29 Times in 29 Posts

    Re: Data Types (Access 2000)

    Welcome to Woody's Lounge.

    You can't do that in a macro, you would need to run a special kind of query. But why not do it interactively?

    See <post#=227451>post 227451</post#> and <post#=269283>post 269283</post#> for some examples of VBA code to run the SQL needed to change the data type of a column.

  3. #3
    Super Moderator
    Join Date
    Jun 2002
    Location
    Mt Macedon, Victoria, Australia
    Posts
    3,993
    Thanks
    1
    Thanked 45 Times in 44 Posts

    Re: Data Types (Access 2000)

    Why create a macro? Just go to the database window, open the table in design view , and change the data type.

    Is the data currently entered consistent with a number format?
    Regards
    John



Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •