Join 2 Databases (both on the same server)

I need to Join 2 databases, I am using delphi and the zeos lib.

The reason: my client has an application wich manages their vacations and which is saved in the first database, now I shall write a programm wich uploads the vacations in an exchange server.

but to know wich vacation I already updated I made a second database to compare both.

One problem might be that the name of the database is the ip adreddess.

Queries like this work:
(It does not include the second database yet)

select ur_id as m_id
, dbo.urlaub.ur_status as m_status
, dbo.urlaub.ur_start as m_start
, dbo.urlaub.ur_end as m_end
, dbo.urlaub.ur_description as m_description
from dbo.urlaub
inner join dbo.users
on dbo.urlaub.ur_user_id = dbo.users.id;

Queries like this does not work:
(Includes the second database)
(It works in the database programm but not in my programnm)

select m_urlaub.ur_id as m_id
, m_urlaub.ur_status as m_status
, m_urlaub.ur_start as m_start
, m_urlaub.ur_end as m_end
, m_urlaub.ur_description as m_description
, ex_urlaub.ur_status as ex_status
from kalender.dbo.urlaub as m_urlaub
inner join kalender.dbo.users as m_users
on m_urlaub.ur_user_id = m_users.id
full outer join exchangerelation.dbo.urlaub as ex_urlaub
on ex_urlaub.ur_id = m_urlaub.ur_id;

(This is only an example what does work and whatnot, not my real querie, only one wich I used to test if everything works)

I get to work with SSMS as database for this project.

I alwasy get the “EZSQLException”: [15250]
The database name component of the object qualifier must be the name of the current database.

The database has already a lot of data saved, so it would not be nice if my programm need to sort every data.

(Both Database use the same server, port, username, password)
(the only differenze is their name:
db1: kalender
db2 exchangerelation)

Do I need to use TZGroupedConnection or TZConnectionGroup?
(I tried to change the databasename in the TZConnection to IP of database (which should also be teir name), kalender, exchangerelation, master (also everything with “/” and “”))

Sadly I didn’t found a good explanation about both TZ…, or how to Join multiple databases with zeos.

Sorry if I did’t post the right way or anything, this is my first question in the forum (until now I somehow found answers elswhere without the need to ask them myself).

New contributor

Ultimate Chaos is a new contributor to this site. Take care in asking for clarification, commenting, and answering.
Check out our Code of Conduct.

1

Trang chủ Giới thiệu Sinh nhật bé trai Sinh nhật bé gái Tổ chức sự kiện Biểu diễn giải trí Dịch vụ khác Trang trí tiệc cưới Tổ chức khai trương Tư vấn dịch vụ Thư viện ảnh Tin tức - sự kiện Liên hệ Chú hề sinh nhật Trang trí YEAR END PARTY công ty Trang trí tất niên cuối năm Trang trí tất niên xu hướng mới nhất Trang trí sinh nhật bé trai Hải Đăng Trang trí sinh nhật bé Khánh Vân Trang trí sinh nhật Bích Ngân Trang trí sinh nhật bé Thanh Trang Thuê ông già Noel phát quà Biểu diễn xiếc khỉ Xiếc quay đĩa Dịch vụ tổ chức sự kiện 5 sao Thông tin về chúng tôi Dịch vụ sinh nhật bé trai Dịch vụ sinh nhật bé gái Sự kiện trọn gói Các tiết mục giải trí Dịch vụ bổ trợ Tiệc cưới sang trọng Dịch vụ khai trương Tư vấn tổ chức sự kiện Hình ảnh sự kiện Cập nhật tin tức Liên hệ ngay Thuê chú hề chuyên nghiệp Tiệc tất niên cho công ty Trang trí tiệc cuối năm Tiệc tất niên độc đáo Sinh nhật bé Hải Đăng Sinh nhật đáng yêu bé Khánh Vân Sinh nhật sang trọng Bích Ngân Tiệc sinh nhật bé Thanh Trang Dịch vụ ông già Noel Xiếc thú vui nhộn Biểu diễn xiếc quay đĩa Dịch vụ tổ chức tiệc uy tín Khám phá dịch vụ của chúng tôi Tiệc sinh nhật cho bé trai Trang trí tiệc cho bé gái Gói sự kiện chuyên nghiệp Chương trình giải trí hấp dẫn Dịch vụ hỗ trợ sự kiện Trang trí tiệc cưới đẹp Khởi đầu thành công với khai trương Chuyên gia tư vấn sự kiện Xem ảnh các sự kiện đẹp Tin mới về sự kiện Kết nối với đội ngũ chuyên gia Chú hề vui nhộn cho tiệc sinh nhật Ý tưởng tiệc cuối năm Tất niên độc đáo Trang trí tiệc hiện đại Tổ chức sinh nhật cho Hải Đăng Sinh nhật độc quyền Khánh Vân Phong cách tiệc Bích Ngân Trang trí tiệc bé Thanh Trang Thuê dịch vụ ông già Noel chuyên nghiệp Xem xiếc khỉ đặc sắc Xiếc quay đĩa thú vị
Trang chủ Giới thiệu Sinh nhật bé trai Sinh nhật bé gái Tổ chức sự kiện Biểu diễn giải trí Dịch vụ khác Trang trí tiệc cưới Tổ chức khai trương Tư vấn dịch vụ Thư viện ảnh Tin tức - sự kiện Liên hệ Chú hề sinh nhật Trang trí YEAR END PARTY công ty Trang trí tất niên cuối năm Trang trí tất niên xu hướng mới nhất Trang trí sinh nhật bé trai Hải Đăng Trang trí sinh nhật bé Khánh Vân Trang trí sinh nhật Bích Ngân Trang trí sinh nhật bé Thanh Trang Thuê ông già Noel phát quà Biểu diễn xiếc khỉ Xiếc quay đĩa
Thiết kế website Thiết kế website Thiết kế website Cách kháng tài khoản quảng cáo Mua bán Fanpage Facebook Dịch vụ SEO Tổ chức sinh nhật