| |

VerySource

 Forgot password?
 Register
Search
View: 2056|Reply: 5

Can the two libraries create views

[Copy link]

2

Threads

3

Posts

4.00

Credits

Newbie

Rank: 1

Credits
4.00

 China

Post time: 2021-3-13 22:30:01
| Show all posts |Read mode
I want to query some data from multiple tables in two databases, can I create a view? How to create it?
Reply

Use magic Report

0

Threads

6

Posts

7.00

Credits

Newbie

Rank: 1

Credits
7.00

 China

Post time: 2021-3-13 22:45:02
| Show all posts
sure
Select * From Library A.dbo. Table A, Library B.dbo. Table B...
Reply

Use magic Report

0

Threads

8

Posts

7.00

Credits

Newbie

Rank: 1

Credits
7.00

 China

Post time: 2021-3-13 23:00:01
| Show all posts
Theoretically possible
But there are not many cases like this, right?
Reply

Use magic Report

0

Threads

64

Posts

35.00

Credits

Newbie

Rank: 1

Credits
35.00

 China

Post time: 2021-3-13 23:15:02
| Show all posts
Yes, you can reference other databases by connecting to the server or using the RowSet function. You can even associate a SQL Server database with an Oracle database and use a SQL statement to query.

But this is not a database forum. Starting from the application, it emphasizes the ORM method programming search and avoids the use of non-portable SQL statements. Sometimes it is also a principle that should be appreciated.
Reply

Use magic Report

0

Threads

2

Posts

3.00

Credits

Newbie

Rank: 1

Credits
3.00

 China

Post time: 2021-3-13 23:30:01
| Show all posts
I heard that it can work across servers.
Reply

Use magic Report

0

Threads

64

Posts

35.00

Credits

Newbie

Rank: 1

Credits
35.00

 Lithuania

Post time: 2021-3-13 23:45:01
| Show all posts
Connect server --> Link server
Reply

Use magic Report

You have to log in before you can reply Login | Register

Points Rules

Contact us|Archive|Mobile|CopyRight © 2008-2023|verysource.com ( 京ICP备17048824号-1 )

Quick Reply To Top Return to the list