Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
Can openquery can use in view ?
Message
 
 
À
12/03/2003 02:27:59
Stanley Yip
Shun Sang (technology) ltd Hong Kong
Hong Kong, Hong Kong
Information générale
Forum:
Microsoft SQL Server
Catégorie:
Autre
Divers
Thread ID:
00764642
Message ID:
00764733
Vues:
27
>I have try to use linking server to link the remote server to get access for the table .
>I use openquery command to get the data from the linked server . it is work fine.
>but I use the openquery to create view I find that it prompt error.
>
>so is it prossible to make a view with one local table with the remote sql server table ?
>is there any other solution to solve this problem ?

Yes, it's possible. I just tested it under SQL 2000. Here's my view definition.
CREATE VIEW view_test
AS 
	SELECT sq.pin 
		FROM 
			OPENQUERY(stxq, 'SELECT * FROM stxq') sq
		JOIN DC_pinmaster pm ON pm.pin = sq.pin
'stxq' is linked server to VFP free table and 'DC_pinmaster' is Sql Server table.
--sb--
Précédent
Suivant
Répondre
Fil
Voir

Click here to load this message in the networking platform