Re: Using OPENROWSET and fileds order...
From: Jacco Schalkwijk (jacco.please.reply_at_to.newsgroups.mvps.org.invalid)
Date: 09/15/04
- Next message: Gert E.R. Drapers: "Re: Hyperthreading"
- Previous message: MeanOldDBA: "RE: Database Design"
- In reply to: Dave: "Using OPENROWSET and fileds order..."
- Next in thread: Steve Kass: "Re: Using OPENROWSET and fileds order..."
- Messages sorted by: [ date ] [ thread ]
Date: Wed, 15 Sep 2004 10:51:09 +0100
In a relational database, there is logically no order in the columns in a
table, and you shouldn't rely on the order of the columns in your code. You
can just explicitly define the column list in your select statement, if you
need the columns to be returned in a particular order.
--
Jacco Schalkwijk
SQL Server MVP
"Dave" <Dave@discussions.microsoft.com> wrote in message
news:D7548AE4-DE65-4A77-825A-24BAB456B477@microsoft.com...
> Hello,
>
> I'm trying executing this command on the SQL query analyzer:
>
> SELECT * FROM OPENROWSET
> ('Microsoft.Jet.OLEDB.4.0','..path..';'Admin';'',MyTable)
>
> It returns the right set of rows from the mdb source, however the order of
> the fileds of MyTable has changed, and has been sorted alphabetically.
>
> I need the original field (columns) order, not changed.
>
> Is there something I'm missing?
>
> TIA.
> Dave
>
>
- Next message: Gert E.R. Drapers: "Re: Hyperthreading"
- Previous message: MeanOldDBA: "RE: Database Design"
- In reply to: Dave: "Using OPENROWSET and fileds order..."
- Next in thread: Steve Kass: "Re: Using OPENROWSET and fileds order..."
- Messages sorted by: [ date ] [ thread ]
Relevant Pages
|