Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 1
Default Querying Excel-Sheets with ADO using Inner Join

Hi!

I use ADO to query an Excel-Worksheet. I can do this
quite well for ONE sheet.

Now I need to query two sheets using an Inner Join in the
SQL statement.

I seem to miss something creating my query since i get an
error message stating that something is wrong with my
join expression...

Here is the statement:

SELECT VP FROM `Data1$` INNER JOIN `Data2$` ON `Data1
$VP`=`Data2$VP`

Any idea anyone? thx in advance,

Karla
  #2   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 593
Default Querying Excel-Sheets with ADO using Inner Join

"Karla" wrote ...

i get an
error message stating that something is wrong with my
join expression...

Here is the statement:

SELECT VP FROM `Data1$` INNER JOIN `Data2$` ON `Data1
$VP`=`Data2$VP`


Try:

SELECT T1.VP
FROM [Data1$] T1
INNER JOIN [Data2$] T2
ON T1.VP = T2.VP
;

Jamie.

--
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
Union or Join Sheets Jeff C Excel Discussion (Misc queries) 2 January 6th 09 06:16 PM
i want to join values of sheets together Islam rashed Excel Discussion (Misc queries) 1 September 12th 07 11:12 AM
How do I join two excel sheets? petr Excel Discussion (Misc queries) 1 March 31st 05 04:05 PM
To join some sheets of several files in one file 71paolo71 Excel Programming 1 April 30th 04 07:58 PM
join more workbooks in one and print sheets 71marco71[_4_] Excel Programming 3 February 6th 04 06:14 PM


All times are GMT +1. The time now is 11:47 PM.

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

About Us

"It's about Microsoft Excel"