
            

            SELECT
                EvnDirection_id as "EvnDirection_id",
                NULL as "EvnDirection_TalonCode",
                error_code as "Error_Code",
                error_message as "Error_Msg"
            FROM dbo.p_EvnDirection_ins(
                EvnDirection_PreparationInfo := NULL,
                ConsultingForm_id := NULL,
                EvnDirection_id := NULL,
                EvnDirection_pid := '380101257143961',
                Server_id := 380101000000184,
                PersonEvn_id := '380101046123285',
                EvnDirection_setDT := '2023-07-25',
                DirType_id := '10',
                MedicalCareFormType_id := NULL,
                StudyTarget_id := '2',
                PayType_id := '380101000000021',
                Diag_id := '10896',
                EvnDirection_Num := '408623',
                EvnDirection_Descr := NULL,
                Lpu_did := '380101000000184', --куда направлен
                LpuSection_did := '380101000012308',
                LpuSectionProfile_id := '380101000000310',
                Lpu_id := '380101000000184', -- кто направил
                LpuSection_id := '380101000012318',
                LpuUnit_did := '380101000005635',
                MedPersonal_id := '380101000014973',
                MedStaffFact_id := '380101000095390',
                MedPersonal_zid := NULL,
                MedPersonal_Code := NULL,
                MedService_id := '380101000005089',
                EvnDirection_desDT := NULL,
                EvnDirection_IsAuto := NULL,
                EvnDirection_IsCito := '1',
                EvnStatus_id := NULL,
                Post_id := '380101000000958',
                Lpu_sid := '380101000000184',
                Org_sid := NULL,
                Org_oid := NULL,
                PrehospDirect_id := '1',
                TimetableGraf_id := NULL,
                TimetableStac_id := NULL,
                TimetableResource_id := '380101001968734',
                TimetableMedService_id := NULL,
                EvnDirection_IsNeedOper := 1,
                EvnQueue_id := NULL,
                ARMType_id := '1047',
                EvnDirection_IsReceive := NULL,
                Resource_id := '380101000001801',
                MedPersonal_did := NULL,
                RemoteConsultCause_id := NULL,
                MedSpec_fid := NULL,
                UslugaComplex_did := '202471',
                FSIDI_id := '7013634',
                LpuUnitType_id := NULL,
                EvnDirection_TalonCode := NULL,
                RecMethodType_id := '10',
                ConsultationForm_id := NULL,
                FluoroReason_id := NULL,
                EvnDirection_IsAgreement := NULL,
                RequestConsult_id := NULL,
                RecordType_id := 3,
                
                    EvnDirection_rid := '380101257143954',
                 LpuSectionBedProfile_id := NULL,  EvnDirection_IsBiopsy := NULL, 
                pmUser_id := '434267292665'
            )
        
