| 14:39:51.757 | 0.9 ms | SELECT | SELECT * FROM "global"."vw_user_login" WHERE "id"=1001 |
| 14:39:51.760 | 0.6 ms | SELECT | SELECT * FROM "a57be577deb434"."tbl_users" WHERE "id"=1001 |
| 14:39:51.764 | 0.7 ms | SELECT | SELECT * FROM "a57be577deb434"."tbl_purchase_contracts" WHERE "id"='4447' |
| 14:39:51.772 | 1.0 ms | SELECT | SELECT "id" FROM "a57be577deb434"."tbl_purchase_contracts" WHERE "serial_no"='DZ202603233147774' LIMIT 2 |
| 14:39:51.773 | 0.7 ms | SELECT | SELECT EXISTS(SELECT * FROM "a57be577deb434"."tbl_suppliers" WHERE "id"='46') |
| 14:39:51.774 | 0.3 ms | SELECT | SELECT EXISTS(SELECT * FROM "a57be577deb434"."tbl_users" WHERE "id"='1011') |
| 14:39:51.774 | 0.3 ms | SELECT | SELECT EXISTS(SELECT * FROM "a57be577deb434"."tbl_users" WHERE "id"=1011) |
| 14:39:51.775 | 4.0 ms | SELECT | SELECT
d.nspname AS table_schema,
c.relname AS table_name,
a.attname AS column_name,
t.typname AS data_type,
a.attlen AS character_maximum_length,
pg_catalog.col_description(c.oid, a.attnum) AS column_comment,
a.atttypmod AS modifier,
a.attnotnull = false AS is_nullable,
CAST(pg_get_expr(ad.adbin, ad.adrelid) AS varchar) AS column_default,
coalesce(pg_get_expr(ad.adbin, ad.adrelid) ~ 'nextval',false) AS is_autoinc,
array_to_string((select array_agg(enumlabel) from pg_enum where enumtypid=a.atttypid)::varchar[],',') as enum_values,
CASE atttypid
WHEN 21 /*int2*/ THEN 16
WHEN 23 /*int4*/ THEN 32
WHEN 20 /*int8*/ THEN 64
WHEN 1700 /*numeric*/ THEN
CASE WHEN atttypmod = -1
THEN null
ELSE ((atttypmod - 4) >> 16) & 65535
END
WHEN 700 /*float4*/ THEN 24 /*FLT_MANT_DIG*/
WHEN 701 /*float8*/ THEN 53 /*DBL_MANT_DIG*/
ELSE null
END AS numeric_precision,
CASE
WHEN atttypid IN (21, 23, 20) THEN 0
WHEN atttypid IN (1700) THEN
CASE
WHEN atttypmod = -1 THEN null
ELSE (atttypmod - 4) & 65535
END
ELSE null
END AS numeric_scale,
CAST(
information_schema._pg_char_max_length(information_schema._pg_truetypid(a, t), information_schema._pg_truetypmod(a, t))
AS numeric
) AS size,
a.attnum = any (ct.conkey) as is_pkey
FROM
pg_class c
LEFT JOIN pg_attribute a ON a.attrelid = c.oid
LEFT JOIN pg_attrdef ad ON a.attrelid = ad.adrelid AND a.attnum = ad.adnum
LEFT JOIN pg_type t ON a.atttypid = t.oid
LEFT JOIN pg_namespace d ON d.oid = c.relnamespace
LEFT join pg_constraint ct on ct.conrelid=c.oid and ct.contype='p'
WHERE
a.attnum > 0 and t.typname != ''
and c.relname = 'tbl_erp_inventory_products'
and d.nspname = 'a57be577deb434'
ORDER BY
a.attnum; |
| 14:39:51.779 | 11.3 ms | SELECT | select
ct.conname as constraint_name,
a.attname as column_name,
fc.relname as foreign_table_name,
fns.nspname as foreign_table_schema,
fa.attname as foreign_column_name
from
(SELECT ct.conname, ct.conrelid, ct.confrelid, ct.conkey, ct.contype, ct.confkey, generate_subscripts(ct.conkey, 1) AS s
FROM pg_constraint ct
) AS ct
inner join pg_class c on c.oid=ct.conrelid
inner join pg_namespace ns on c.relnamespace=ns.oid
inner join pg_attribute a on a.attrelid=ct.conrelid and a.attnum = ct.conkey[ct.s]
left join pg_class fc on fc.oid=ct.confrelid
left join pg_namespace fns on fc.relnamespace=fns.oid
left join pg_attribute fa on fa.attrelid=ct.confrelid and fa.attnum = ct.confkey[ct.s]
where
ct.contype='f'
and c.relname='tbl_erp_inventory_products'
and ns.nspname='a57be577deb434'
order by
fns.nspname, fc.relname, a.attnum |
| 14:39:51.791 | 0.8 ms | SELECT | SELECT * FROM "a57be577deb434"."tbl_erp_inventory_products" WHERE "id"=491 |
| 14:39:51.793 | 3.9 ms | SELECT | SELECT
d.nspname AS table_schema,
c.relname AS table_name,
a.attname AS column_name,
t.typname AS data_type,
a.attlen AS character_maximum_length,
pg_catalog.col_description(c.oid, a.attnum) AS column_comment,
a.atttypmod AS modifier,
a.attnotnull = false AS is_nullable,
CAST(pg_get_expr(ad.adbin, ad.adrelid) AS varchar) AS column_default,
coalesce(pg_get_expr(ad.adbin, ad.adrelid) ~ 'nextval',false) AS is_autoinc,
array_to_string((select array_agg(enumlabel) from pg_enum where enumtypid=a.atttypid)::varchar[],',') as enum_values,
CASE atttypid
WHEN 21 /*int2*/ THEN 16
WHEN 23 /*int4*/ THEN 32
WHEN 20 /*int8*/ THEN 64
WHEN 1700 /*numeric*/ THEN
CASE WHEN atttypmod = -1
THEN null
ELSE ((atttypmod - 4) >> 16) & 65535
END
WHEN 700 /*float4*/ THEN 24 /*FLT_MANT_DIG*/
WHEN 701 /*float8*/ THEN 53 /*DBL_MANT_DIG*/
ELSE null
END AS numeric_precision,
CASE
WHEN atttypid IN (21, 23, 20) THEN 0
WHEN atttypid IN (1700) THEN
CASE
WHEN atttypmod = -1 THEN null
ELSE (atttypmod - 4) & 65535
END
ELSE null
END AS numeric_scale,
CAST(
information_schema._pg_char_max_length(information_schema._pg_truetypid(a, t), information_schema._pg_truetypmod(a, t))
AS numeric
) AS size,
a.attnum = any (ct.conkey) as is_pkey
FROM
pg_class c
LEFT JOIN pg_attribute a ON a.attrelid = c.oid
LEFT JOIN pg_attrdef ad ON a.attrelid = ad.adrelid AND a.attnum = ad.adnum
LEFT JOIN pg_type t ON a.atttypid = t.oid
LEFT JOIN pg_namespace d ON d.oid = c.relnamespace
LEFT join pg_constraint ct on ct.conrelid=c.oid and ct.contype='p'
WHERE
a.attnum > 0 and t.typname != ''
and c.relname = 'tbl_erp_purchase_inbound_products'
and d.nspname = 'a57be577deb434'
ORDER BY
a.attnum; |
| 14:39:51.797 | 4.4 ms | SELECT | select
ct.conname as constraint_name,
a.attname as column_name,
fc.relname as foreign_table_name,
fns.nspname as foreign_table_schema,
fa.attname as foreign_column_name
from
(SELECT ct.conname, ct.conrelid, ct.confrelid, ct.conkey, ct.contype, ct.confkey, generate_subscripts(ct.conkey, 1) AS s
FROM pg_constraint ct
) AS ct
inner join pg_class c on c.oid=ct.conrelid
inner join pg_namespace ns on c.relnamespace=ns.oid
inner join pg_attribute a on a.attrelid=ct.conrelid and a.attnum = ct.conkey[ct.s]
left join pg_class fc on fc.oid=ct.confrelid
left join pg_namespace fns on fc.relnamespace=fns.oid
left join pg_attribute fa on fa.attrelid=ct.confrelid and fa.attnum = ct.confkey[ct.s]
where
ct.contype='f'
and c.relname='tbl_erp_purchase_inbound_products'
and ns.nspname='a57be577deb434'
order by
fns.nspname, fc.relname, a.attnum |
| 14:39:51.802 | 2.4 ms | SELECT | SELECT * FROM "a57be577deb434"."tbl_erp_purchase_inbound_products" WHERE "id"=428 |
| 14:39:51.806 | 3.4 ms | UPDATE | UPDATE "a57be577deb434"."tbl_purchase_contracts" SET "supplier_id"=46, "contract_type"=1, "handler"=1011, "updated_at"='now()' WHERE "id"=4447 |
| 14:39:51.812 | 2.8 ms | SELECT | SELECT
d.nspname AS table_schema,
c.relname AS table_name,
a.attname AS column_name,
t.typname AS data_type,
a.attlen AS character_maximum_length,
pg_catalog.col_description(c.oid, a.attnum) AS column_comment,
a.atttypmod AS modifier,
a.attnotnull = false AS is_nullable,
CAST(pg_get_expr(ad.adbin, ad.adrelid) AS varchar) AS column_default,
coalesce(pg_get_expr(ad.adbin, ad.adrelid) ~ 'nextval',false) AS is_autoinc,
array_to_string((select array_agg(enumlabel) from pg_enum where enumtypid=a.atttypid)::varchar[],',') as enum_values,
CASE atttypid
WHEN 21 /*int2*/ THEN 16
WHEN 23 /*int4*/ THEN 32
WHEN 20 /*int8*/ THEN 64
WHEN 1700 /*numeric*/ THEN
CASE WHEN atttypmod = -1
THEN null
ELSE ((atttypmod - 4) >> 16) & 65535
END
WHEN 700 /*float4*/ THEN 24 /*FLT_MANT_DIG*/
WHEN 701 /*float8*/ THEN 53 /*DBL_MANT_DIG*/
ELSE null
END AS numeric_precision,
CASE
WHEN atttypid IN (21, 23, 20) THEN 0
WHEN atttypid IN (1700) THEN
CASE
WHEN atttypmod = -1 THEN null
ELSE (atttypmod - 4) & 65535
END
ELSE null
END AS numeric_scale,
CAST(
information_schema._pg_char_max_length(information_schema._pg_truetypid(a, t), information_schema._pg_truetypmod(a, t))
AS numeric
) AS size,
a.attnum = any (ct.conkey) as is_pkey
FROM
pg_class c
LEFT JOIN pg_attribute a ON a.attrelid = c.oid
LEFT JOIN pg_attrdef ad ON a.attrelid = ad.adrelid AND a.attnum = ad.adnum
LEFT JOIN pg_type t ON a.atttypid = t.oid
LEFT JOIN pg_namespace d ON d.oid = c.relnamespace
LEFT join pg_constraint ct on ct.conrelid=c.oid and ct.contype='p'
WHERE
a.attnum > 0 and t.typname != ''
and c.relname = 'tbl_action_logs'
and d.nspname = 'a57be577deb434'
ORDER BY
a.attnum; |
| 14:39:51.815 | 3.6 ms | SELECT | select
ct.conname as constraint_name,
a.attname as column_name,
fc.relname as foreign_table_name,
fns.nspname as foreign_table_schema,
fa.attname as foreign_column_name
from
(SELECT ct.conname, ct.conrelid, ct.confrelid, ct.conkey, ct.contype, ct.confkey, generate_subscripts(ct.conkey, 1) AS s
FROM pg_constraint ct
) AS ct
inner join pg_class c on c.oid=ct.conrelid
inner join pg_namespace ns on c.relnamespace=ns.oid
inner join pg_attribute a on a.attrelid=ct.conrelid and a.attnum = ct.conkey[ct.s]
left join pg_class fc on fc.oid=ct.confrelid
left join pg_namespace fns on fc.relnamespace=fns.oid
left join pg_attribute fa on fa.attrelid=ct.confrelid and fa.attnum = ct.confkey[ct.s]
where
ct.contype='f'
and c.relname='tbl_action_logs'
and ns.nspname='a57be577deb434'
order by
fns.nspname, fc.relname, a.attnum |
| 14:39:51.820 | 18.7 ms | INSERT | INSERT INTO "a57be577deb434"."tbl_action_logs" ("action", "object_type", "object_id", "new_value", "old_value", "created_by", "ip_address") VALUES ('UPDATE', 'app\models\PurchaseContracts', 4447, 'a:0:{}', '', 1001, '221.216.117.25') |
| 14:39:51.839 | 0.5 ms | SELECT | SELECT * FROM "a57be577deb434"."tbl_suppliers" WHERE "id"='46' |
| 14:39:51.840 | 3.6 ms | SELECT | SELECT * FROM "a57be577deb434"."tbl_attachement_relationships" WHERE ("object_type"=108) AND ("object_id"=4447) |
| 14:39:51.844 | 2.7 ms | SELECT | SELECT
d.nspname AS table_schema,
c.relname AS table_name,
a.attname AS column_name,
t.typname AS data_type,
a.attlen AS character_maximum_length,
pg_catalog.col_description(c.oid, a.attnum) AS column_comment,
a.atttypmod AS modifier,
a.attnotnull = false AS is_nullable,
CAST(pg_get_expr(ad.adbin, ad.adrelid) AS varchar) AS column_default,
coalesce(pg_get_expr(ad.adbin, ad.adrelid) ~ 'nextval',false) AS is_autoinc,
array_to_string((select array_agg(enumlabel) from pg_enum where enumtypid=a.atttypid)::varchar[],',') as enum_values,
CASE atttypid
WHEN 21 /*int2*/ THEN 16
WHEN 23 /*int4*/ THEN 32
WHEN 20 /*int8*/ THEN 64
WHEN 1700 /*numeric*/ THEN
CASE WHEN atttypmod = -1
THEN null
ELSE ((atttypmod - 4) >> 16) & 65535
END
WHEN 700 /*float4*/ THEN 24 /*FLT_MANT_DIG*/
WHEN 701 /*float8*/ THEN 53 /*DBL_MANT_DIG*/
ELSE null
END AS numeric_precision,
CASE
WHEN atttypid IN (21, 23, 20) THEN 0
WHEN atttypid IN (1700) THEN
CASE
WHEN atttypmod = -1 THEN null
ELSE (atttypmod - 4) & 65535
END
ELSE null
END AS numeric_scale,
CAST(
information_schema._pg_char_max_length(information_schema._pg_truetypid(a, t), information_schema._pg_truetypmod(a, t))
AS numeric
) AS size,
a.attnum = any (ct.conkey) as is_pkey
FROM
pg_class c
LEFT JOIN pg_attribute a ON a.attrelid = c.oid
LEFT JOIN pg_attrdef ad ON a.attrelid = ad.adrelid AND a.attnum = ad.adnum
LEFT JOIN pg_type t ON a.atttypid = t.oid
LEFT JOIN pg_namespace d ON d.oid = c.relnamespace
LEFT join pg_constraint ct on ct.conrelid=c.oid and ct.contype='p'
WHERE
a.attnum > 0 and t.typname != ''
and c.relname = 'tbl_attachement_relationships'
and d.nspname = 'a57be577deb434'
ORDER BY
a.attnum; |
| 14:39:51.847 | 3.5 ms | SELECT | select
ct.conname as constraint_name,
a.attname as column_name,
fc.relname as foreign_table_name,
fns.nspname as foreign_table_schema,
fa.attname as foreign_column_name
from
(SELECT ct.conname, ct.conrelid, ct.confrelid, ct.conkey, ct.contype, ct.confkey, generate_subscripts(ct.conkey, 1) AS s
FROM pg_constraint ct
) AS ct
inner join pg_class c on c.oid=ct.conrelid
inner join pg_namespace ns on c.relnamespace=ns.oid
inner join pg_attribute a on a.attrelid=ct.conrelid and a.attnum = ct.conkey[ct.s]
left join pg_class fc on fc.oid=ct.confrelid
left join pg_namespace fns on fc.relnamespace=fns.oid
left join pg_attribute fa on fa.attrelid=ct.confrelid and fa.attnum = ct.confkey[ct.s]
where
ct.contype='f'
and c.relname='tbl_attachement_relationships'
and ns.nspname='a57be577deb434'
order by
fns.nspname, fc.relname, a.attnum |
| 14:39:51.851 | 5.5 ms | DELETE | DELETE FROM "a57be577deb434"."tbl_attachement_relationships" WHERE ("object_type"=108) AND ("object_id"=4447) |
| 14:39:51.856 | 13.0 ms | INSERT | INSERT INTO "a57be577deb434"."tbl_attachement_relationships" ("object_type", "object_id", "attachment_id") VALUES (108, 4447, 32534) |
| 14:39:51.879 | 3.5 ms | SELECT | SELECT
d.nspname AS table_schema,
c.relname AS table_name,
a.attname AS column_name,
t.typname AS data_type,
a.attlen AS character_maximum_length,
pg_catalog.col_description(c.oid, a.attnum) AS column_comment,
a.atttypmod AS modifier,
a.attnotnull = false AS is_nullable,
CAST(pg_get_expr(ad.adbin, ad.adrelid) AS varchar) AS column_default,
coalesce(pg_get_expr(ad.adbin, ad.adrelid) ~ 'nextval',false) AS is_autoinc,
array_to_string((select array_agg(enumlabel) from pg_enum where enumtypid=a.atttypid)::varchar[],',') as enum_values,
CASE atttypid
WHEN 21 /*int2*/ THEN 16
WHEN 23 /*int4*/ THEN 32
WHEN 20 /*int8*/ THEN 64
WHEN 1700 /*numeric*/ THEN
CASE WHEN atttypmod = -1
THEN null
ELSE ((atttypmod - 4) >> 16) & 65535
END
WHEN 700 /*float4*/ THEN 24 /*FLT_MANT_DIG*/
WHEN 701 /*float8*/ THEN 53 /*DBL_MANT_DIG*/
ELSE null
END AS numeric_precision,
CASE
WHEN atttypid IN (21, 23, 20) THEN 0
WHEN atttypid IN (1700) THEN
CASE
WHEN atttypmod = -1 THEN null
ELSE (atttypmod - 4) & 65535
END
ELSE null
END AS numeric_scale,
CAST(
information_schema._pg_char_max_length(information_schema._pg_truetypid(a, t), information_schema._pg_truetypmod(a, t))
AS numeric
) AS size,
a.attnum = any (ct.conkey) as is_pkey
FROM
pg_class c
LEFT JOIN pg_attribute a ON a.attrelid = c.oid
LEFT JOIN pg_attrdef ad ON a.attrelid = ad.adrelid AND a.attnum = ad.adnum
LEFT JOIN pg_type t ON a.atttypid = t.oid
LEFT JOIN pg_namespace d ON d.oid = c.relnamespace
LEFT join pg_constraint ct on ct.conrelid=c.oid and ct.contype='p'
WHERE
a.attnum > 0 and t.typname != ''
and c.relname = 'tbl_erp_purchase_returns'
and d.nspname = 'a57be577deb434'
ORDER BY
a.attnum; |
| 14:39:51.882 | 5.0 ms | SELECT | select
ct.conname as constraint_name,
a.attname as column_name,
fc.relname as foreign_table_name,
fns.nspname as foreign_table_schema,
fa.attname as foreign_column_name
from
(SELECT ct.conname, ct.conrelid, ct.confrelid, ct.conkey, ct.contype, ct.confkey, generate_subscripts(ct.conkey, 1) AS s
FROM pg_constraint ct
) AS ct
inner join pg_class c on c.oid=ct.conrelid
inner join pg_namespace ns on c.relnamespace=ns.oid
inner join pg_attribute a on a.attrelid=ct.conrelid and a.attnum = ct.conkey[ct.s]
left join pg_class fc on fc.oid=ct.confrelid
left join pg_namespace fns on fc.relnamespace=fns.oid
left join pg_attribute fa on fa.attrelid=ct.confrelid and fa.attnum = ct.confkey[ct.s]
where
ct.contype='f'
and c.relname='tbl_erp_purchase_returns'
and ns.nspname='a57be577deb434'
order by
fns.nspname, fc.relname, a.attnum |
| 14:39:51.888 | 6.2 ms | SELECT | SELECT * FROM "a57be577deb434"."tbl_erp_purchase_returns" WHERE ("created_at" >= '2026-06-26 00:00:00') AND ("created_at" <= '2026-06-26 23:59:59') AND ("serial_no" LIKE '%CGTH-20260626-%') AND (LENGTH(serial_no) = 19) ORDER BY "serial_no" DESC |
| 14:39:51.895 | 1.1 ms | UPDATE | UPDATE "a57be577deb434"."tbl_purchase_contracts" SET "is_chargeback_verify"=TRUE WHERE "id"=4447 |
| 14:39:51.896 | 1.2 ms | INSERT | INSERT INTO "a57be577deb434"."tbl_action_logs" ("action", "object_type", "object_id", "new_value", "old_value", "created_by", "ip_address") VALUES ('UPDATE', 'app\models\PurchaseContracts', 4447, 'a:0:{}', '', 1001, '221.216.117.25') |
| 14:39:51.897 | 0.3 ms | SELECT | SELECT * FROM "a57be577deb434"."tbl_suppliers" WHERE "id"='46' |
| 14:39:51.898 | 5.6 ms | INSERT | INSERT INTO "a57be577deb434"."tbl_erp_purchase_returns" ("supplier_id", "handler", "serial_no", "from_date", "description", "purchase_contract_id", "verify_type", "created_by", "wrote_date", "created_at", "status") VALUES (46, 1011, 'CGTH-20260626-00001', NULL, '', 4447, 2, 1001, '2026-06-26', 'now()', 1) RETURNING "id" |
| 14:39:51.904 | 1.3 ms | INSERT | INSERT INTO "a57be577deb434"."tbl_action_logs" ("action", "object_type", "object_id", "new_value", "old_value", "created_by", "ip_address") VALUES ('INSERT', 'app\models\ErpPurchaseReturns', 7, 'a:26:{s:2:"id";i:7;s:9:"serial_no";s:19:"CGTH-20260626-00001";s:9:"from_date";s:0:"";s:10:"wrote_date";s:10:"2026-06-26";s:7:"handler";s:4:"1011";s:11:"supplier_id";s:2:"46";s:20:"purchase_contract_id";i:4447;s:12:"erp_store_id";N;s:6:"status";i:1;s:8:"abstract";N;s:11:"description";s:0:"";s:11:"verify_type";s:1:"2";s:16:"next_verify_user";N;s:21:"next_stop_verify_user";N;s:9:"verify_at";N;s:7:"stop_at";N;s:18:"refuse_description";N;s:14:"is_resubmitted";N;s:6:"number";N;s:6:"amount";N;s:10:"created_by";i:1001;s:16:"stop_description";N;s:9:"is_settle";N;s:10:"created_at";s:19:"1970-01-01 08:00:00";s:10:"updated_at";N;s:11:"print_times";N;}', '', 1001, '221.216.117.25') |
| 14:39:51.906 | 1.6 ms | DELETE | DELETE FROM "a57be577deb434"."tbl_erp_purchase_return_verify_rels" WHERE "erp_purchase_return_id"=7 |
| 14:39:51.908 | 2.8 ms | SELECT | SELECT
d.nspname AS table_schema,
c.relname AS table_name,
a.attname AS column_name,
t.typname AS data_type,
a.attlen AS character_maximum_length,
pg_catalog.col_description(c.oid, a.attnum) AS column_comment,
a.atttypmod AS modifier,
a.attnotnull = false AS is_nullable,
CAST(pg_get_expr(ad.adbin, ad.adrelid) AS varchar) AS column_default,
coalesce(pg_get_expr(ad.adbin, ad.adrelid) ~ 'nextval',false) AS is_autoinc,
array_to_string((select array_agg(enumlabel) from pg_enum where enumtypid=a.atttypid)::varchar[],',') as enum_values,
CASE atttypid
WHEN 21 /*int2*/ THEN 16
WHEN 23 /*int4*/ THEN 32
WHEN 20 /*int8*/ THEN 64
WHEN 1700 /*numeric*/ THEN
CASE WHEN atttypmod = -1
THEN null
ELSE ((atttypmod - 4) >> 16) & 65535
END
WHEN 700 /*float4*/ THEN 24 /*FLT_MANT_DIG*/
WHEN 701 /*float8*/ THEN 53 /*DBL_MANT_DIG*/
ELSE null
END AS numeric_precision,
CASE
WHEN atttypid IN (21, 23, 20) THEN 0
WHEN atttypid IN (1700) THEN
CASE
WHEN atttypmod = -1 THEN null
ELSE (atttypmod - 4) & 65535
END
ELSE null
END AS numeric_scale,
CAST(
information_schema._pg_char_max_length(information_schema._pg_truetypid(a, t), information_schema._pg_truetypmod(a, t))
AS numeric
) AS size,
a.attnum = any (ct.conkey) as is_pkey
FROM
pg_class c
LEFT JOIN pg_attribute a ON a.attrelid = c.oid
LEFT JOIN pg_attrdef ad ON a.attrelid = ad.adrelid AND a.attnum = ad.adnum
LEFT JOIN pg_type t ON a.atttypid = t.oid
LEFT JOIN pg_namespace d ON d.oid = c.relnamespace
LEFT join pg_constraint ct on ct.conrelid=c.oid and ct.contype='p'
WHERE
a.attnum > 0 and t.typname != ''
and c.relname = 'tbl_erp_purchase_return_verify_rels'
and d.nspname = 'a57be577deb434'
ORDER BY
a.attnum; |
| 14:39:51.911 | 3.8 ms | SELECT | select
ct.conname as constraint_name,
a.attname as column_name,
fc.relname as foreign_table_name,
fns.nspname as foreign_table_schema,
fa.attname as foreign_column_name
from
(SELECT ct.conname, ct.conrelid, ct.confrelid, ct.conkey, ct.contype, ct.confkey, generate_subscripts(ct.conkey, 1) AS s
FROM pg_constraint ct
) AS ct
inner join pg_class c on c.oid=ct.conrelid
inner join pg_namespace ns on c.relnamespace=ns.oid
inner join pg_attribute a on a.attrelid=ct.conrelid and a.attnum = ct.conkey[ct.s]
left join pg_class fc on fc.oid=ct.confrelid
left join pg_namespace fns on fc.relnamespace=fns.oid
left join pg_attribute fa on fa.attrelid=ct.confrelid and fa.attnum = ct.confkey[ct.s]
where
ct.contype='f'
and c.relname='tbl_erp_purchase_return_verify_rels'
and ns.nspname='a57be577deb434'
order by
fns.nspname, fc.relname, a.attnum |
| 14:39:51.915 | 7.0 ms | INSERT | INSERT INTO "a57be577deb434"."tbl_erp_purchase_return_verify_rels" ("erp_purchase_return_id", "user_id", "status") VALUES (7, 1001, 0) |
| 14:39:51.924 | 3.0 ms | SELECT | SELECT
d.nspname AS table_schema,
c.relname AS table_name,
a.attname AS column_name,
t.typname AS data_type,
a.attlen AS character_maximum_length,
pg_catalog.col_description(c.oid, a.attnum) AS column_comment,
a.atttypmod AS modifier,
a.attnotnull = false AS is_nullable,
CAST(pg_get_expr(ad.adbin, ad.adrelid) AS varchar) AS column_default,
coalesce(pg_get_expr(ad.adbin, ad.adrelid) ~ 'nextval',false) AS is_autoinc,
array_to_string((select array_agg(enumlabel) from pg_enum where enumtypid=a.atttypid)::varchar[],',') as enum_values,
CASE atttypid
WHEN 21 /*int2*/ THEN 16
WHEN 23 /*int4*/ THEN 32
WHEN 20 /*int8*/ THEN 64
WHEN 1700 /*numeric*/ THEN
CASE WHEN atttypmod = -1
THEN null
ELSE ((atttypmod - 4) >> 16) & 65535
END
WHEN 700 /*float4*/ THEN 24 /*FLT_MANT_DIG*/
WHEN 701 /*float8*/ THEN 53 /*DBL_MANT_DIG*/
ELSE null
END AS numeric_precision,
CASE
WHEN atttypid IN (21, 23, 20) THEN 0
WHEN atttypid IN (1700) THEN
CASE
WHEN atttypmod = -1 THEN null
ELSE (atttypmod - 4) & 65535
END
ELSE null
END AS numeric_scale,
CAST(
information_schema._pg_char_max_length(information_schema._pg_truetypid(a, t), information_schema._pg_truetypmod(a, t))
AS numeric
) AS size,
a.attnum = any (ct.conkey) as is_pkey
FROM
pg_class c
LEFT JOIN pg_attribute a ON a.attrelid = c.oid
LEFT JOIN pg_attrdef ad ON a.attrelid = ad.adrelid AND a.attnum = ad.adnum
LEFT JOIN pg_type t ON a.atttypid = t.oid
LEFT JOIN pg_namespace d ON d.oid = c.relnamespace
LEFT join pg_constraint ct on ct.conrelid=c.oid and ct.contype='p'
WHERE
a.attnum > 0 and t.typname != ''
and c.relname = 'tbl_erp_purchase_return_products'
and d.nspname = 'a57be577deb434'
ORDER BY
a.attnum; |
| 14:39:51.927 | 4.6 ms | SELECT | select
ct.conname as constraint_name,
a.attname as column_name,
fc.relname as foreign_table_name,
fns.nspname as foreign_table_schema,
fa.attname as foreign_column_name
from
(SELECT ct.conname, ct.conrelid, ct.confrelid, ct.conkey, ct.contype, ct.confkey, generate_subscripts(ct.conkey, 1) AS s
FROM pg_constraint ct
) AS ct
inner join pg_class c on c.oid=ct.conrelid
inner join pg_namespace ns on c.relnamespace=ns.oid
inner join pg_attribute a on a.attrelid=ct.conrelid and a.attnum = ct.conkey[ct.s]
left join pg_class fc on fc.oid=ct.confrelid
left join pg_namespace fns on fc.relnamespace=fns.oid
left join pg_attribute fa on fa.attrelid=ct.confrelid and fa.attnum = ct.confkey[ct.s]
where
ct.contype='f'
and c.relname='tbl_erp_purchase_return_products'
and ns.nspname='a57be577deb434'
order by
fns.nspname, fc.relname, a.attnum |
| 14:39:51.933 | 8.1 ms | INSERT | INSERT INTO "a57be577deb434"."tbl_erp_purchase_return_products" ("erp_purchase_return_id", "erp_purchase_inbound_product_id", "erp_inventory_start_product_id", "product_id", "amount", "total_amount", "number", "description") VALUES (7, 428, NULL, 1584, '21681.66', '43363.32', '2', '') RETURNING "id" |
| 14:39:51.941 | 1.7 ms | INSERT | INSERT INTO "a57be577deb434"."tbl_action_logs" ("action", "object_type", "object_id", "new_value", "old_value", "created_by", "ip_address") VALUES ('INSERT', 'app\models\ErpPurchaseReturnProducts', 7, 'a:10:{s:2:"id";i:7;s:24:"erp_inventory_product_id";N;s:22:"erp_purchase_return_id";i:7;s:31:"erp_purchase_inbound_product_id";s:3:"428";s:10:"product_id";s:4:"1584";s:11:"description";s:0:"";s:6:"number";s:1:"2";s:6:"amount";s:8:"21681.66";s:12:"total_amount";s:8:"43363.32";s:30:"erp_inventory_start_product_id";s:0:"";}', '', 1001, '221.216.117.25') |
| 14:39:51.943 | 0.3 ms | SELECT | SELECT * FROM "a57be577deb434"."tbl_erp_purchase_return_verify_rels" WHERE ("status"=0) AND ("erp_purchase_return_id"=7) ORDER BY "id" |
| 14:39:51.944 | 1.5 ms | UPDATE | UPDATE "a57be577deb434"."tbl_erp_purchase_returns" SET "amount"='43363.32', "number"='2', "next_verify_user"=1001 WHERE "id"=7 |
| 14:39:51.945 | 1.3 ms | INSERT | INSERT INTO "a57be577deb434"."tbl_action_logs" ("action", "object_type", "object_id", "new_value", "old_value", "created_by", "ip_address") VALUES ('UPDATE', 'app\models\ErpPurchaseReturns', 7, 'a:1:{s:6:"amount";d:43363.32;}', '', 1001, '221.216.117.25') |
| 14:39:51.947 | 0.3 ms | SELECT | SELECT * FROM "a57be577deb434"."tbl_erp_purchase_returns" WHERE "id"=7 |
| 14:39:51.947 | 0.4 ms | SELECT | SELECT * FROM "a57be577deb434"."tbl_erp_purchase_return_products" WHERE "erp_purchase_return_id"=7 |
| 14:39:51.950 | 0.3 ms | SELECT | SELECT * FROM "a57be577deb434"."tbl_erp_purchase_inbound_products" WHERE "id"=428 |
| 14:39:51.951 | 0.7 ms | SELECT | SELECT * FROM "a57be577deb434"."tbl_erp_purchase_inbounds" WHERE "id"=211 |
| 14:39:51.952 | 0.4 ms | SELECT | SELECT * FROM "a57be577deb434"."tbl_erp_purchase_inbound_products" WHERE "erp_purchase_inbound_id"=211 |
| 14:39:51.953 | 0.3 ms | SELECT | SELECT * FROM "a57be577deb434"."tbl_erp_purchase_return_products" WHERE "erp_purchase_inbound_product_id"=427 |
| 14:39:51.953 | 1.3 ms | UPDATE | UPDATE "a57be577deb434"."tbl_erp_purchase_inbound_products" SET "cancel_number"='0', "cancel_amount"='0', "cancel_total_amount"='0' WHERE "id"=427 |
| 14:39:51.955 | 1.3 ms | INSERT | INSERT INTO "a57be577deb434"."tbl_action_logs" ("action", "object_type", "object_id", "new_value", "old_value", "created_by", "ip_address") VALUES ('UPDATE', 'app\models\ErpPurchaseInboundProducts', 427, 'a:0:{}', '', 1001, '221.216.117.25') |
| 14:39:51.956 | 0.3 ms | SELECT | SELECT * FROM "a57be577deb434"."tbl_erp_purchase_return_products" WHERE "erp_purchase_inbound_product_id"=428 |
| 14:39:51.957 | 0.3 ms | SELECT | SELECT * FROM "a57be577deb434"."tbl_erp_purchase_returns" WHERE "id"=7 |
| 14:39:51.958 | 3.5 ms | SELECT | SELECT * FROM "a57be577deb434"."tbl_erp_purchase_inbound_product_sns" WHERE "erp_purchase_inbound_product_id"=428 |
| 14:39:51.962 | 0.9 ms | UPDATE | UPDATE "a57be577deb434"."tbl_erp_purchase_inbound_products" SET "cancel_number"='2', "cancel_amount"='21681.66', "cancel_total_amount"='43363.32' WHERE "id"=428 |
| 14:39:51.963 | 1.3 ms | INSERT | INSERT INTO "a57be577deb434"."tbl_action_logs" ("action", "object_type", "object_id", "new_value", "old_value", "created_by", "ip_address") VALUES ('UPDATE', 'app\models\ErpPurchaseInboundProducts', 428, 'a:0:{}', '', 1001, '221.216.117.25') |
| 14:39:51.965 | 0.3 ms | SELECT | SELECT * FROM "a57be577deb434"."tbl_erp_purchase_return_products" WHERE "erp_purchase_inbound_product_id"=430 |
| 14:39:51.965 | 0.8 ms | UPDATE | UPDATE "a57be577deb434"."tbl_erp_purchase_inbound_products" SET "cancel_number"='0', "cancel_amount"='0', "cancel_total_amount"='0' WHERE "id"=430 |
| 14:39:51.966 | 0.7 ms | INSERT | INSERT INTO "a57be577deb434"."tbl_action_logs" ("action", "object_type", "object_id", "new_value", "old_value", "created_by", "ip_address") VALUES ('UPDATE', 'app\models\ErpPurchaseInboundProducts', 430, 'a:0:{}', '', 1001, '221.216.117.25') |
| 14:39:51.967 | 0.2 ms | SELECT | SELECT * FROM "a57be577deb434"."tbl_erp_purchase_return_products" WHERE "erp_purchase_inbound_product_id"=429 |
| 14:39:51.968 | 0.8 ms | UPDATE | UPDATE "a57be577deb434"."tbl_erp_purchase_inbound_products" SET "cancel_number"='0', "cancel_amount"='0', "cancel_total_amount"='0' WHERE "id"=429 |
| 14:39:51.969 | 1.0 ms | INSERT | INSERT INTO "a57be577deb434"."tbl_action_logs" ("action", "object_type", "object_id", "new_value", "old_value", "created_by", "ip_address") VALUES ('UPDATE', 'app\models\ErpPurchaseInboundProducts', 429, 'a:0:{}', '', 1001, '221.216.117.25') |
| 14:39:51.970 | 0.4 ms | SELECT | SELECT * FROM "a57be577deb434"."tbl_erp_purchase_inbound_products" WHERE "erp_purchase_inbound_id"=211 |
| 14:39:51.971 | 0.4 ms | SELECT | SELECT * FROM "a57be577deb434"."tbl_erp_inventory_products" WHERE "erp_purchase_inbound_product_id"=427 |
| 14:39:51.971 | 0.9 ms | UPDATE | UPDATE "a57be577deb434"."tbl_erp_inventory_products" SET "number"='2', "inventory"='2', "total_amount"='19081.7' WHERE "id"=490 |
| 14:39:51.972 | 0.8 ms | INSERT | INSERT INTO "a57be577deb434"."tbl_action_logs" ("action", "object_type", "object_id", "new_value", "old_value", "created_by", "ip_address") VALUES ('UPDATE', 'app\models\ErpInventoryProducts', 490, 'a:0:{}', '', 1001, '221.216.117.25') |
| 14:39:51.973 | 0.2 ms | SELECT | SELECT * FROM "a57be577deb434"."tbl_erp_purchase_inbound_product_sns" WHERE "erp_purchase_inbound_product_id"=427 |
| 14:39:51.975 | 3.7 ms | DELETE | DELETE FROM "a57be577deb434"."tbl_erp_inventory_product_sns" WHERE ("erp_inventory_product_id"=490) |
| 14:39:51.979 | 0.4 ms | SELECT | SELECT * FROM "a57be577deb434"."tbl_erp_inventory_product_sns" WHERE "erp_inventory_product_id"=490 |
| 14:39:51.981 | 2.9 ms | SELECT | SELECT SUM(outbound) FROM "a57be577deb434"."tbl_erp_inventory_product_spents" WHERE "erp_inventory_product_id"=490 |
| 14:39:51.984 | 1.9 ms | UPDATE | UPDATE "a57be577deb434"."tbl_erp_inventory_products" SET "outbound"='0' WHERE "id"=490 |
| 14:39:51.987 | 0.8 ms | INSERT | INSERT INTO "a57be577deb434"."tbl_action_logs" ("action", "object_type", "object_id", "new_value", "old_value", "created_by", "ip_address") VALUES ('UPDATE', 'app\models\ErpInventoryProducts', 490, 'a:0:{}', '', 1001, '221.216.117.25') |
| 14:39:51.989 | 4.6 ms | SELECT | SELECT * FROM "a57be577deb434"."tbl_settings" WHERE "setting_key"='erp_cost_type' |
| 14:39:51.995 | 3.4 ms | SELECT | SELECT
d.nspname AS table_schema,
c.relname AS table_name,
a.attname AS column_name,
t.typname AS data_type,
a.attlen AS character_maximum_length,
pg_catalog.col_description(c.oid, a.attnum) AS column_comment,
a.atttypmod AS modifier,
a.attnotnull = false AS is_nullable,
CAST(pg_get_expr(ad.adbin, ad.adrelid) AS varchar) AS column_default,
coalesce(pg_get_expr(ad.adbin, ad.adrelid) ~ 'nextval',false) AS is_autoinc,
array_to_string((select array_agg(enumlabel) from pg_enum where enumtypid=a.atttypid)::varchar[],',') as enum_values,
CASE atttypid
WHEN 21 /*int2*/ THEN 16
WHEN 23 /*int4*/ THEN 32
WHEN 20 /*int8*/ THEN 64
WHEN 1700 /*numeric*/ THEN
CASE WHEN atttypmod = -1
THEN null
ELSE ((atttypmod - 4) >> 16) & 65535
END
WHEN 700 /*float4*/ THEN 24 /*FLT_MANT_DIG*/
WHEN 701 /*float8*/ THEN 53 /*DBL_MANT_DIG*/
ELSE null
END AS numeric_precision,
CASE
WHEN atttypid IN (21, 23, 20) THEN 0
WHEN atttypid IN (1700) THEN
CASE
WHEN atttypmod = -1 THEN null
ELSE (atttypmod - 4) & 65535
END
ELSE null
END AS numeric_scale,
CAST(
information_schema._pg_char_max_length(information_schema._pg_truetypid(a, t), information_schema._pg_truetypmod(a, t))
AS numeric
) AS size,
a.attnum = any (ct.conkey) as is_pkey
FROM
pg_class c
LEFT JOIN pg_attribute a ON a.attrelid = c.oid
LEFT JOIN pg_attrdef ad ON a.attrelid = ad.adrelid AND a.attnum = ad.adnum
LEFT JOIN pg_type t ON a.atttypid = t.oid
LEFT JOIN pg_namespace d ON d.oid = c.relnamespace
LEFT join pg_constraint ct on ct.conrelid=c.oid and ct.contype='p'
WHERE
a.attnum > 0 and t.typname != ''
and c.relname = 'tbl_settings'
and d.nspname = 'a57be577deb434'
ORDER BY
a.attnum; |
| 14:39:51.998 | 4.2 ms | SELECT | select
ct.conname as constraint_name,
a.attname as column_name,
fc.relname as foreign_table_name,
fns.nspname as foreign_table_schema,
fa.attname as foreign_column_name
from
(SELECT ct.conname, ct.conrelid, ct.confrelid, ct.conkey, ct.contype, ct.confkey, generate_subscripts(ct.conkey, 1) AS s
FROM pg_constraint ct
) AS ct
inner join pg_class c on c.oid=ct.conrelid
inner join pg_namespace ns on c.relnamespace=ns.oid
inner join pg_attribute a on a.attrelid=ct.conrelid and a.attnum = ct.conkey[ct.s]
left join pg_class fc on fc.oid=ct.confrelid
left join pg_namespace fns on fc.relnamespace=fns.oid
left join pg_attribute fa on fa.attrelid=ct.confrelid and fa.attnum = ct.confkey[ct.s]
where
ct.contype='f'
and c.relname='tbl_settings'
and ns.nspname='a57be577deb434'
order by
fns.nspname, fc.relname, a.attnum |
| 14:39:52.003 | 0.3 ms | SELECT | SELECT * FROM "a57be577deb434"."tbl_settings" WHERE "setting_key"='erp_decimal_point' |
| 14:39:52.004 | 1.0 ms | UPDATE | UPDATE "a57be577deb434"."tbl_erp_inventory_products" SET "actual_total_amount"='19081.7' WHERE "id"=490 |
| 14:39:52.005 | 1.0 ms | INSERT | INSERT INTO "a57be577deb434"."tbl_action_logs" ("action", "object_type", "object_id", "new_value", "old_value", "created_by", "ip_address") VALUES ('UPDATE', 'app\models\ErpInventoryProducts', 490, 'a:0:{}', '', 1001, '221.216.117.25') |
| 14:39:52.006 | 0.9 ms | UPDATE | UPDATE "a57be577deb434"."tbl_erp_purchase_inbound_products" SET "outbound"='0', "inventory"='2' WHERE "id"=427 |
| 14:39:52.007 | 0.9 ms | INSERT | INSERT INTO "a57be577deb434"."tbl_action_logs" ("action", "object_type", "object_id", "new_value", "old_value", "created_by", "ip_address") VALUES ('UPDATE', 'app\models\ErpPurchaseInboundProducts', 427, 'a:0:{}', '', 1001, '221.216.117.25') |
| 14:39:52.009 | 0.4 ms | SELECT | SELECT * FROM "a57be577deb434"."tbl_erp_inventory_products" WHERE "erp_purchase_inbound_product_id"=428 |
| 14:39:52.009 | 1.4 ms | UPDATE | UPDATE "a57be577deb434"."tbl_erp_inventory_products" SET "number"='0', "inventory"='0', "total_amount"='0' WHERE "id"=491 |
| 14:39:52.011 | 0.9 ms | INSERT | INSERT INTO "a57be577deb434"."tbl_action_logs" ("action", "object_type", "object_id", "new_value", "old_value", "created_by", "ip_address") VALUES ('UPDATE', 'app\models\ErpInventoryProducts', 491, 'a:2:{s:6:"number";s:1:"2";s:9:"inventory";s:1:"2";}', '', 1001, '221.216.117.25') |
| 14:39:52.012 | 0.3 ms | SELECT | SELECT * FROM "a57be577deb434"."tbl_erp_purchase_inbound_product_sns" WHERE "erp_purchase_inbound_product_id"=428 |
| 14:39:52.012 | 0.3 ms | DELETE | DELETE FROM "a57be577deb434"."tbl_erp_inventory_product_sns" WHERE ("erp_inventory_product_id"=491) |
| 14:39:52.013 | 0.3 ms | SELECT | SELECT * FROM "a57be577deb434"."tbl_erp_inventory_product_sns" WHERE "erp_inventory_product_id"=491 |
| 14:39:52.014 | 0.4 ms | SELECT | SELECT SUM(outbound) FROM "a57be577deb434"."tbl_erp_inventory_product_spents" WHERE "erp_inventory_product_id"=491 |
| 14:39:52.014 | 0.9 ms | UPDATE | UPDATE "a57be577deb434"."tbl_erp_inventory_products" SET "outbound"='0' WHERE "id"=491 |
| 14:39:52.015 | 0.9 ms | INSERT | INSERT INTO "a57be577deb434"."tbl_action_logs" ("action", "object_type", "object_id", "new_value", "old_value", "created_by", "ip_address") VALUES ('UPDATE', 'app\models\ErpInventoryProducts', 491, 'a:0:{}', '', 1001, '221.216.117.25') |
| 14:39:52.016 | 0.3 ms | SELECT | SELECT * FROM "a57be577deb434"."tbl_settings" WHERE "setting_key"='erp_cost_type' |
| 14:39:52.017 | 0.3 ms | SELECT | SELECT * FROM "a57be577deb434"."tbl_settings" WHERE "setting_key"='erp_decimal_point' |
| 14:39:52.017 | 1.1 ms | UPDATE | UPDATE "a57be577deb434"."tbl_erp_inventory_products" SET "actual_total_amount"='0' WHERE "id"=491 |
| 14:39:52.019 | 0.8 ms | INSERT | INSERT INTO "a57be577deb434"."tbl_action_logs" ("action", "object_type", "object_id", "new_value", "old_value", "created_by", "ip_address") VALUES ('UPDATE', 'app\models\ErpInventoryProducts', 491, 'a:1:{s:19:"actual_total_amount";s:8:"43363.32";}', '', 1001, '221.216.117.25') |
| 14:39:52.020 | 0.8 ms | UPDATE | UPDATE "a57be577deb434"."tbl_erp_purchase_inbound_products" SET "outbound"='0', "inventory"='0' WHERE "id"=428 |
| 14:39:52.021 | 1.1 ms | INSERT | INSERT INTO "a57be577deb434"."tbl_action_logs" ("action", "object_type", "object_id", "new_value", "old_value", "created_by", "ip_address") VALUES ('UPDATE', 'app\models\ErpPurchaseInboundProducts', 428, 'a:0:{}', '', 1001, '221.216.117.25') |
| 14:39:52.022 | 0.4 ms | SELECT | SELECT * FROM "a57be577deb434"."tbl_erp_inventory_products" WHERE "erp_purchase_inbound_product_id"=430 |
| 14:39:52.023 | 1.0 ms | UPDATE | UPDATE "a57be577deb434"."tbl_erp_inventory_products" SET "number"='2', "inventory"='2', "total_amount"='19081.7' WHERE "id"=493 |
| 14:39:52.024 | 1.3 ms | INSERT | INSERT INTO "a57be577deb434"."tbl_action_logs" ("action", "object_type", "object_id", "new_value", "old_value", "created_by", "ip_address") VALUES ('UPDATE', 'app\models\ErpInventoryProducts', 493, 'a:0:{}', '', 1001, '221.216.117.25') |
| 14:39:52.025 | 0.2 ms | SELECT | SELECT * FROM "a57be577deb434"."tbl_erp_purchase_inbound_product_sns" WHERE "erp_purchase_inbound_product_id"=430 |
| 14:39:52.026 | 3.3 ms | SELECT | SELECT
d.nspname AS table_schema,
c.relname AS table_name,
a.attname AS column_name,
t.typname AS data_type,
a.attlen AS character_maximum_length,
pg_catalog.col_description(c.oid, a.attnum) AS column_comment,
a.atttypmod AS modifier,
a.attnotnull = false AS is_nullable,
CAST(pg_get_expr(ad.adbin, ad.adrelid) AS varchar) AS column_default,
coalesce(pg_get_expr(ad.adbin, ad.adrelid) ~ 'nextval',false) AS is_autoinc,
array_to_string((select array_agg(enumlabel) from pg_enum where enumtypid=a.atttypid)::varchar[],',') as enum_values,
CASE atttypid
WHEN 21 /*int2*/ THEN 16
WHEN 23 /*int4*/ THEN 32
WHEN 20 /*int8*/ THEN 64
WHEN 1700 /*numeric*/ THEN
CASE WHEN atttypmod = -1
THEN null
ELSE ((atttypmod - 4) >> 16) & 65535
END
WHEN 700 /*float4*/ THEN 24 /*FLT_MANT_DIG*/
WHEN 701 /*float8*/ THEN 53 /*DBL_MANT_DIG*/
ELSE null
END AS numeric_precision,
CASE
WHEN atttypid IN (21, 23, 20) THEN 0
WHEN atttypid IN (1700) THEN
CASE
WHEN atttypmod = -1 THEN null
ELSE (atttypmod - 4) & 65535
END
ELSE null
END AS numeric_scale,
CAST(
information_schema._pg_char_max_length(information_schema._pg_truetypid(a, t), information_schema._pg_truetypmod(a, t))
AS numeric
) AS size,
a.attnum = any (ct.conkey) as is_pkey
FROM
pg_class c
LEFT JOIN pg_attribute a ON a.attrelid = c.oid
LEFT JOIN pg_attrdef ad ON a.attrelid = ad.adrelid AND a.attnum = ad.adnum
LEFT JOIN pg_type t ON a.atttypid = t.oid
LEFT JOIN pg_namespace d ON d.oid = c.relnamespace
LEFT join pg_constraint ct on ct.conrelid=c.oid and ct.contype='p'
WHERE
a.attnum > 0 and t.typname != ''
and c.relname = 'tbl_erp_purchase_inbound_product_sns'
and d.nspname = 'a57be577deb434'
ORDER BY
a.attnum; |
| 14:39:52.030 | 4.3 ms | SELECT | select
ct.conname as constraint_name,
a.attname as column_name,
fc.relname as foreign_table_name,
fns.nspname as foreign_table_schema,
fa.attname as foreign_column_name
from
(SELECT ct.conname, ct.conrelid, ct.confrelid, ct.conkey, ct.contype, ct.confkey, generate_subscripts(ct.conkey, 1) AS s
FROM pg_constraint ct
) AS ct
inner join pg_class c on c.oid=ct.conrelid
inner join pg_namespace ns on c.relnamespace=ns.oid
inner join pg_attribute a on a.attrelid=ct.conrelid and a.attnum = ct.conkey[ct.s]
left join pg_class fc on fc.oid=ct.confrelid
left join pg_namespace fns on fc.relnamespace=fns.oid
left join pg_attribute fa on fa.attrelid=ct.confrelid and fa.attnum = ct.confkey[ct.s]
where
ct.contype='f'
and c.relname='tbl_erp_purchase_inbound_product_sns'
and ns.nspname='a57be577deb434'
order by
fns.nspname, fc.relname, a.attnum |
| 14:39:52.035 | 0.3 ms | DELETE | DELETE FROM "a57be577deb434"."tbl_erp_inventory_product_sns" WHERE ("erp_inventory_product_id"=493) AND ("erp_purchase_inbound_product_sn_id"<>39) |
| 14:39:52.035 | 0.3 ms | SELECT | SELECT * FROM "a57be577deb434"."tbl_erp_inventory_product_sns" WHERE "erp_inventory_product_id"=493 |
| 14:39:52.036 | 3.8 ms | SELECT | SELECT
d.nspname AS table_schema,
c.relname AS table_name,
a.attname AS column_name,
t.typname AS data_type,
a.attlen AS character_maximum_length,
pg_catalog.col_description(c.oid, a.attnum) AS column_comment,
a.atttypmod AS modifier,
a.attnotnull = false AS is_nullable,
CAST(pg_get_expr(ad.adbin, ad.adrelid) AS varchar) AS column_default,
coalesce(pg_get_expr(ad.adbin, ad.adrelid) ~ 'nextval',false) AS is_autoinc,
array_to_string((select array_agg(enumlabel) from pg_enum where enumtypid=a.atttypid)::varchar[],',') as enum_values,
CASE atttypid
WHEN 21 /*int2*/ THEN 16
WHEN 23 /*int4*/ THEN 32
WHEN 20 /*int8*/ THEN 64
WHEN 1700 /*numeric*/ THEN
CASE WHEN atttypmod = -1
THEN null
ELSE ((atttypmod - 4) >> 16) & 65535
END
WHEN 700 /*float4*/ THEN 24 /*FLT_MANT_DIG*/
WHEN 701 /*float8*/ THEN 53 /*DBL_MANT_DIG*/
ELSE null
END AS numeric_precision,
CASE
WHEN atttypid IN (21, 23, 20) THEN 0
WHEN atttypid IN (1700) THEN
CASE
WHEN atttypmod = -1 THEN null
ELSE (atttypmod - 4) & 65535
END
ELSE null
END AS numeric_scale,
CAST(
information_schema._pg_char_max_length(information_schema._pg_truetypid(a, t), information_schema._pg_truetypmod(a, t))
AS numeric
) AS size,
a.attnum = any (ct.conkey) as is_pkey
FROM
pg_class c
LEFT JOIN pg_attribute a ON a.attrelid = c.oid
LEFT JOIN pg_attrdef ad ON a.attrelid = ad.adrelid AND a.attnum = ad.adnum
LEFT JOIN pg_type t ON a.atttypid = t.oid
LEFT JOIN pg_namespace d ON d.oid = c.relnamespace
LEFT join pg_constraint ct on ct.conrelid=c.oid and ct.contype='p'
WHERE
a.attnum > 0 and t.typname != ''
and c.relname = 'tbl_erp_inventory_product_sns'
and d.nspname = 'a57be577deb434'
ORDER BY
a.attnum; |
| 14:39:52.040 | 11.7 ms | SELECT | select
ct.conname as constraint_name,
a.attname as column_name,
fc.relname as foreign_table_name,
fns.nspname as foreign_table_schema,
fa.attname as foreign_column_name
from
(SELECT ct.conname, ct.conrelid, ct.confrelid, ct.conkey, ct.contype, ct.confkey, generate_subscripts(ct.conkey, 1) AS s
FROM pg_constraint ct
) AS ct
inner join pg_class c on c.oid=ct.conrelid
inner join pg_namespace ns on c.relnamespace=ns.oid
inner join pg_attribute a on a.attrelid=ct.conrelid and a.attnum = ct.conkey[ct.s]
left join pg_class fc on fc.oid=ct.confrelid
left join pg_namespace fns on fc.relnamespace=fns.oid
left join pg_attribute fa on fa.attrelid=ct.confrelid and fa.attnum = ct.confkey[ct.s]
where
ct.contype='f'
and c.relname='tbl_erp_inventory_product_sns'
and ns.nspname='a57be577deb434'
order by
fns.nspname, fc.relname, a.attnum |
| 14:39:52.052 | 0.4 ms | SELECT | SELECT SUM(outbound) FROM "a57be577deb434"."tbl_erp_inventory_product_spents" WHERE "erp_inventory_product_id"=493 |
| 14:39:52.053 | 1.0 ms | UPDATE | UPDATE "a57be577deb434"."tbl_erp_inventory_products" SET "outbound"='0' WHERE "id"=493 |
| 14:39:52.054 | 0.9 ms | INSERT | INSERT INTO "a57be577deb434"."tbl_action_logs" ("action", "object_type", "object_id", "new_value", "old_value", "created_by", "ip_address") VALUES ('UPDATE', 'app\models\ErpInventoryProducts', 493, 'a:0:{}', '', 1001, '221.216.117.25') |
| 14:39:52.055 | 0.3 ms | SELECT | SELECT * FROM "a57be577deb434"."tbl_settings" WHERE "setting_key"='erp_cost_type' |
| 14:39:52.056 | 0.3 ms | SELECT | SELECT * FROM "a57be577deb434"."tbl_settings" WHERE "setting_key"='erp_decimal_point' |
| 14:39:52.056 | 1.0 ms | UPDATE | UPDATE "a57be577deb434"."tbl_erp_inventory_products" SET "actual_total_amount"='19081.7' WHERE "id"=493 |
| 14:39:52.058 | 1.1 ms | INSERT | INSERT INTO "a57be577deb434"."tbl_action_logs" ("action", "object_type", "object_id", "new_value", "old_value", "created_by", "ip_address") VALUES ('UPDATE', 'app\models\ErpInventoryProducts', 493, 'a:0:{}', '', 1001, '221.216.117.25') |
| 14:39:52.059 | 0.9 ms | UPDATE | UPDATE "a57be577deb434"."tbl_erp_purchase_inbound_products" SET "outbound"='0', "inventory"='2' WHERE "id"=430 |
| 14:39:52.060 | 1.1 ms | INSERT | INSERT INTO "a57be577deb434"."tbl_action_logs" ("action", "object_type", "object_id", "new_value", "old_value", "created_by", "ip_address") VALUES ('UPDATE', 'app\models\ErpPurchaseInboundProducts', 430, 'a:0:{}', '', 1001, '221.216.117.25') |
| 14:39:52.062 | 0.6 ms | SELECT | SELECT * FROM "a57be577deb434"."tbl_erp_inventory_products" WHERE "erp_purchase_inbound_product_id"=429 |
| 14:39:52.062 | 1.6 ms | UPDATE | UPDATE "a57be577deb434"."tbl_erp_inventory_products" SET "number"='2', "inventory"='2', "total_amount"='158798.2' WHERE "id"=492 |
| 14:39:52.064 | 1.4 ms | INSERT | INSERT INTO "a57be577deb434"."tbl_action_logs" ("action", "object_type", "object_id", "new_value", "old_value", "created_by", "ip_address") VALUES ('UPDATE', 'app\models\ErpInventoryProducts', 492, 'a:0:{}', '', 1001, '221.216.117.25') |
| 14:39:52.066 | 0.4 ms | SELECT | SELECT * FROM "a57be577deb434"."tbl_erp_purchase_inbound_product_sns" WHERE "erp_purchase_inbound_product_id"=429 |
| 14:39:52.066 | 0.4 ms | DELETE | DELETE FROM "a57be577deb434"."tbl_erp_inventory_product_sns" WHERE ("erp_inventory_product_id"=492) AND ("erp_purchase_inbound_product_sn_id" NOT IN (42, 43)) |
| 14:39:52.067 | 0.4 ms | SELECT | SELECT * FROM "a57be577deb434"."tbl_erp_inventory_product_sns" WHERE "erp_inventory_product_id"=492 |
| 14:39:52.068 | 0.5 ms | SELECT | SELECT SUM(outbound) FROM "a57be577deb434"."tbl_erp_inventory_product_spents" WHERE "erp_inventory_product_id"=492 |
| 14:39:52.068 | 1.3 ms | UPDATE | UPDATE "a57be577deb434"."tbl_erp_inventory_products" SET "inventory"='0' WHERE "id"=492 |
| 14:39:52.070 | 1.4 ms | INSERT | INSERT INTO "a57be577deb434"."tbl_action_logs" ("action", "object_type", "object_id", "new_value", "old_value", "created_by", "ip_address") VALUES ('UPDATE', 'app\models\ErpInventoryProducts', 492, 'a:0:{}', '', 1001, '221.216.117.25') |
| 14:39:52.072 | 0.4 ms | SELECT | SELECT * FROM "a57be577deb434"."tbl_settings" WHERE "setting_key"='erp_cost_type' |
| 14:39:52.072 | 0.3 ms | SELECT | SELECT * FROM "a57be577deb434"."tbl_settings" WHERE "setting_key"='erp_decimal_point' |
| 14:39:52.073 | 1.1 ms | INSERT | INSERT INTO "a57be577deb434"."tbl_action_logs" ("action", "object_type", "object_id", "new_value", "old_value", "created_by", "ip_address") VALUES ('UPDATE', 'app\models\ErpInventoryProducts', 492, 'a:0:{}', '', 1001, '221.216.117.25') |
| 14:39:52.074 | 1.0 ms | UPDATE | UPDATE "a57be577deb434"."tbl_erp_purchase_inbound_products" SET "inventory"='0' WHERE "id"=429 |
| 14:39:52.075 | 0.9 ms | INSERT | INSERT INTO "a57be577deb434"."tbl_action_logs" ("action", "object_type", "object_id", "new_value", "old_value", "created_by", "ip_address") VALUES ('UPDATE', 'app\models\ErpPurchaseInboundProducts', 429, 'a:0:{}', '', 1001, '221.216.117.25') |
| 14:39:52.077 | 5.2 ms | SELECT | SELECT
d.nspname AS table_schema,
c.relname AS table_name,
a.attname AS column_name,
t.typname AS data_type,
a.attlen AS character_maximum_length,
pg_catalog.col_description(c.oid, a.attnum) AS column_comment,
a.atttypmod AS modifier,
a.attnotnull = false AS is_nullable,
CAST(pg_get_expr(ad.adbin, ad.adrelid) AS varchar) AS column_default,
coalesce(pg_get_expr(ad.adbin, ad.adrelid) ~ 'nextval',false) AS is_autoinc,
array_to_string((select array_agg(enumlabel) from pg_enum where enumtypid=a.atttypid)::varchar[],',') as enum_values,
CASE atttypid
WHEN 21 /*int2*/ THEN 16
WHEN 23 /*int4*/ THEN 32
WHEN 20 /*int8*/ THEN 64
WHEN 1700 /*numeric*/ THEN
CASE WHEN atttypmod = -1
THEN null
ELSE ((atttypmod - 4) >> 16) & 65535
END
WHEN 700 /*float4*/ THEN 24 /*FLT_MANT_DIG*/
WHEN 701 /*float8*/ THEN 53 /*DBL_MANT_DIG*/
ELSE null
END AS numeric_precision,
CASE
WHEN atttypid IN (21, 23, 20) THEN 0
WHEN atttypid IN (1700) THEN
CASE
WHEN atttypmod = -1 THEN null
ELSE (atttypmod - 4) & 65535
END
ELSE null
END AS numeric_scale,
CAST(
information_schema._pg_char_max_length(information_schema._pg_truetypid(a, t), information_schema._pg_truetypmod(a, t))
AS numeric
) AS size,
a.attnum = any (ct.conkey) as is_pkey
FROM
pg_class c
LEFT JOIN pg_attribute a ON a.attrelid = c.oid
LEFT JOIN pg_attrdef ad ON a.attrelid = ad.adrelid AND a.attnum = ad.adnum
LEFT JOIN pg_type t ON a.atttypid = t.oid
LEFT JOIN pg_namespace d ON d.oid = c.relnamespace
LEFT join pg_constraint ct on ct.conrelid=c.oid and ct.contype='p'
WHERE
a.attnum > 0 and t.typname != ''
and c.relname = 'tbl_products'
and d.nspname = 'a57be577deb434'
ORDER BY
a.attnum; |
| 14:39:52.083 | 9.9 ms | SELECT | select
ct.conname as constraint_name,
a.attname as column_name,
fc.relname as foreign_table_name,
fns.nspname as foreign_table_schema,
fa.attname as foreign_column_name
from
(SELECT ct.conname, ct.conrelid, ct.confrelid, ct.conkey, ct.contype, ct.confkey, generate_subscripts(ct.conkey, 1) AS s
FROM pg_constraint ct
) AS ct
inner join pg_class c on c.oid=ct.conrelid
inner join pg_namespace ns on c.relnamespace=ns.oid
inner join pg_attribute a on a.attrelid=ct.conrelid and a.attnum = ct.conkey[ct.s]
left join pg_class fc on fc.oid=ct.confrelid
left join pg_namespace fns on fc.relnamespace=fns.oid
left join pg_attribute fa on fa.attrelid=ct.confrelid and fa.attnum = ct.confkey[ct.s]
where
ct.contype='f'
and c.relname='tbl_products'
and ns.nspname='a57be577deb434'
order by
fns.nspname, fc.relname, a.attnum |
| 14:39:52.093 | 2.5 ms | UPDATE | UPDATE "a57be577deb434"."tbl_products" SET "updated_at"='now()', "in_out_at"='now()' WHERE "id" IN (1562, 1584, 2262, 1558) |
| 14:39:52.096 | 1.1 ms | INSERT | INSERT INTO "a57be577deb434"."tbl_action_logs" ("action", "object_type", "object_id", "new_value", "old_value", "created_by", "ip_address") VALUES ('UPDATE', 'app\models\ErpPurchaseInbounds', 211, 'a:0:{}', '', 1001, '221.216.117.25') |
| 14:39:52.098 | 0.4 ms | UPDATE | UPDATE "a57be577deb434"."tbl_erp_inventory_products" SET "inventory"='0', "number"='0', "actual_total_amount"='0' WHERE ("erp_purchase_inbound_id"=211) AND ("erp_purchase_inbound_product_id" NOT IN (427, 428, 430, 429)) |
| 14:39:52.099 | 1.8 ms | SELECT | SELECT * FROM "a57be577deb434"."tbl_erp_purchase_orders" WHERE "id"=2204 |
| 14:39:52.101 | 4.0 ms | SELECT | SELECT
d.nspname AS table_schema,
c.relname AS table_name,
a.attname AS column_name,
t.typname AS data_type,
a.attlen AS character_maximum_length,
pg_catalog.col_description(c.oid, a.attnum) AS column_comment,
a.atttypmod AS modifier,
a.attnotnull = false AS is_nullable,
CAST(pg_get_expr(ad.adbin, ad.adrelid) AS varchar) AS column_default,
coalesce(pg_get_expr(ad.adbin, ad.adrelid) ~ 'nextval',false) AS is_autoinc,
array_to_string((select array_agg(enumlabel) from pg_enum where enumtypid=a.atttypid)::varchar[],',') as enum_values,
CASE atttypid
WHEN 21 /*int2*/ THEN 16
WHEN 23 /*int4*/ THEN 32
WHEN 20 /*int8*/ THEN 64
WHEN 1700 /*numeric*/ THEN
CASE WHEN atttypmod = -1
THEN null
ELSE ((atttypmod - 4) >> 16) & 65535
END
WHEN 700 /*float4*/ THEN 24 /*FLT_MANT_DIG*/
WHEN 701 /*float8*/ THEN 53 /*DBL_MANT_DIG*/
ELSE null
END AS numeric_precision,
CASE
WHEN atttypid IN (21, 23, 20) THEN 0
WHEN atttypid IN (1700) THEN
CASE
WHEN atttypmod = -1 THEN null
ELSE (atttypmod - 4) & 65535
END
ELSE null
END AS numeric_scale,
CAST(
information_schema._pg_char_max_length(information_schema._pg_truetypid(a, t), information_schema._pg_truetypmod(a, t))
AS numeric
) AS size,
a.attnum = any (ct.conkey) as is_pkey
FROM
pg_class c
LEFT JOIN pg_attribute a ON a.attrelid = c.oid
LEFT JOIN pg_attrdef ad ON a.attrelid = ad.adrelid AND a.attnum = ad.adnum
LEFT JOIN pg_type t ON a.atttypid = t.oid
LEFT JOIN pg_namespace d ON d.oid = c.relnamespace
LEFT join pg_constraint ct on ct.conrelid=c.oid and ct.contype='p'
WHERE
a.attnum > 0 and t.typname != ''
and c.relname = 'tbl_erp_purchase_orders'
and d.nspname = 'a57be577deb434'
ORDER BY
a.attnum; |
| 14:39:52.105 | 5.9 ms | SELECT | select
ct.conname as constraint_name,
a.attname as column_name,
fc.relname as foreign_table_name,
fns.nspname as foreign_table_schema,
fa.attname as foreign_column_name
from
(SELECT ct.conname, ct.conrelid, ct.confrelid, ct.conkey, ct.contype, ct.confkey, generate_subscripts(ct.conkey, 1) AS s
FROM pg_constraint ct
) AS ct
inner join pg_class c on c.oid=ct.conrelid
inner join pg_namespace ns on c.relnamespace=ns.oid
inner join pg_attribute a on a.attrelid=ct.conrelid and a.attnum = ct.conkey[ct.s]
left join pg_class fc on fc.oid=ct.confrelid
left join pg_namespace fns on fc.relnamespace=fns.oid
left join pg_attribute fa on fa.attrelid=ct.confrelid and fa.attnum = ct.confkey[ct.s]
where
ct.contype='f'
and c.relname='tbl_erp_purchase_orders'
and ns.nspname='a57be577deb434'
order by
fns.nspname, fc.relname, a.attnum |
| 14:39:52.112 | 0.6 ms | SELECT | SELECT * FROM "a57be577deb434"."tbl_erp_purchase_order_products" WHERE "erp_purchase_order_id"=2204 |
| 14:39:52.113 | 3.0 ms | SELECT | SELECT
d.nspname AS table_schema,
c.relname AS table_name,
a.attname AS column_name,
t.typname AS data_type,
a.attlen AS character_maximum_length,
pg_catalog.col_description(c.oid, a.attnum) AS column_comment,
a.atttypmod AS modifier,
a.attnotnull = false AS is_nullable,
CAST(pg_get_expr(ad.adbin, ad.adrelid) AS varchar) AS column_default,
coalesce(pg_get_expr(ad.adbin, ad.adrelid) ~ 'nextval',false) AS is_autoinc,
array_to_string((select array_agg(enumlabel) from pg_enum where enumtypid=a.atttypid)::varchar[],',') as enum_values,
CASE atttypid
WHEN 21 /*int2*/ THEN 16
WHEN 23 /*int4*/ THEN 32
WHEN 20 /*int8*/ THEN 64
WHEN 1700 /*numeric*/ THEN
CASE WHEN atttypmod = -1
THEN null
ELSE ((atttypmod - 4) >> 16) & 65535
END
WHEN 700 /*float4*/ THEN 24 /*FLT_MANT_DIG*/
WHEN 701 /*float8*/ THEN 53 /*DBL_MANT_DIG*/
ELSE null
END AS numeric_precision,
CASE
WHEN atttypid IN (21, 23, 20) THEN 0
WHEN atttypid IN (1700) THEN
CASE
WHEN atttypmod = -1 THEN null
ELSE (atttypmod - 4) & 65535
END
ELSE null
END AS numeric_scale,
CAST(
information_schema._pg_char_max_length(information_schema._pg_truetypid(a, t), information_schema._pg_truetypmod(a, t))
AS numeric
) AS size,
a.attnum = any (ct.conkey) as is_pkey
FROM
pg_class c
LEFT JOIN pg_attribute a ON a.attrelid = c.oid
LEFT JOIN pg_attrdef ad ON a.attrelid = ad.adrelid AND a.attnum = ad.adnum
LEFT JOIN pg_type t ON a.atttypid = t.oid
LEFT JOIN pg_namespace d ON d.oid = c.relnamespace
LEFT join pg_constraint ct on ct.conrelid=c.oid and ct.contype='p'
WHERE
a.attnum > 0 and t.typname != ''
and c.relname = 'tbl_erp_purchase_order_products'
and d.nspname = 'a57be577deb434'
ORDER BY
a.attnum; |
| 14:39:52.116 | 4.4 ms | SELECT | select
ct.conname as constraint_name,
a.attname as column_name,
fc.relname as foreign_table_name,
fns.nspname as foreign_table_schema,
fa.attname as foreign_column_name
from
(SELECT ct.conname, ct.conrelid, ct.confrelid, ct.conkey, ct.contype, ct.confkey, generate_subscripts(ct.conkey, 1) AS s
FROM pg_constraint ct
) AS ct
inner join pg_class c on c.oid=ct.conrelid
inner join pg_namespace ns on c.relnamespace=ns.oid
inner join pg_attribute a on a.attrelid=ct.conrelid and a.attnum = ct.conkey[ct.s]
left join pg_class fc on fc.oid=ct.confrelid
left join pg_namespace fns on fc.relnamespace=fns.oid
left join pg_attribute fa on fa.attrelid=ct.confrelid and fa.attnum = ct.confkey[ct.s]
where
ct.contype='f'
and c.relname='tbl_erp_purchase_order_products'
and ns.nspname='a57be577deb434'
order by
fns.nspname, fc.relname, a.attnum |
| 14:39:52.121 | 0.4 ms | SELECT | SELECT * FROM "a57be577deb434"."tbl_erp_purchase_inbound_products" WHERE "erp_purchase_order_product_id" IN (421, 422, 423, 420) |
| 14:39:52.122 | 0.4 ms | SELECT | SELECT * FROM "a57be577deb434"."tbl_erp_purchase_inbounds" WHERE "id" IN (209, 211) |
| 14:39:52.123 | 0.3 ms | SELECT | SELECT * FROM "a57be577deb434"."tbl_erp_purchase_return_products" WHERE "erp_purchase_inbound_product_id" IN (424, 428, 430, 429, 427) |
| 14:39:52.123 | 0.3 ms | SELECT | SELECT * FROM "a57be577deb434"."tbl_erp_purchase_returns" WHERE "id"=7 |
| 14:39:52.124 | 2.6 ms | UPDATE | UPDATE "a57be577deb434"."tbl_erp_purchase_order_products" SET "into_inventory"='2' WHERE "id"=421 |
| 14:39:52.127 | 0.9 ms | INSERT | INSERT INTO "a57be577deb434"."tbl_action_logs" ("action", "object_type", "object_id", "new_value", "old_value", "created_by", "ip_address") VALUES ('UPDATE', 'app\models\ErpPurchaseOrderProducts', 421, 'a:0:{}', '', 1001, '221.216.117.25') |
| 14:39:52.128 | 0.7 ms | UPDATE | UPDATE "a57be577deb434"."tbl_erp_purchase_order_products" SET "into_inventory"='2' WHERE "id"=422 |
| 14:39:52.129 | 0.9 ms | INSERT | INSERT INTO "a57be577deb434"."tbl_action_logs" ("action", "object_type", "object_id", "new_value", "old_value", "created_by", "ip_address") VALUES ('UPDATE', 'app\models\ErpPurchaseOrderProducts', 422, 'a:0:{}', '', 1001, '221.216.117.25') |
| 14:39:52.130 | 0.9 ms | UPDATE | UPDATE "a57be577deb434"."tbl_erp_purchase_order_products" SET "into_inventory"='2' WHERE "id"=423 |
| 14:39:52.131 | 1.3 ms | INSERT | INSERT INTO "a57be577deb434"."tbl_action_logs" ("action", "object_type", "object_id", "new_value", "old_value", "created_by", "ip_address") VALUES ('UPDATE', 'app\models\ErpPurchaseOrderProducts', 423, 'a:0:{}', '', 1001, '221.216.117.25') |
| 14:39:52.133 | 1.0 ms | UPDATE | UPDATE "a57be577deb434"."tbl_erp_purchase_order_products" SET "into_inventory"='3' WHERE "id"=420 |
| 14:39:52.134 | 1.3 ms | INSERT | INSERT INTO "a57be577deb434"."tbl_action_logs" ("action", "object_type", "object_id", "new_value", "old_value", "created_by", "ip_address") VALUES ('UPDATE', 'app\models\ErpPurchaseOrderProducts', 420, 'a:0:{}', '', 1001, '221.216.117.25') |
| 14:39:52.136 | 0.9 ms | INSERT | INSERT INTO "a57be577deb434"."tbl_action_logs" ("action", "object_type", "object_id", "new_value", "old_value", "created_by", "ip_address") VALUES ('UPDATE', 'app\models\ErpPurchaseOrders', 2204, 'a:0:{}', '', 1001, '221.216.117.25') |
| 14:39:52.137 | 0.4 ms | SELECT | SELECT * FROM "a57be577deb434"."tbl_users" WHERE "id"=1001 |
| 14:39:52.138 | 0.3 ms | SELECT | SELECT * FROM "a57be577deb434"."tbl_erp_purchase_return_verify_rels" WHERE ("status"=0) AND ("erp_purchase_return_id"=7) ORDER BY "id" |
| 14:39:52.138 | 0.3 ms | SELECT | SELECT * FROM "a57be577deb434"."tbl_erp_purchase_return_verify_rels" WHERE ("status"=0) AND ("erp_purchase_return_id"=7) ORDER BY "id" |
| 14:39:52.139 | 0.4 ms | SELECT | SELECT * FROM "a57be577deb434"."tbl_users" WHERE "id"=1001 |
| 14:39:52.140 | 3.2 ms | SELECT | SELECT
d.nspname AS table_schema,
c.relname AS table_name,
a.attname AS column_name,
t.typname AS data_type,
a.attlen AS character_maximum_length,
pg_catalog.col_description(c.oid, a.attnum) AS column_comment,
a.atttypmod AS modifier,
a.attnotnull = false AS is_nullable,
CAST(pg_get_expr(ad.adbin, ad.adrelid) AS varchar) AS column_default,
coalesce(pg_get_expr(ad.adbin, ad.adrelid) ~ 'nextval',false) AS is_autoinc,
array_to_string((select array_agg(enumlabel) from pg_enum where enumtypid=a.atttypid)::varchar[],',') as enum_values,
CASE atttypid
WHEN 21 /*int2*/ THEN 16
WHEN 23 /*int4*/ THEN 32
WHEN 20 /*int8*/ THEN 64
WHEN 1700 /*numeric*/ THEN
CASE WHEN atttypmod = -1
THEN null
ELSE ((atttypmod - 4) >> 16) & 65535
END
WHEN 700 /*float4*/ THEN 24 /*FLT_MANT_DIG*/
WHEN 701 /*float8*/ THEN 53 /*DBL_MANT_DIG*/
ELSE null
END AS numeric_precision,
CASE
WHEN atttypid IN (21, 23, 20) THEN 0
WHEN atttypid IN (1700) THEN
CASE
WHEN atttypmod = -1 THEN null
ELSE (atttypmod - 4) & 65535
END
ELSE null
END AS numeric_scale,
CAST(
information_schema._pg_char_max_length(information_schema._pg_truetypid(a, t), information_schema._pg_truetypmod(a, t))
AS numeric
) AS size,
a.attnum = any (ct.conkey) as is_pkey
FROM
pg_class c
LEFT JOIN pg_attribute a ON a.attrelid = c.oid
LEFT JOIN pg_attrdef ad ON a.attrelid = ad.adrelid AND a.attnum = ad.adnum
LEFT JOIN pg_type t ON a.atttypid = t.oid
LEFT JOIN pg_namespace d ON d.oid = c.relnamespace
LEFT join pg_constraint ct on ct.conrelid=c.oid and ct.contype='p'
WHERE
a.attnum > 0 and t.typname != ''
and c.relname = 'tbl_object_change_logs'
and d.nspname = 'a57be577deb434'
ORDER BY
a.attnum; |
| 14:39:52.143 | 4.1 ms | SELECT | select
ct.conname as constraint_name,
a.attname as column_name,
fc.relname as foreign_table_name,
fns.nspname as foreign_table_schema,
fa.attname as foreign_column_name
from
(SELECT ct.conname, ct.conrelid, ct.confrelid, ct.conkey, ct.contype, ct.confkey, generate_subscripts(ct.conkey, 1) AS s
FROM pg_constraint ct
) AS ct
inner join pg_class c on c.oid=ct.conrelid
inner join pg_namespace ns on c.relnamespace=ns.oid
inner join pg_attribute a on a.attrelid=ct.conrelid and a.attnum = ct.conkey[ct.s]
left join pg_class fc on fc.oid=ct.confrelid
left join pg_namespace fns on fc.relnamespace=fns.oid
left join pg_attribute fa on fa.attrelid=ct.confrelid and fa.attnum = ct.confkey[ct.s]
where
ct.contype='f'
and c.relname='tbl_object_change_logs'
and ns.nspname='a57be577deb434'
order by
fns.nspname, fc.relname, a.attnum |
| 14:39:52.148 | 11.3 ms | INSERT | INSERT INTO "a57be577deb434"."tbl_object_change_logs" ("act", "attribute", "object_id", "object_type", "created_by", "created_at", "new_value", "old_value", "description") VALUES (1, 'create', 7, 20003, 1001, '2026-06-26 14:39:51', '{"id":7,"serial_no":"CGTH-20260626-00001","from_date":null,"wrote_date":"2026-06-26","handler":1011,"supplier_id":46,"purchase_contract_id":4447,"erp_store_id":null,"status":1,"abstract":null,"description":"","verify_type":2,"next_verify_user":1001,"next_stop_verify_user":null,"verify_at":null,"stop_at":null,"refuse_description":null,"is_resubmitted":false,"number":"2","amount":"43363.32","created_by":1001,"stop_description":null,"is_settle":false,"created_at":"2026-06-26 14:39:51","updated_at":"2026-06-26 14:39:51","print_times":null}', '{"id":7,"serial_no":"CGTH-20260626-00001","from_date":null,"wrote_date":"2026-06-26","handler":1011,"supplier_id":46,"purchase_contract_id":4447,"erp_store_id":null,"status":1,"abstract":null,"description":"","verify_type":2,"next_verify_user":1001,"next_stop_verify_user":null,"verify_at":null,"stop_at":null,"refuse_description":null,"is_resubmitted":false,"number":"2","amount":"43363.32","created_by":1001,"stop_description":null,"is_settle":false,"created_at":"2026-06-26 14:39:51","updated_at":"2026-06-26 14:39:51","print_times":null}', '{"d1":"\u5218\u4eba\u8bda","d2":"\u521b\u5efa\u4e86","d3":"\u91c7\u8d2d\u9000\u8d27\u5355\u7533\u8bf7","d4":[]}') RETURNING "id" |
| 14:39:52.160 | 0.9 ms | INSERT | INSERT INTO "a57be577deb434"."tbl_action_logs" ("action", "object_type", "object_id", "new_value", "old_value", "created_by", "ip_address") VALUES ('INSERT', 'app\models\ObjectChangeLogs', 642702, 'a:13:{s:2:"id";i:642702;s:9:"object_id";i:7;s:11:"object_type";i:20003;s:9:"target_id";N;s:18:"target_object_type";N;s:3:"act";i:1;s:9:"attribute";s:6:"create";s:9:"old_value";s:541:"{"id":7,"serial_no":"CGTH-20260626-00001","from_date":null,"wrote_date":"2026-06-26","handler":1011,"supplier_id":46,"purchase_contract_id":4447,"erp_store_id":null,"status":1,"abstract":null,"description":"","verify_type":2,"next_verify_user":1001,"next_stop_verify_user":null,"verify_at":null,"stop_at":null,"refuse_description":null,"is_resubmitted":false,"number":"2","amount":"43363.32","created_by":1001,"stop_description":null,"is_settle":false,"created_at":"2026-06-26 14:39:51","updated_at":"2026-06-26 14:39:51","print_times":null}";s:9:"new_value";s:541:"{"id":7,"serial_no":"CGTH-20260626-00001","from_date":null,"wrote_date":"2026-06-26","handler":1011,"supplier_id":46,"purchase_contract_id":4447,"erp_store_id":null,"status":1,"abstract":null,"description":"","verify_type":2,"next_verify_user":1001,"next_stop_verify_user":null,"verify_at":null,"stop_at":null,"refuse_description":null,"is_resubmitted":false,"number":"2","amount":"43363.32","created_by":1001,"stop_description":null,"is_settle":false,"created_at":"2026-06-26 14:39:51","updated_at":"2026-06-26 14:39:51","print_times":null}";s:11:"description";s:111:"{"d1":"\u5218\u4eba\u8bda","d2":"\u521b\u5efa\u4e86","d3":"\u91c7\u8d2d\u9000\u8d27\u5355\u7533\u8bf7","d4":[]}";s:10:"created_by";i:1001;s:10:"created_at";s:19:"2026-06-26 14:39:51";s:9:"is_delete";N;}', '', 1001, '221.216.117.25') |
| 14:39:52.162 | 1.2 ms | INSERT | INSERT INTO "global"."tbl_api_log" ("code", "schema", "user_id", "device_type", "url", "request", "response", "php_error", "time", "duration") VALUES (200, 'a57be577deb434', 1001, 5, 'vue/purchase-contract/save-new-return', '{"ErpPurchaseReturns":{"id":"4447","supplier_id":"46","supplier_name":"\u795e\u5dde\u6570\u7801(\u4e2d\u56fd)\u6709\u9650\u516c\u53f8","handler":"1011","contract_type":"1","serial_no":"DZ202603233147774","signed_at":"2026-03-24","from_date":"","description":"","contractScans":["32534"],"contractFileList":{"32534":"DZ202603233147774.pdf"},"erpPurchaseReturnVerifyRels":["1001"],"original_amount":"278488.32","returns_amount":"81526.72","returns_number":"6","erpPurchaseReturnProducts":{"new":[{"product_id":"1584","number":"2","amount":"21681.66","total_amount":"43363.32","description":"","erp_purchase_order_id":"2204","erp_purchase_inbound_product_id":"428","erp_inventory_start_product_id":"","erp_inventory_product_id":"491","sns":""}]}}}', '{"code":2000,"result":{"id":7},"status":1,"msg":[{"name":"success","success":"\u65b0\u91c7\u8d2d\u9000\u8d27\u5355\u5df2\u521b\u5efa\u6210\u529f","error":""}],"mod":0,"ip":"221.216.117.25","ua":"Mozilla\/5.0 (Macintosh; Intel Mac OS X 10_15_7) AppleWebKit\/537.36 (KHTML, like Gecko) Chrome\/149.0.0.0 Safari\/537.36"}', FALSE, '2026-06-26 14:39:52', 408216832) RETURNING "id" |