spostamento XPS_data

This commit is contained in:
Samuele Locatelli
2017-01-31 14:34:55 +01:00
parent f5ae99144a
commit 5d99b976a3
71 changed files with 52936 additions and 56818 deletions
@@ -0,0 +1,72 @@
set xact_abort on
go
begin transaction
go
update LogStatoIstObj set CodStato = N'' where CodStato is null
go
alter table LogStatoIstObj alter column
CodStato nvarchar(50) not null
go
exec sp_rename 'PK_LogStatoIstObj', 'PK_LogStatoIstObj_1', 'object'
go
alter table LogStatoIstObj drop
constraint FK_LogStatoIstObj_IstObj
go
alter table LogStatoIstObj add
constraint FK_LogStatoIstObj_IstObj foreign key(IdxObj) references IstObj(IdxObj) on update cascade on delete cascade
go
commit
go
set xact_abort on
go
begin transaction
go
set ANSI_NULLS on
go
/***********************************
* STORED PROCEDURE sp_delRow
* elimina un set di dati a partire dalla riga di una commessa
*
* modif.: S.E.L.
* il: 2008.10.23
**************************************/
alter PROCEDURE sp_delRow
(
@Original_Cod VARCHAR(50)
)
AS
BEGIN TRAN
-- cancello ULP child
DELETE FROM IstObj
WHERE (IdxObjMamma = @Original_Cod)
-- cancello riga...
DELETE FROM IstObj
WHERE (IdxObj = @Original_Cod)
COMMIT TRAN
RETURN
go
commit
go
-- registro versione...
INSERT INTO [dbo].[LogUpdateDb] ([Versione],[Data]) VALUES(131, GETDATE())
GO