Consulting

Results 1 to 7 of 7

Thread: Help with Maketable query

  1. #1
    VBAX Tutor jamescol's Avatar
    Joined
    May 2004
    Location
    Charlotte, NC
    Posts
    251
    Location

    Help with Maketable query

    I'm hoping one of you Access gurus here can help this guy with a maketable query (Acc 97). I'm not proficient with this kind of query.

    http://forums.techguy.org/t266291.html

    Thanks,
    James
    "All that's necessary for evil to triumph is for good men to do nothing."

  2. #2
    VBAX Master TonyJollans's Avatar
    Joined
    May 2004
    Location
    Norfolk, England
    Posts
    2,291
    Location
    Hi James,

    It's hard to tell from the thread exactly what is going on but a couple of thoughts.

    Where is the order being checked? What else (post-query) might affect it? When you run a Query it should order records according to the Order By in the query. When the results of that query are written to a table they are not explicitly ordered within that table. If you then look at that table the query no longer has anything to do with the sequence of the records and they may be displayed in any order. In effect (AFAIK) putting an Order By on a Make Table query is pointless - records in a table do not have any inherent order. If you want to process the records in the new table in a particular sequence you need to say so at the time you process them. Do the records show in the expected sequence when the query results are checked from query design?

    Not directly related to the problem but, assuming his date fields are Date/Time datatypes there is no point in ordering separately on the year and month components - just order by on the date.
    Enjoy,
    Tony

    ---------------------------------------------------------------
    Give a man a fish and he'll eat for a day.
    Teach him how to fish and he'll sit in a boat and drink beer all day.

    I'm (slowly) building my own site: www.WordArticles.com

  3. #3
    Site Admin
    The Princess
    VBAX Guru Anne Troy's Avatar
    Joined
    May 2004
    Location
    Arlington Heights, IL
    Posts
    2,530
    Location
    James: Do you know how many times I've wanted to do that? I'm glad you did it. If everyone thinks that it's appropriate to do that, I say we do it.

    "THAT" meaning post a link from another forum where we're having trouble.

    I think it's a cool idea.
    ~Anne Troy

  4. #4
    VBAX Master TonyJollans's Avatar
    Joined
    May 2004
    Location
    Norfolk, England
    Posts
    2,291
    Location
    I guess it depends on the forum. If the link works for everybody (and not just members of the linked to forum) then it seems fine to me.

    Only thing is I wasn't sure where to post - here or there. I decided I have enough trouble keeping tabs on what I do as it is and that I'd probably forget to go back and check the tech support guy - I might forget to check here of course
    Enjoy,
    Tony

    ---------------------------------------------------------------
    Give a man a fish and he'll eat for a day.
    Teach him how to fish and he'll sit in a boat and drink beer all day.

    I'm (slowly) building my own site: www.WordArticles.com

  5. #5
    VBAX Tutor jamescol's Avatar
    Joined
    May 2004
    Location
    Charlotte, NC
    Posts
    251
    Location
    Tony,
    I was think the same thing about why the order matters if it's just another table. But I didn't ask the guy. Maybe he's displaying the table in a dataview as if it were a report.

    I'm just not familiar with the maketable syntax to be much help either way.

    James
    "All that's necessary for evil to triumph is for good men to do nothing."

  6. #6
    VBAX Tutor jamescol's Avatar
    Joined
    May 2004
    Location
    Charlotte, NC
    Posts
    251
    Location
    Quote Originally Posted by Dreamboat
    James: Do you know how many times I've wanted to do that? I'm glad you did it. If everyone thinks that it's appropriate to do that, I say we do it.

    "THAT" meaning post a link from another forum where we're having trouble.

    I think it's a cool idea.
    You know, I didn't even think about the appropriateness of my post here. I was just thinking of the best way to help the guy, and didn't figure TSM would like it if I told him to check here for the "cream of the crop" Access coders.

    James
    "All that's necessary for evil to triumph is for good men to do nothing."

  7. #7
    VBAX Master TonyJollans's Avatar
    Joined
    May 2004
    Location
    Norfolk, England
    Posts
    2,291
    Location
    I just posted there as well. The questioner says it's sorted all by itself - I'll see if he comes back.
    Enjoy,
    Tony

    ---------------------------------------------------------------
    Give a man a fish and he'll eat for a day.
    Teach him how to fish and he'll sit in a boat and drink beer all day.

    I'm (slowly) building my own site: www.WordArticles.com

Posting Permissions

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