博客
关于我
强烈建议你试试无所不能的chatGPT,快点击我
biztalk rosettanet 自定义 pip code
阅读量:6324 次
发布时间:2019-06-22

本文共 3623 字,大约阅读时间需要 12 分钟。

USE [BTARNDATA]GO/****** Object:  StoredProcedure [dbo].[proc_GetActivityStatus]    Script Date: 09/16/2015 16:16:02 ******/SET ANSI_NULLS ONGOSET QUOTED_IDENTIFIER ONGOALTER PROCEDURE [dbo].[proc_GetActivityStatus]( @PIPCode varchar(10), @PIPVersion varchar(20), @PIPInstanceID nvarchar(255), @SourcePartnerName nvarchar(255), @DestinationPartnerName nvarchar(255), @IsInitiatorActivity bit)ASIF (@DestinationPartnerName = 'SEAGATE-AMK' and @PIPCode = 'SG_3B2')BEGIN SET @PIPCode = '3B2'ENDIF (@DestinationPartnerName = 'SEAGATE-US' and @PIPCode = 'SG_3B2')BEGIN SET @PIPCode = '3B2'ENDIF (@DestinationPartnerName = 'SEAGATE-USML' and @PIPCode = 'SG_3B2')BEGIN SET @PIPCode = '3B2'ENDIF (@DestinationPartnerName = 'SEAGATE-AMK' and @PIPCode = 'SG_4B2')BEGIN SET @PIPCode = '4B2'ENDIF (@DestinationPartnerName = 'SEAGATE-US' and @PIPCode = 'SG_4B2')BEGIN SET @PIPCode = '4B2'ENDIF (@DestinationPartnerName = 'SEAGATE-USML' and @PIPCode = 'SG_4B2')BEGIN SET @PIPCode = '4B2'END DECLARE @sourcePartnerKey int  DECLARE @destinationPartnerKey int DECLARE @ActivityID nvarchar(255) SET @sourcePartnerKey = '-1' SET @destinationPartnerKey = '-1' SELECT @sourcePartnerKey = PartnerKey FROM PartnerLookup WHERE PartnerName=@SourcePartnerName SELECT @destinationPartnerKey = PartnerKey FROM PartnerLookup WHERE PartnerName=@DestinationPartnerName SELECT TOP 1 CurrentStatus  FROM ActivityTracking tblAT  WHERE tblAT.PIPCode = @PIPCode AND   tblAT.PIPVersion = @PIPVersion AND   tblAT.PIPInstanceID = @PIPInstanceID AND   tblAT.SourcePartnerKey = @sourcePartnerKey AND   tblAT.DestinationPartnerKey = @destinationPartnerKey AND   tblAT.IsInitiatorActivity = @IsInitiatorActivity

  

USE [BTARNCONFIG]GO/****** Object:  StoredProcedure [dbo].[GetTPAConfigData]    Script Date: 09/16/2015 16:47:17 ******/SET ANSI_NULLS OFFGOSET QUOTED_IDENTIFIER ONGOALTER PROCEDURE [dbo].[GetTPAConfigData]( @PIPCode char(20), @PIPVersion char(10), @HomePartnerName nvarchar(255), @TradingPartnerName nvarchar(255), @IsHomeRoleInitiator tinyint)AS  DECLARE @homePartnerKey int  DECLARE @tradingPartnerKey int SET @homePartnerKey = '-1' SET @tradingPartnerKey = '-1' SELECT @homePartnerKey = PartnerKey FROM PartnerLookup WHERE PartnerName=@HomePartnerName SELECT @tradingPartnerKey = PartnerKey FROM PartnerLookup WHERE PartnerName=@TradingPartnerName if (@homePartnerKey = -1 and @HomePartnerName <> '') BEGIN  INSERT INTO PartnerLookup(PartnerName) VALUES(@HomePartnerName)  SELECT @homePartnerKey = @@IDENTITY END if (@tradingPartnerKey = -1 and @TradingPartnerName <> '') BEGIN  INSERT INTO PartnerLookup(PartnerName) VALUES(@TradingPartnerName)  SELECT @tradingPartnerKey = @@IDENTITY ENDIF (@TradingPartnerName = 'SEAGATE-AMK' and @PIPCode = '3B2')BEGIN SET @PIPCode = 'SG_' + @PIPCodeENDIF (@TradingPartnerName = 'SEAGATE-US' and @PIPCode = '3B2')BEGIN SET @PIPCode = 'SG_' + @PIPCodeENDIF (@TradingPartnerName = 'SEAGATE-USML' and @PIPCode = '3B2')BEGIN SET @PIPCode = 'SG_' + @PIPCodeENDIF (@TradingPartnerName = 'SEAGATE-AMK' and @PIPCode = '4B2')BEGIN SET @PIPCode = 'SG_' + @PIPCodeENDIF (@TradingPartnerName = 'SEAGATE-US' and @PIPCode = '4B2')BEGIN SET @PIPCode = 'SG_' + @PIPCodeENDIF (@TradingPartnerName = 'SEAGATE-USML' and @PIPCode = '4B2')BEGIN SET @PIPCode = 'SG_' + @PIPCodeEND SELECT tc.*  FROM TPAConfig tc, PIPConfig pc WHERE @PIPCode = pc.Code   AND @PIPVersion = pc.Version   AND @homePartnerKey = tc.HomePartnerKey  AND @tradingPartnerKey = tc.TradingPartnerKey   AND pc.ID = tc.PIPID  AND @IsHomeRoleInitiator = tc.IsHomeRoleInitiator  AND Status = '1' ORDER BY tc.Name

  

 

转载于:https://www.cnblogs.com/neozhu/p/4813777.html

你可能感兴趣的文章
数学课本上的9大变态!
查看>>
《iOS编程指南》——第 1 章为何选择本地化应用
查看>>
《全栈性能测试修炼宝典 JMeter实战》—第1章 1.4节不仅仅是性能测试
查看>>
第十六章 Python正则表达式
查看>>
C++模板
查看>>
架构腐化之谜-阅读笔记
查看>>
谈谈AppDelegate
查看>>
揭秘OSS实战优化、UDF追求极致之路
查看>>
不和HR谈一次恋爱,你都不知道有多好
查看>>
码栈开发手册(五)---可视化方式开发(模块详解--流程)
查看>>
myrocks记录格式分析
查看>>
PostgreSQL、Greenplum DML合并操作 最佳实践
查看>>
阿里云人工智能科学家闵万里犀利点评:现在的人工智能有点过热
查看>>
Spark修炼之道(高级篇)——Spark源码阅读:第十节 Standalone运行模式解析
查看>>
移动应用要如何埋点上传才能收集更多数据?
查看>>
MIDle生命周期详解,以及工作原理
查看>>
Nginx + Shiro + Ehcache 实现负载均衡集群(成绩报告查询系统)
查看>>
Java CRC32的用法
查看>>
Google官方网络框架Volley实战——QQ吉凶测试,南无阿弥陀佛!
查看>>
【 MAKEFILE 编程基础之一】详细介绍MAKEFILE概念和其机制用途;
查看>>