The forum will be down for maintenance at some point from Friday, August 24 at 19:00 EDT until Sunday, August 26 at 23:59 EDT. Downtime will be minimized but the exact timing is unknown.

Does a simple SELECT * FROM a non-relational (Excel, text file, etc) proxy table preserve the row/record/line ordering in the original file?

This is important to know, for a large class of source files that do not contain ANY data that is suitable for ORDER BY... the initial SELECT must preserve the row ordering... on the SQL Anywhere side an autoincrement column can THEN be used to continue the preservation:

INSERT copy_table ( all-columns-except-the-autoincrement ) SELECT * FROM proxy_table;

asked 31 Aug '10, 14:49

Breck%20Carter's gravatar image

Breck Carter
27.8k476633912
accept rate: 20%


There is no gear in the Remote Data Access layer to preserve row/record/line ordering since no such capability exists within ODBC. As a result you are at the mercy of the underlying ODBC driver (and possibly data source as well). There may be options within the DSN to do the "right" thing, but otherwise, I would say there is no guarantee.

permanent link

answered 31 Aug '10, 15:02

Karim%20Khamis's gravatar image

Karim Khamis
5.6k53870
accept rate: 40%

Your answer
toggle preview

Follow this question

By Email:

Once you sign in you will be able to subscribe for any updates here

By RSS:

Answers

Answers and Comments

Markdown Basics

  • *italic* or _italic_
  • **bold** or __bold__
  • link:[text](http://url.com/ "title")
  • image?![alt text](/path/img.jpg "title")
  • numbered list: 1. Foo 2. Bar
  • to add a line break simply add two spaces to where you would like the new line to be.
  • basic HTML tags are also supported

Question tags:

×63

question asked: 31 Aug '10, 14:49

question was seen: 693 times

last updated: 31 Aug '10, 15:02