DataStage---方法小结ing[转]

本文介绍了DataStage中的多种实用技巧,包括调用存储过程的方法、解决Job被其他用户访问导致的错误、链接收集器的配置调整等。适用于DataStage开发者及维护人员。

摘要生成于 C知道 ,由 DeepSeek-R1 满血版支持, 前往体验 >

datastage怎样调用存储过程

1。可以选择编写一个自定义Routine然后通过Transformer去实现

或者建立存储过程,然后在Database组件里的Before After里用数据库语句去调用就可以了

还有一个选择就是运行自定的shell脚本去调用,这种方法要用到job sequence中的运行命令的组件

2。datastage有专门调用存储过程的stage

-------------------------------------------------------------------------------------------------------------------------

实现是日期加1

DateToString(DateFromDaysSince(1,StringToDate(DSLink4.sjrq,"%yyyy%mm%dd")),"%yyyy%mm%dd")

---------------------------------------------------------------------------------------------------------------------------------

Transfomer function to Left Pad a string ?

Not sure if there is one available. I think it is available in the server job using the FMT function.

But what we did was use the STR, LEN and concatenation operator(:) to achieve the desired result.

STR("0",10-LEN(Input_Column)):Input_Column

---------------------------------------------------------------------------------------------------------------------------------

DataStage 如何解决"job is being accessed by another user"错误

由于网络连接失败或客户端崩溃造成Job被锁定的解决方法

当某一个用户在DataStage Designer中打开一个job,该job就被锁定。当其他用户试图打开同一个job或者job sequence,在designer中会得到如下信息"job [job名称] is being accessed by another user"。顺便提一下,这点Informatica比DS作的更友好一些,当试图打开某一个正在被其他用户编辑的mapping的时候,除了警告信息,Informatica还会告知当前编辑该Job的IP和User。

如果正在编辑某个job,发生网络连接中断(不小心碰掉了网线),或者客户端崩溃(我用XP SP2+DS751,每个星期总要发生个两三回,尤其是在编辑复杂的job sequence时)。重新启动客户端,试图打开刚才被编辑的Job很可能就被提示" job is being accessed by another user"。

首先确定在DataStage Administrator中对该project 设置了权限"Enable job Administration in Director",否则Director中部分菜单按钮不能访问

打开DataStage Director,找到被锁定的Job, 菜单Job->Clear Status File。会得到提示" This will remove all job status information from [job名称]. Are you sure you want to continue?",选择"Yes"

菜单Job->Clean up resources,此时会有Job Resources对话框出现。下边list中卫当前锁,在Item Id列找到被锁定的job,记下PID/User#列对应的PID

Telnet到DataStage服务器,执行如下命令
ps -ef | grep dsapi_slave
注意输出的前三列是用户名, ID1, ID2格式
在ID1列找到前面记下的PID,执行如下命令
kill -9 ID2

有空研究下windows下如何定位,加以更新

*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-

If u are trying to open a Job in the Datastage Designer and it says: "th

job is accessed by another user", it cud be due to two reasons:
1.) Chk if you already have that job open in a different wDesigner Window.
2) If not, then the job is locked.

You can realse the lock in various different ways.
1.) Go to ->Manager-> tools->Release job (u shud have administrator prev )
2.) Use DS.TOOLS command in the DataStage Administrator to chk and releas

---------------------------------------------------------------------------------------------------------------------------------

Error in Link collector - Stage does not support in-process active-to-active inputs or outputs


To get rid of the error just go to the Job Properties -> Performance and select Enable row buffer.
Then select Inter process which will let the link collector run correctly.
Buffer size set to 128Kb should be fine, however it's a good idea to increase the timeout.

---------------------------------------------------------------------------------------------------------------------------------

评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值