Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 44
Default Recordset's RowID as part of Recordset

Can someone please provide some direction...

Using ADO against Acccess 2000

I need the Recordset's rowID to be part of the recordset itself so that
I may use it as an ORDER BY subquery in an INNER JOIN.

I would think it would be something like this...
SQLStmnt = "SELECT CustomerMarket.AccountNumber, RowID FROM
CustomerMarket WHERE MarketName = ""FV"" ORDER BY ""QuantityTraded"""

Where RowID is some sort of recordset property or dB engin query.

Any ideas????

Thanks!!!

Trip

  #2   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 1,163
Default Recordset's RowID as part of Recordset

What do you mean by RowID? If it is not part of your database in Access it is
not part of the recordset, and there is no recordset property like a RowID.
If you mean a sequential number in the order that the records are entered in
the table: if you do not specify any other order the recordset will come in
the order of database entry. You could potentially disconnect the recordset
from the source data (close the connection) and add a field, iterate through
the recordset and populate the new field with the record number, then use
this as your subquery recordset - but that is pretty cumbersome.

The best solution is to add a RowID that meets your specs within the Access
database, if that is possible. Or, if you don't have the ability to modify
the database, link the table into a new Access db and use a query to create a
RowID.
--
- K Dales


"Trip" wrote:

Can someone please provide some direction...

Using ADO against Acccess 2000

I need the Recordset's rowID to be part of the recordset itself so that
I may use it as an ORDER BY subquery in an INNER JOIN.

I would think it would be something like this...
SQLStmnt = "SELECT CustomerMarket.AccountNumber, RowID FROM
CustomerMarket WHERE MarketName = ""FV"" ORDER BY ""QuantityTraded"""

Where RowID is some sort of recordset property or dB engin query.

Any ideas????

Thanks!!!

Trip


  #3   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 11,272
Default Recordset's RowID as part of Recordset

AFAIK, Access data provider doesn't support RowID. I believe that Oracle
does, and Sybase has RowNum, but no luck with Access.

--

HTH

RP
(remove nothere from the email address if mailing direct)


"Trip" wrote in message
oups.com...
Can someone please provide some direction...

Using ADO against Acccess 2000

I need the Recordset's rowID to be part of the recordset itself so that
I may use it as an ORDER BY subquery in an INNER JOIN.

I would think it would be something like this...
SQLStmnt = "SELECT CustomerMarket.AccountNumber, RowID FROM
CustomerMarket WHERE MarketName = ""FV"" ORDER BY ""QuantityTraded"""

Where RowID is some sort of recordset property or dB engin query.

Any ideas????

Thanks!!!

Trip



  #4   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 44
Default Recordset's RowID as part of Recordset

Thanks Guys!

Bob, you've hit it. I finally created a temp table with an auto number
as an intermediate step and then used the auto number as a sort
sequence in an inner join. Even though it's a bit clugey it works
well.

Thanks again!

Trip

Reply
Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules

Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On


Similar Threads
Thread Thread Starter Forum Replies Last Post
spreadsheet part and part without grid lines jan Excel Discussion (Misc queries) 2 April 26th 10 11:27 PM
Search/Match/Find ANY part of string to ANY part of Cell Value TWhizTom Excel Worksheet Functions 0 July 21st 08 08:16 PM
Copying Part of a row down part of a column Not Excelling Excel Discussion (Misc queries) 3 January 6th 06 11:58 PM
How can I sperate the module into two part and connecte the two part and work well? ¬f©÷ Excel Programming 1 November 7th 04 03:05 AM
Type recordset/recordset? FlaviusFlav[_9_] Excel Programming 4 May 24th 04 12:16 PM


All times are GMT +1. The time now is 01:54 AM.

Powered by vBulletin® Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
Copyright ©2004-2025 ExcelBanter.
The comments are property of their posters.
 

About Us

"It's about Microsoft Excel"