Results 1 to 7 of 7
  1. #1
    Lwang is offline Novice
    Windows 10 Access 2007
    Join Date
    Mar 2017
    Posts
    4

    Need to export a union query to a pipe delimited .txt file, with saved sorts

    I'm trying to export a union query in Access to a pipe delimited .txt file, with saved sorts, but the saved specification does not keep the sorts. Is there a way to save this export specification to include the sorts?

  2. #2
    aytee111 is offline Competent At Times
    Windows 10 Access 2013 64bit
    Join Date
    Nov 2011
    Location
    Nomad
    Posts
    3,936
    The sort order will be in the query.

  3. #3
    Lwang is offline Novice
    Windows 10 Access 2007
    Join Date
    Mar 2017
    Posts
    4
    The query is sorted the way I need, but when I export to the pipe delimited file txt file, there is no sort at all.

  4. #4
    aytee111 is offline Competent At Times
    Windows 10 Access 2013 64bit
    Join Date
    Nov 2011
    Location
    Nomad
    Posts
    3,936
    It works for me, I wonder what can be different? How are you exporting, is it TransferText in VBA, or a macro? Are you using a saved specification?

  5. #5
    Lwang is offline Novice
    Windows 10 Access 2007
    Join Date
    Mar 2017
    Posts
    4
    I am using the TransferText with the saved specification in a macro.

  6. #6
    aytee111 is offline Competent At Times
    Windows 10 Access 2013 64bit
    Join Date
    Nov 2011
    Location
    Nomad
    Posts
    3,936
    Still am unable to reproduce your issue! Could you post your database? Just with the bare necessities needed.

  7. #7
    Lwang is offline Novice
    Windows 10 Access 2007
    Join Date
    Mar 2017
    Posts
    4
    I was able to figure it out! I was highlighting the columns in each query of the union query and sorting them separately...which didn't keep the sort.. I added the ORDER BY code at the end of the SQL and then it worked to save the sorts in the saved export specification.

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

Similar Threads

  1. Replies: 1
    Last Post: 10-29-2015, 07:03 AM
  2. Replies: 7
    Last Post: 01-08-2014, 10:36 AM
  3. Replies: 1
    Last Post: 05-20-2013, 08:02 PM
  4. Export "Query or Report" to a "Delimited Text File"
    By hawzmolly in forum Import/Export Data
    Replies: 3
    Last Post: 08-31-2012, 08:00 AM
  5. Import PIPE Delimited Multiple Line
    By wcotis60 in forum Import/Export Data
    Replies: 1
    Last Post: 09-19-2011, 04:25 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