2018-06-06

select * from ChargeForCertainDocDetails where ExcutionNumber='HSMBAWELDB7Z'

select * from ChargeForCertainDocInfo where ExcutionNumber='HSMBAWELDB7Z'

select distinct(ExcutionNumber) from ChargeForCertainDocInfo

select count(*) from ChargeForCertainDocInfo

select * from InvoiceMaked;

select * from MorHKeepAccountsInfo

select * from InvoiceMaked where ExecutionNumber='HS8JSRDS8AEI' and ChargeType=0

select * from InvoiceMaked where ExecutionNumber='HSNSVL3MJHKL' and ChargeType=0

--delete from InvoiceMaked

select * from MorHKeepAccountsInfo where ID='HJTK917F2W29AZJFIYX5'

select * from MorHKeepAccountsDetails where MhID='HJUUXYPMCQPGJB73S50T'

select * from MorHKeepAccountsDetails where MhID='HJTO26YXUKPZW5ZD7GYJ'

select * from ChargeForCertainDocInfo where ExcutionNumber=’HSP096BIOGC2′

select * from ChargeForCertainDocDetails where ExcutionNumber=’HSP096BIOGC2′

select * from PayModeInfo;

select * from FinanceTotal where CustomerID=’8OUA40SX5T’

select * from IntegrationGenerateLog where CustomerID=’8OUA40SX5T’

select * from ReturnMoneyForCertainDoc;

exec sp_executesql N’SELECT TOP (1) [t0].[Amount], [t0].[ArrearsUnPayed], [t0].[BuyAmount], [t0].[BuyDate], [t0].[BuyPrice], [t0].[BuyQuantity], [t0].[BuyQuantity2], [t0].[BuySconto], [t0].[CertainProjectID], [t0].[CustomerID], [t0].[Date], [t0].[HandleBy], [t0].[ExcutionNumber], [t0].[ID], [t0].[IsInside], [t0].[ItemID], [t0].[ItemName], [t0].[ParticipateEmployees], [t0].[Price], [t0].[Quantity], [t0].[Quantity2], [t0].[Remark], [t0].[SaleBy], [t0].[Status]
FROM [dbo].[ReturnMoneyForCertainDoc] AS [t0]
WHERE [t0].[ID] = @p0′,N’@p0 bigint’,@p0=2769

SELECT [t0].[ID], [t0].[IsBaseMode], [t0].[PayModeName], [t0].[Remark], [t0].[SN], [t0].[SupportCertain], [t0].[SupportMorh], [t0].[Valid]
FROM [dbo].[PayModeInfo] AS [t0]
WHERE ([t0].[IsBaseMode] = 1) AND ([t0].[Valid] = 1)
ORDER BY [t0].[SN]

exec sp_executesql N’SELECT [t0].[Amount], [t0].[ArrearsUnPayed], [t0].[BuyAmount], [t0].[BuyDate], [t0].[BuyPrice], [t0].[BuyQuantity], [t0].[BuyQuantity2], [t0].[BuySconto], [t0].[CertainProjectID], [t0].[CustomerID], [t0].[Date], [t0].[HandleBy], [t0].[ExcutionNumber], [t0].[ID], [t0].[IsInside], [t0].[ItemID], [t0].[ItemName], [t0].[ParticipateEmployees], [t0].[Price], [t0].[Quantity], [t0].[Quantity2], [t0].[Remark], [t0].[SaleBy], [t0].[Status]
FROM [dbo].[ReturnMoneyForCertainDoc] AS [t0]
WHERE [t0].[ID] = @p0′,N’@p0 bigint’,@p0=2769

exec sp_executesql N’SELECT [t0].[Amount], [t0].[CardNumber], [t0].[ID], [t0].[IsDispute], [t0].[IsHandselMoney], [t0].[PayModeID], [t0].[Remark], [t0].[ReturnInfoID]
FROM [dbo].[ReturnMoneyForCertainDocDetails] AS [t0]
WHERE [t0].[ReturnInfoID] = @p0′,N’@p0 bigint’,@p0=2769

select * from AccountsOfCustomer where CustomerID=’1IN7C8NKNO’

update AccountsOfCustomer set IntegrationBalance=0 where CustomerID=’1IN7C8NKNO’

select * from ReturnMoneyForCertainDoc where ID=’2779′

select * from ReturnMoneyForCertainDocDetails where ReturnInfoID=’2779′

select * from AccountsOfCustomer where IntegrationBalance>10000 and CustomerID=’BBY9B25KEL’

select * from CustomerBaseInfo where ID=’BBY9B25KEL’

exec sp_executesql N’SELECT [t0].[CardNo], [t0].[Checked], [t0].[CustomerID], [t0].[Date], [t0].[HandleBy], [t0].[Manual], [t0].[MemberCardNum], [t0].[NewRankID], [t0].[Valid]
FROM [dbo].[MemberCardHandle] AS [t0]
WHERE ([t0].[Valid] = 1) AND ([t0].[CustomerID] = @p0)’,N’@p0 varchar(8000)’,@p0=’4TWBJ2ZG5O’

exec sp_executesql N’SELECT [t0].[Amount], [t0].[Balance], [t0].[CustomerID], [t0].[IntegrationBalance], [t0].[Invoice], [t0].[Version]
FROM [dbo].[AccountsOfCustomer] AS [t0]
WHERE [t0].[CustomerID] = @p0′,N’@p0 varchar(8000)’,@p0=’4TWBJ2ZG5O’

update AccountsOfCustomer set Balance=3000,IntegrationBalance=3200 where CustomerID=’4TWBJ2ZG5O’

select * from IntegrationDetails where CustomerID=’4TWBJ2ZG5O’

select * from IntegrationUseLog where CustomerID=’4TWBJ2ZG5O’

select * from IntegrationGenerateLog where Balance>0

select * from ChargeForCertainDocInfo order by Date desc

select * from ChargeForCertainDocDetails where ExcutionNumber='HSMBAWELDB7Z'

select * from ChargeForCertainDocInfo where ExcutionNumber='HSMBAWELDB7Z'

select * from FinanceTotal where DocInfoCode='HSMBAWELDB7Z'

select * from FinanceTotal where DocInfoCode='HJTO26YXUKPZW5ZD7GYJ'

select * from PayModeInfo;

select * from MorHKeepAccountsInfo where ID='HJTO26YXUKPZW5ZD7GYJ'

select * from MorHKeepAccountsDetails where MhID='HJTO26YXUKPZW5ZD7GYJ'

update MorHKeepAccountsDetails set ItemType=0 where MhID='HJTO26YXUKPZW5ZD7GYJ'

select * from IntegrationDetails where CustomerID='8K7ZJ2WOJV'

select * from IntegrationUseLog where CustomerID='8K7ZJ2WOJV'

select * from IntegrationGenerateLog where CustomerID='8K7ZJ2WOJV'

select * from CustomerBaseInfo where ID='8K7ZJ2WOJV'

select * from InvoiceMaked