有关DB2日志的DDL信息吗? [英] Any DDL Information on the DB2 Logs?

查看:71
本文介绍了有关DB2日志的DDL信息吗?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

有人知道DDL是否会更改,例如创建表,更改表,

删除表,删除表空间是否在DB2日志中?我正在编写一个

日志捕获程序,以便我可以通过

获取更改数据信息来复制源DB2上的更改,获取此信息,将其转换为SQL

命令,将其发送到另一个DB2实例并在那里运行,实际上

复制DDL更改。我已经能够使用DML执行此操作。

此外,我还在考虑将DDL和DML更改复制到其他

非DB2数据库。


JWK

Would anyone know if DDL changes such as creating a table, altering a table,
dropping the table, dropping a tablespace be in the DB2 logs? I am writing a
log capture program so that I can replicate changes on my source DB2 by
getting change data information , get this information, convert it to a SQL
command, send it to another DB2 instance and run it there, in effect
replicating the DDL change. I am already able to do this with DML.
Furthermore, I am also looking at replicating DDL and DML changes to other
non-DB2 databases.

JWK

推荐答案


有人知道DDL是否会改变这样的创建表,改变表,删除表,删除表空间是否在DB2日志中?我正在编写一个日志捕获程序,以便我可以通过获取更改数据信息来复制源DB2上的更改,获取此信息,将其转换为SQL命令,然后将其发送给另一个DB2实例并在那里运行,实际上
复制DDL更改。
Would anyone know if DDL changes such as creating a table,
altering a table, dropping the table, dropping a tablespace be
in the DB2 logs? I am writing a log capture program so that I
can replicate changes on my source DB2 by getting change data
information , get this information, convert it to a SQL command,
send it to another DB2 instance and run it there, in effect
replicating the DDL change.




听起来有点像为我重新发明轮子。


查看文档,高可用性灾难恢复

恢复。在24/7生产环境中对我来说很好(DB2
$ 32 $ 8在Win32上)。


问候,

Bernd



sounds a little bit like re-inventing the wheel to me.

Take a look at the documentation, "high availability desaster
recovery". Works fine for me in a 24/7 production environment (DB2
8.2 on Win32).

Regards,
Bernd


RdR写道:
是否有人知道DDL是否更改,如创建表,更改表,
丢弃表,丢弃表空间在DB2日志中?我正在编写一个
日志捕获程序,以便我可以通过获取更改数据信息,获取此信息,将其转换为SQL
命令,将其发送给另一个来复制源DB2上的更改。 DB2实例并在那里运行,实际上
复制DDL更改。我已经能够用DML做到这一点。
此外,我还在考虑将DDL和DML更改复制到其他非DB2数据库。

JWK
Would anyone know if DDL changes such as creating a table, altering a table,
dropping the table, dropping a tablespace be in the DB2 logs? I am writing a
log capture program so that I can replicate changes on my source DB2 by
getting change data information , get this information, convert it to a SQL
command, send it to another DB2 instance and run it there, in effect
replicating the DDL change. I am already able to do this with DML.
Furthermore, I am also looking at replicating DDL and DML changes to other
non-DB2 databases.

JWK



我能想到的所有DDL都会在某些

点的SYSIBM.SYS *表中结束。您需要做的是从目录中撤消工程师

更新DDL并应用它。 db2look做到这一点。

注意虽然看着SYSIBM.SYS *表有点危险

因为开发可能会在任何给定的全部重新洗牌。

发布 - 这就是为什么表没有记录。

但是再一次......只需看看SYSCAT.VIEWS将如何显示SYSCAT。* views

是衍生....没什么大秘密。


干杯

Serge


-

Serge Rielau

DB2 SQL编译器开发

IBM多伦多实验室


All DDL that I can think of ends up in the SYSIBM.SYS* tables at some
point. What you would have to do is reverse engineer out of the catalog
updates the DDL and apply it. db2look does this.
Note though that looking at SYSIBM.SYS* tables is a bit dangerous
because develeopment may reshuffle the deck on you on any given full
release - which is why the tables are not documented.
But again.. a simple look at SYSCAT.VIEWS will show how SYSCAT.* views
are derived.... not much of a secret.

Cheers
Serge

--
Serge Rielau
DB2 SQL Compiler Development
IBM Toronto Lab


您好Bernd,


我要做的是从日志中捕获DDL和DML更改并根据该信息确定
,打包它,将其发送到目标DB2和或许

稍后在其他数据库上复制DDL更改或DML更改。如果你在讨论Log Shipping,那么这不是我正在做的日志传送,

这更多是为了近乎实时地复制DDL和DML的变化。对于Oracle重做日志,我们已经完成了相同的操作但是只有Oracle作为源,但是我可以将DMl和DDL更改复制到DB2,Oracle,SQL Server, MySQL

目标。在异构体环境中,我可以在
Oracle中更改表结构,并将该更改复制到其他数据库,以及行更改。

我现在想要DB2成为来源,但我看到的日志信息非常可信。


我不认为我在这里重新发明轮子,因为没有这样的

产品,我在DB2上看到这样做,这就是我创建它的原因。

谢谢,


JWK


" Bernd Giegerich"

< bgi0815-for-news-use-only @ this-is-a-valid-mailaddress-but -please-do-not-spa

m-me.de>在消息新闻中写道:vl ************ @ news37.b-giegerich.de ...
Hi Bernd,

What I am trying to do is to catch DDL and DML changes from the logs and
based on that information, package it, send it to a target DB2 and maybe
later on other databases and replicate a DDL change or a DML change. If you
are talking about Log Shipping, this is not log shipping that I am doing,
this is more for replicating DDL and DML changes in near real time. We have
done the same for Oracle redo logs but that is only Oracle as the source but
I can replicate DMl and DDL changes to a DB2, Oracle, SQL Server, MySQL
targets. In a heterogenoues environment, I can change a table structure in
Oracle and replicate that change to other databases, as well as row changes.
I want now DB2 to be the source but the log information I see is very
cryptic.

I do not think I am re-inventing the wheel here because there is no such
product that I have seen for DB2 to do this, that is why I am creating it.

Thanks,

JWK

"Bernd Giegerich"
<bgi0815-for-news-use-only@this-is-a-valid-mailaddress-but-please-do-not-spa
m-me.de> wrote in message news:vl************@news37.b-giegerich.de...

有人知道DDL是否会发生更改,例如创建表,更改表,删除表,删除表空间是否在DB2日志中?我正在编写一个日志捕获程序,以便我可以通过获取更改数据信息来复制源DB2上的更改,获取此信息,将其转换为SQL命令,然后将其发送给另一个DB2实例并在那里运行,实际上
复制DDL更改。
Would anyone know if DDL changes such as creating a table,
altering a table, dropping the table, dropping a tablespace be
in the DB2 logs? I am writing a log capture program so that I
can replicate changes on my source DB2 by getting change data
information , get this information, convert it to a SQL command,
send it to another DB2 instance and run it there, in effect
replicating the DDL change.



听起来有点像为我重新发明轮子。
看一下文档,高可用性灾难恢复。在24/7生产环境中适用于我的工作(在Win32上的DB2
8.2)。

问候,
Bernd



sounds a little bit like re-inventing the wheel to me.

Take a look at the documentation, "high availability desaster
recovery". Works fine for me in a 24/7 production environment (DB2
8.2 on Win32).

Regards,
Bernd



这篇关于有关DB2日志的DDL信息吗?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆