1
0.50 ms
SELECT t0 . id AS id_1 , t0 . username AS username_2 , t0 . roles AS roles_3 , t0 . password AS password_4 , t0 . email AS email_5 , t0 . name AS name_6 , t0 . lastname AS lastname_7 , t0 . reset_password_key AS reset_password_key_8 , t9 . id AS id_10 , t9 . phone AS phone_11 , t9 . can_report_main_sucursal AS can_report_main_sucursal_12 , t9 . user_id AS user_id_13 , t9 . sri_info_id AS sri_info_id_14 , t9 . sucursal_id AS sucursal_id_15 , t0 . disabled_by_id AS disabled_by_id_16 FROM user t0 LEFT JOIN employee t9 ON t9 . user_id = t0 . id WHERE t0 . id = ?
SELECT t0 . id AS id_1 , t0 . username AS username_2 , t0 . roles AS roles_3 , t0 . password AS password_4 , t0 . email AS email_5 , t0 . name AS name_6 , t0 . lastname AS lastname_7 , t0 . reset_password_key AS reset_password_key_8 , t9 . id AS id_10 , t9 . phone AS phone_11 , t9 . can_report_main_sucursal AS can_report_main_sucursal_12 , t9 . user_id AS user_id_13 , t9 . sri_info_id AS sri_info_id_14 , t9 . sucursal_id AS sucursal_id_15 , t0 . disabled_by_id AS disabled_by_id_16 FROM user t0 LEFT JOIN employee t9 ON t9 . user_id = t0 . id WHERE t0 . id = 25 ;
Copy
2
0.48 ms
SELECT t0 . id AS id_1 , t0 . razon_social AS razon_social_2 , t0 . ruc AS ruc_3 , t0 . direction AS direction_4 , t0 . email AS email_5 , t0 . serie1 AS serie1_6 , t0 . serie2 AS serie2_7 , t0 . obligado_contabilidad AS obligado_contabilidad_8 , t0 . logo AS logo_9 , t0 . agente_retencion AS agente_retencion_10 , t0 . contribuyente_rimpe AS contribuyente_rimpe_11 , t0 . contribuyente_especial AS contribuyente_especial_12 , t0 . contribuyente_rimpe_text AS contribuyente_rimpe_text_13 , t0 . phone AS phone_14 , t0 . iess AS iess_15 , t0 . period103 AS period103_16 , t0 . user_id AS user_id_17 , t0 . certificate_id AS certificate_id_18 , t19 . id AS id_20 , t19 . company_created AS company_created_21 , t19 . sri_info_id AS sri_info_id_22 , t23 . id AS id_24 , t23 . host AS host_25 , t23 . email AS email_26 , t23 . password AS password_27 , t23 . name AS name_28 , t23 . port AS port_29 , t23 . auto_send AS auto_send_30 , t23 . sri_info_id AS sri_info_id_31 , t32 . id AS id_33 , t32 . show_transporter AS show_transporter_34 , t32 . sucursal_limit AS sucursal_limit_35 , t32 . should_print332_pdf AS should_print332_pdf_36 , t32 . company_id AS company_id_37 , t0 . disabled_by_id AS disabled_by_id_38 , t39 . id AS id_40 , t39 . email AS email_41 , t39 . sri_info_id AS sri_info_id_42 FROM sri_info t0 LEFT JOIN sri_edwin t19 ON t19 . sri_info_id = t0 . id LEFT JOIN email_configuration t23 ON t23 . sri_info_id = t0 . id LEFT JOIN saas_configuration t32 ON t32 . company_id = t0 . id LEFT JOIN email_extra_config t39 ON t39 . sri_info_id = t0 . id WHERE t0 . user_id = ?
SELECT t0 . id AS id_1 , t0 . razon_social AS razon_social_2 , t0 . ruc AS ruc_3 , t0 . direction AS direction_4 , t0 . email AS email_5 , t0 . serie1 AS serie1_6 , t0 . serie2 AS serie2_7 , t0 . obligado_contabilidad AS obligado_contabilidad_8 , t0 . logo AS logo_9 , t0 . agente_retencion AS agente_retencion_10 , t0 . contribuyente_rimpe AS contribuyente_rimpe_11 , t0 . contribuyente_especial AS contribuyente_especial_12 , t0 . contribuyente_rimpe_text AS contribuyente_rimpe_text_13 , t0 . phone AS phone_14 , t0 . iess AS iess_15 , t0 . period103 AS period103_16 , t0 . user_id AS user_id_17 , t0 . certificate_id AS certificate_id_18 , t19 . id AS id_20 , t19 . company_created AS company_created_21 , t19 . sri_info_id AS sri_info_id_22 , t23 . id AS id_24 , t23 . host AS host_25 , t23 . email AS email_26 , t23 . password AS password_27 , t23 . name AS name_28 , t23 . port AS port_29 , t23 . auto_send AS auto_send_30 , t23 . sri_info_id AS sri_info_id_31 , t32 . id AS id_33 , t32 . show_transporter AS show_transporter_34 , t32 . sucursal_limit AS sucursal_limit_35 , t32 . should_print332_pdf AS should_print332_pdf_36 , t32 . company_id AS company_id_37 , t0 . disabled_by_id AS disabled_by_id_38 , t39 . id AS id_40 , t39 . email AS email_41 , t39 . sri_info_id AS sri_info_id_42 FROM sri_info t0 LEFT JOIN sri_edwin t19 ON t19 . sri_info_id = t0 . id LEFT JOIN email_configuration t23 ON t23 . sri_info_id = t0 . id LEFT JOIN saas_configuration t32 ON t32 . company_id = t0 . id LEFT JOIN email_extra_config t39 ON t39 . sri_info_id = t0 . id WHERE t0 . user_id = 25 ;
Copy
3
0.35 ms
SELECT t0 . id AS id_1 , t0 . doc_type AS doc_type_2 , t0 . period AS period_3 , t0 . total AS total_4 , t0 . sealed AS sealed_5 , t0 . saas_configuration_id AS saas_configuration_id_6 FROM saas_doc_allowed t0 WHERE t0 . doc_type = ? AND t0 . saas_configuration_id = ? LIMIT 1
Parameters :
[
"retencion "
13
]
SELECT t0 . id AS id_1 , t0 . doc_type AS doc_type_2 , t0 . period AS period_3 , t0 . total AS total_4 , t0 . sealed AS sealed_5 , t0 . saas_configuration_id AS saas_configuration_id_6 FROM saas_doc_allowed t0 WHERE t0 . doc_type = 'retencion' AND t0 . saas_configuration_id = 13 LIMIT 1 ;
Copy
4
0.19 ms
SELECT t0 . id AS id_1 , t0 . name AS name_2 , t0 . amount AS amount_3 , t0 . valid_until AS valid_until_4 , t0 . is_default AS is_default_5 , t0 . sri_info_id AS sri_info_id_6 FROM tax t0 WHERE t0 . sri_info_id = ?
SELECT t0 . id AS id_1 , t0 . name AS name_2 , t0 . amount AS amount_3 , t0 . valid_until AS valid_until_4 , t0 . is_default AS is_default_5 , t0 . sri_info_id AS sri_info_id_6 FROM tax t0 WHERE t0 . sri_info_id = 15 ;
Copy
5
0.47 ms
SELECT r0_ . creation_date AS creation_date_0 , r0_ . date_update AS date_update_1 , r0_ . id AS id_2 , r0_ . name AS name_3 , r0_ . code AS code_4 , r0_ . percentage AS percentage_5 , r0_ . iva AS iva_6 , r0_ . valid_from AS valid_from_7 , r0_ . valid_to AS valid_to_8 , r0_ . percentage_iva AS percentage_iva_9 , r0_ . code_iva AS code_iva_10 , r0_ . code103 AS code103_11 FROM retention_code_list r0_ WHERE r0_ . id = ?
SELECT r0_ . creation_date AS creation_date_0 , r0_ . date_update AS date_update_1 , r0_ . id AS id_2 , r0_ . name AS name_3 , r0_ . code AS code_4 , r0_ . percentage AS percentage_5 , r0_ . iva AS iva_6 , r0_ . valid_from AS valid_from_7 , r0_ . valid_to AS valid_to_8 , r0_ . percentage_iva AS percentage_iva_9 , r0_ . code_iva AS code_iva_10 , r0_ . code103 AS code103_11 FROM retention_code_list r0_ WHERE r0_ . id = '147' ;
Copy
6
0.30 ms
SELECT p0_ . id AS id_0 , p0_ . date_created AS date_created_1 , p0_ . razon_social AS razon_social_2 , p0_ . identification AS identification_3 , p0_ . type_id AS type_id_4 , p0_ . location AS location_5 , p0_ . email AS email_6 , p0_ . phone AS phone_7 , p0_ . tipo_sujeto_retenido AS tipo_sujeto_retenido_8 , p0_ . parte_rel AS parte_rel_9 , p0_ . company_id AS company_id_10 , p0_ . doc_attribute_id AS doc_attribute_id_11 FROM provider p0_ WHERE p0_ . company_id = 15 AND p0_ . id = ?
SELECT p0_ . id AS id_0 , p0_ . date_created AS date_created_1 , p0_ . razon_social AS razon_social_2 , p0_ . identification AS identification_3 , p0_ . type_id AS type_id_4 , p0_ . location AS location_5 , p0_ . email AS email_6 , p0_ . phone AS phone_7 , p0_ . tipo_sujeto_retenido AS tipo_sujeto_retenido_8 , p0_ . parte_rel AS parte_rel_9 , p0_ . company_id AS company_id_10 , p0_ . doc_attribute_id AS doc_attribute_id_11 FROM provider p0_ WHERE p0_ . company_id = 15 AND p0_ . id = '9448' ;
Copy
7
0.94 ms
SELECT d0_ . id AS id_0 , d0_ . cod_sustento AS cod_sustento_1 , d0_ . cod_doc_sustento AS cod_doc_sustento_2 , d0_ . num_doc_sustento AS num_doc_sustento_3 , d0_ . fecha_emision_doc_sustento AS fecha_emision_doc_sustento_4 , d0_ . num_aut_doc_sustento AS num_aut_doc_sustento_5 , d0_ . total_sin_impuestos AS total_sin_impuestos_6 , d0_ . total AS total_7 , d0_ . pago_loc_ext AS pago_loc_ext_8 , d0_ . other_value AS other_value_9 , d0_ . fecha_caducidad AS fecha_caducidad_10 , d0_ . retencion_id AS retencion_id_11 , d0_ . pago_loc_id AS pago_loc_id_12 FROM doc_sustento d0_ INNER JOIN retencion r1_ ON d0_ . retencion_id = r1_ . id WHERE r1_ . provider_id = ? AND d0_ . num_doc_sustento = ? LIMIT 1
Parameters :
[
9448
"001-002-000000223 "
]
SELECT d0_ . id AS id_0 , d0_ . cod_sustento AS cod_sustento_1 , d0_ . cod_doc_sustento AS cod_doc_sustento_2 , d0_ . num_doc_sustento AS num_doc_sustento_3 , d0_ . fecha_emision_doc_sustento AS fecha_emision_doc_sustento_4 , d0_ . num_aut_doc_sustento AS num_aut_doc_sustento_5 , d0_ . total_sin_impuestos AS total_sin_impuestos_6 , d0_ . total AS total_7 , d0_ . pago_loc_ext AS pago_loc_ext_8 , d0_ . other_value AS other_value_9 , d0_ . fecha_caducidad AS fecha_caducidad_10 , d0_ . retencion_id AS retencion_id_11 , d0_ . pago_loc_id AS pago_loc_id_12 FROM doc_sustento d0_ INNER JOIN retencion r1_ ON d0_ . retencion_id = r1_ . id WHERE r1_ . provider_id = 9448 AND d0_ . num_doc_sustento = '001-002-000000223' LIMIT 1 ;
Copy
8
0.14 ms
"START TRANSACTION"
"START TRANSACTION" ;
Copy
9
0.42 ms
INSERT INTO retencion (creation_date , date_update , fecha_emision , tipo_identificacion_sujeto , razon_social_sujeto , identificacion_sujeto , periodo_fiscal , concept , tax_amount , retencion_iva , dates104 , doc_related_type , doc_related_date , doc_related_serie , doc_related_sequence , doc_related_auth , tipo_sujeto_retenido , parte_rel , sri_info_id , created_by_id , sucursal_id , provider_id , import_id ) VALUES (? , ? , ? , ? , ? , ? , ? , ? , ? , ? , ? , ? , ? , ? , ? , ? , ? , ? , ? , ? , ? , ? , ? )
Parameters :
[
"2025-12-31 13:51:52 "
"2025-12-31 13:51:52 "
"2025-12-31 "
"04 "
"LA CASA DEL OVEROL S.A.S. "
"0591764225001 "
"2025-12-31 "
"MATERIALES DE PUBLICIDAD (ARTICULOS PUBLICITARIOS, SERIGRAFIA, TAMPOGRAFIA, SOUVENIRS, ENTRE OTROS) Tomatodo personalizado con la marca del CASIGAP. Tomatodo Plástico sin BPA, capacidad de 550 ml. "
"15.00 "
0
null
null
null
null
null
null
null
null
15
25
null
9448
null
]
INSERT INTO retencion (
creation_date , date_update , fecha_emision ,
tipo_identificacion_sujeto , razon_social_sujeto ,
identificacion_sujeto , periodo_fiscal ,
concept , tax_amount , retencion_iva ,
dates104 , doc_related_type , doc_related_date ,
doc_related_serie , doc_related_sequence ,
doc_related_auth , tipo_sujeto_retenido ,
parte_rel , sri_info_id , created_by_id ,
sucursal_id , provider_id , import_id
)
VALUES
(
? , ? , ? , ? , ? , ? , ? , ? , ? , ? , ? , ? , ? , ? , ? , ? ,
? , ? , ? , ? , ? , ? , ?
)
Copy
INSERT INTO retencion (creation_date , date_update , fecha_emision , tipo_identificacion_sujeto , razon_social_sujeto , identificacion_sujeto , periodo_fiscal , concept , tax_amount , retencion_iva , dates104 , doc_related_type , doc_related_date , doc_related_serie , doc_related_sequence , doc_related_auth , tipo_sujeto_retenido , parte_rel , sri_info_id , created_by_id , sucursal_id , provider_id , import_id ) VALUES ('2025-12-31 13:51:52' , '2025-12-31 13:51:52' , '2025-12-31' , '04' , 'LA CASA DEL OVEROL S.A.S.' , '0591764225001' , '2025-12-31' , 'MATERIALES DE PUBLICIDAD (ARTICULOS PUBLICITARIOS, SERIGRAFIA, TAMPOGRAFIA, SOUVENIRS, ENTRE OTROS) Tomatodo personalizado con la marca del CASIGAP. Tomatodo Plástico sin BPA, capacidad de 550 ml.' , '15.00' , 0 , NULL , NULL , NULL , NULL , NULL , NULL , NULL , NULL , 15 , 25 , NULL , 9448 , NULL );
Copy
10
0.25 ms
INSERT INTO aditional_field (field , value , invoice_id , credit_note_id , remission_guide_id , debit_note_id , liquidacion_compra_id , retencion_id ) VALUES (? , ? , ? , ? , ? , ? , ? , ? )
Parameters :
[
"MATERIALES DE PUBLICIDAD (ARTICULOS PUBLICITARIOS, SERIGRAFIA, TAMPOGRAFIA, SOUVENIRS, ENTRE OTROS) Tomatodo personalizado con la marca del CASIGAP. Tomatodo Plástico sin BPA, capacidad de 550 ml. "
"MATERIALES DE PUBLICIDAD (ARTICULOS PUBLICITARIOS, SERIGRAFIA, TAMPOGRAFIA, SOUVENIRS, ENTRE OTROS) Tomatodo personalizado con la marca del CASIGAP. Tomatodo Plástico sin BPA, capacidad de 550 ml. "
null
null
null
null
null
20589
]
INSERT INTO aditional_field (field , value , invoice_id , credit_note_id , remission_guide_id , debit_note_id , liquidacion_compra_id , retencion_id ) VALUES ('MATERIALES DE PUBLICIDAD (ARTICULOS PUBLICITARIOS, SERIGRAFIA, TAMPOGRAFIA, SOUVENIRS, ENTRE OTROS) Tomatodo personalizado con la marca del CASIGAP. Tomatodo Plástico sin BPA, capacidad de 550 ml.' , 'MATERIALES DE PUBLICIDAD (ARTICULOS PUBLICITARIOS, SERIGRAFIA, TAMPOGRAFIA, SOUVENIRS, ENTRE OTROS) Tomatodo personalizado con la marca del CASIGAP. Tomatodo Plástico sin BPA, capacidad de 550 ml.' , NULL , NULL , NULL , NULL , NULL , 20589 );
Copy
11
0.20 ms
INSERT INTO doc_sustento (cod_sustento , cod_doc_sustento , num_doc_sustento , fecha_emision_doc_sustento , num_aut_doc_sustento , total_sin_impuestos , total , pago_loc_ext , other_value , fecha_caducidad , retencion_id , pago_loc_id ) VALUES (? , ? , ? , ? , ? , ? , ? , ? , ? , ? , ? , ? )
Parameters :
[
"02 "
"01 "
"001-002-000000223 "
"2025-12-31 00:00:00 "
"3112202501059176422500120010020000002232304201911 "
"795 "
"914.25 "
"01 "
"0 "
"2025-12-31 "
20589
null
]
INSERT INTO doc_sustento (cod_sustento , cod_doc_sustento , num_doc_sustento , fecha_emision_doc_sustento , num_aut_doc_sustento , total_sin_impuestos , total , pago_loc_ext , other_value , fecha_caducidad , retencion_id , pago_loc_id ) VALUES ('02' , '01' , '001-002-000000223' , '2025-12-31 00:00:00' , '3112202501059176422500120010020000002232304201911' , '795' , '914.25' , '01' , '0' , '2025-12-31' , 20589 , NULL );
Copy
12
0.20 ms
INSERT INTO invoice_taxes (code , percentage , base , fare , tax_amount , purpose , invoice_id , credit_note_id , debit_note_id , liquidacion_compra_id , doc_sustento_id ) VALUES (? , ? , ? , ? , ? , ? , ? , ? , ? , ? , ? )
Parameters :
[
2
0
null
"0 "
"0 "
"NOI "
null
null
null
null
20565
]
INSERT INTO invoice_taxes (code , percentage , base , fare , tax_amount , purpose , invoice_id , credit_note_id , debit_note_id , liquidacion_compra_id , doc_sustento_id ) VALUES (2 , 0 , NULL , '0' , '0' , 'NOI' , NULL , NULL , NULL , NULL , 20565 );
Copy
13
0.18 ms
INSERT INTO invoice_taxes (code , percentage , base , fare , tax_amount , purpose , invoice_id , credit_note_id , debit_note_id , liquidacion_compra_id , doc_sustento_id ) VALUES (? , ? , ? , ? , ? , ? , ? , ? , ? , ? , ? )
Parameters :
[
2
0
null
"0 "
"0 "
"BS0 "
null
null
null
null
20565
]
INSERT INTO invoice_taxes (code , percentage , base , fare , tax_amount , purpose , invoice_id , credit_note_id , debit_note_id , liquidacion_compra_id , doc_sustento_id ) VALUES (2 , 0 , NULL , '0' , '0' , 'BS0' , NULL , NULL , NULL , NULL , 20565 );
Copy
14
0.19 ms
INSERT INTO invoice_taxes (code , percentage , base , fare , tax_amount , purpose , invoice_id , credit_note_id , debit_note_id , liquidacion_compra_id , doc_sustento_id ) VALUES (? , ? , ? , ? , ? , ? , ? , ? , ? , ? , ? )
Parameters :
[
2
2
null
"15.00 "
"0 "
"IVA "
null
null
null
null
20565
]
INSERT INTO invoice_taxes (code , percentage , base , fare , tax_amount , purpose , invoice_id , credit_note_id , debit_note_id , liquidacion_compra_id , doc_sustento_id ) VALUES (2 , 2 , NULL , '15.00' , '0' , 'IVA' , NULL , NULL , NULL , NULL , 20565 );
Copy
15
0.33 ms
INSERT INTO doc_sustento_impuesto (codigo_retencion , base , percentage , value , base_no_obj , base0 , iva , percentage_iva , value_iva , base_total0 , tax_amount , is_manual_iva_calc , is_manual_values_calc , doc_sustento_id , retention_code_id ) VALUES (? , ? , ? , ? , ? , ? , ? , ? , ? , ? , ? , ? , ? , ? , ? )
Parameters :
[
"332 "
"795 "
"0 "
"0 "
"0 "
"0 "
"119.25 "
"100 "
"119.25 "
"795 "
15.0
0
0
20565
147
]
INSERT INTO doc_sustento_impuesto (codigo_retencion , base , percentage , value , base_no_obj , base0 , iva , percentage_iva , value_iva , base_total0 , tax_amount , is_manual_iva_calc , is_manual_values_calc , doc_sustento_id , retention_code_id ) VALUES ('332' , '795' , '0' , '0' , '0' , '0' , '119.25' , '100' , '119.25' , '795' , 15 , 0 , 0 , 20565 , 147 );
Copy
16
0.19 ms
INSERT INTO sri_payment (payment_form , total , term , term_time , debit_note_id , liquidacion_compra_id , doc_sustento_id , invoice_id ) VALUES (? , ? , ? , ? , ? , ? , ? , ? )
Parameters :
[
"20 "
"795 "
null
null
null
null
20565
null
]
INSERT INTO sri_payment (payment_form , total , term , term_time , debit_note_id , liquidacion_compra_id , doc_sustento_id , invoice_id ) VALUES ('20' , '795' , NULL , NULL , NULL , NULL , 20565 , NULL );
Copy
17
0.79 ms
"COMMIT"