Results 1 to 10 of 10
  1. #1
    Dornenhexe is offline Novice
    Windows XP Access 2003
    Join Date
    Jul 2010
    Posts
    5

    attributes out of order

    hey there,
    I'm currently taking care of a little multiuser access database that tracks applications of students.

    The people using the database run queries on a regular basis - setting them up with help of the design view; and here is my issue:

    when the queries are setup, the user determines a specific order of the attributes, i.e.:


    ssn
    firstName
    lastName
    address
    ...
    however, when the query is executed, the attributes come up in the wrong order, like:
    address
    firstName
    lastName
    ssn
    ...
    checking the sql in the back, everything looks correct and the way it should be.

    Does anyone have an idea what I could do to bring the queries back to the correct order?

  2. #2
    jzwp11 is offline VIP
    Windows 7 Access 2007
    Join Date
    Jun 2010
    Location
    Dayton, OH
    Posts
    2,901
    Welcome to the forum!

    How are the users viewing the query results, through a form or the query results directly?

    Can you provide the SQL text of the query?

  3. #3
    Dornenhexe is offline Novice
    Windows XP Access 2003
    Join Date
    Jul 2010
    Posts
    5
    The users are viewing the results directly in table format.

    The code that the design view generates is:

    Code:
    SELECT summer.SSN, summer.Alumni, summer.FirstName, summer.LastName, summer.ProgramAttending, summer.Scholarship, summer.BalanceDue, summer.ReportCardFinal, summer.Health, summer.ReleaseForm
    FROM summer
    WHERE (((summer.ProgramAttending)="ichime") AND ((summer.EMBHSSC)=No))
    ORDER BY summer.LastName, summer.FirstName;
    the results however are displayed as:

    Code:
    SELECT summer.Alumni, summer.FirstName, summer.LastName, summer.SSN, summer.Scholarship, summer.BalanceDue, summer.ReportCardFinal, summer.Health, summer.ReleaseForm, summer.ProgramAttending 
    FROM ...
    this is just one example, there are several that work (or don't work) in a similar fashion.

  4. #4
    jzwp11 is offline VIP
    Windows 7 Access 2007
    Join Date
    Jun 2010
    Location
    Dayton, OH
    Posts
    2,901
    The order in which the fields are displayed is governed by the SELECT clause. If they are not being displayed in that order then the query is being altered which brings me to my next question. You say this is a multiuser database. Is the database split into front and backends? Can your users see your tables?

  5. #5
    Dornenhexe is offline Novice
    Windows XP Access 2003
    Join Date
    Jul 2010
    Posts
    5
    The database is split into front and backend, the users only make use of the forms and queries.

    I don't write the queries, the users do that on their own using the design view, since they don't know sql.
    However, when I test the queries, in the result the attributes are displayed in a different order than in the SELECT statement.

  6. #6
    jzwp11 is offline VIP
    Windows 7 Access 2007
    Join Date
    Jun 2010
    Location
    Dayton, OH
    Posts
    2,901
    Does each user have their own copy of the front end on their local hard drives?
    I sounds like your users have access to the database window (query design view) and thus the tables, this is not recommended in a multiuser environment.

  7. #7
    Dornenhexe is offline Novice
    Windows XP Access 2003
    Join Date
    Jul 2010
    Posts
    5
    Each User has their own copy of the frontend on their machine.
    But now you confused me, isn't it normal that the fronend users have access to the queries?
    Anyways, the only queries that are run are SELECT statements. Any kind of INSERT, UPDATE, DELETE is done by using forms.

  8. #8
    jzwp11 is offline VIP
    Windows 7 Access 2007
    Join Date
    Jun 2010
    Location
    Dayton, OH
    Posts
    2,901
    Normally, the user only interacts with the database through forms. I would normally provide a form with a button and the button invokes the query. There are ways to provide a query builder using a form, but I have not used one personally.

    Now regarding the query where the order of the fields returned is different than the SELECT statement, are you able to duplicate this behavior on the user's system? on your system? Is there any VBA code anywhere tied to the query?

  9. #9
    Dornenhexe is offline Novice
    Windows XP Access 2003
    Join Date
    Jul 2010
    Posts
    5
    The SELECT statements pull their information all directly out of the main table. There all very basic statements that don't involve any VBA code. There is some VBA used for the forms but those parts shouldn't intertwine with the info that is pulled in the queries.

    The same behavior exists on basically all systems, even a non split version of the database that I keep on my system.

    When I rearrange the attributes in the Datasheet View they will stay in order for a while but eventually revert back.

  10. #10
    jzwp11 is offline VIP
    Windows 7 Access 2007
    Join Date
    Jun 2010
    Location
    Dayton, OH
    Posts
    2,901
    I'm at a loss, the order in which the fields are displayed should stay as originally designed. Would it be possible to post a copy of your database with any sensitive data removed?

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

Similar Threads

  1. How to use Rnd to order records?
    By Gdm in forum Queries
    Replies: 1
    Last Post: 05-26-2010, 09:01 PM
  2. Order by
    By cowboy in forum Access
    Replies: 2
    Last Post: 05-03-2010, 05:04 PM
  3. Multiple "AutoNumber" attributes.
    By elektrisk in forum Access
    Replies: 3
    Last Post: 02-12-2010, 10:07 PM
  4. Hidden Attributes
    By NMJones in forum Access
    Replies: 1
    Last Post: 02-09-2010, 10:57 AM
  5. Macro to set rich text attributes?
    By EER in forum Programming
    Replies: 0
    Last Post: 03-04-2009, 09:25 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