dbo.backend_alta_balances_contables_cuit_fecha

Description

Properties

Name Value
ANSI Nulls ON

True

Quoted Identifier ON

True

Encrypted

False

Execute As
Assembly

Parameters

6
Name Data Type Length Description
@p_cuit varchar 20
@p_fecha_balance date 3
@p_usuario int 4
@p_id_persona int 4
@p_visible bit 1
@p_estado varchar 50

SQL Script

Copy
SET QUOTED_IDENTIFIER, ANSI_NULLS ON
GO

create OR ALTER PROCEDURE dbo.backend_alta_balances_contables_cuit_fecha
  
   @p_cuit varchar(20),
 @p_fecha_balance date,
 @p_usuario int, 
 @p_id_persona int = null, 
 @p_visible bit = 0,
 @p_estado varchar(50) = 'GRABADO PARCIAL'

AS
BEGIN
    SET NOCOUNT ON;
 declare @p_id int = 0;

  insert into balances_contables(
         cuit,
         fecha_balance,
         created,
         created_by,
         visible,
         estado,
         id_padron)

        values ( 
         @p_cuit ,
         @p_fecha_balance ,
         GETDATE(), 
         @p_usuario ,
         @p_visible,
         @p_estado,
         @p_id_persona)

  set @p_id = (SELECT @@IDENTITY)
  select '0' as error, 'El registro se grabó satisfactoriamente' as mensaje, @p_id as id
 

END 

GO

Depends On

1

Used By

No items found