Postgres profile report (StartID: 429, EndID: 452)

pg_profile version 0.3.6

Server name: local

Report interval: 2026-07-17 04:00:01+01 - 2026-07-18 03:00:02+01

Warning!Report includes 23 sample(s) with setting pg_stat_statements.track = all.Value of %Total columns may be incorrect.

Report sections

Server statistics

Database statistics

DatabaseTransactionsBlock statisticsTuplesTemp filesSizeGrowth
CommitsRollbacksDeadlocksHit(%)ReadHitRetFetInsUpdDelSizeFiles
openbravo1196934609695.945143181951214770017032737738238116559339111142485785149843463317 GB6367309 GB6967 MB
postgres1170599.48343065473719049413481166391 kB
Total1208639609695.945143216251214835490732739643179116562820271142485785149843463317 GB6367309 GB6967 MB

Statement statistics by database

DatabaseCallsTime (s)Fetched (blk)Dirtied (blk)Temp (blk)Local (blk)Statements
ExecReadWriteTrgSharedLocalSharedLocalReadWriteReadWrite
openbravo19533329103700.38278.181309028113028319815363542629274078564641817416326955007
postgres56128.7386741345
template1634813.057176276
Total19545289103722.16278.181309037504728319815363542629274078564641817416326955628

Cluster statistics

MetricValue
Scheduled checkpoints276
Requested checkpoints
Checkpoint write time (s)54209.38
Checkpoint sync time (s)24.76
Checkpoints buffers written2359026
Background buffers written500435
Backend buffers written205051
Backend fsync count
Bgwriter interrupts (too many buffers)3115
Number of buffers allocated125005033
WAL generated25 GB
WAL segments archived1614
WAL segments archive failed

Tablespace statistics

TablespacePathSizeGrowth
pg_default309 GB6967 MB
pg_global1014 kB

SQL query statistics

Top SQL by execution time

Query IDDatabaseExec (s)%TotalRowsExecution times (ms)Executions
MeanMinMaxStdErr

a29af35cca

[ff177b6c]

openbravo12069.0211.64117410280.2520.047491168.62756777.2521174

ff35139986

[a35d3b99]

openbravo7679.397.4013585654.9264.866491903.30339617.0001358

7efafc5af2

[74267a2]

openbravo7679.337.4013585654.8834.845491903.28139616.9951358

4cb9cc1cbf

[ea4e56b9]

openbravo7679.307.4013585654.8624.831491903.26839616.9931358

1ca54a7d1e

[a8f792e0]

openbravo6896.086.658767872.2390.079491168.83053538.713876

8fe405377b

[c68fee63]

openbravo5185.235.0036514206.10111.559390071.02058993.988365

77c9f44e37

[5fc94ec0]

openbravo5184.985.0036014402.72011.541390070.99659378.484360

e2c0748a35

[e8c42400]

openbravo5173.164.9936014369.8950.042390036.74259373.869360

dca3f71473

[f268953e]

openbravo4569.894.41150913978.637908182.920917963.9763813.5395

4aae53f3da

[5b93a467]

openbravo3069.822.9622245.08016608.446168531.77217100.947138

9918228dba

[9603f2b6]

openbravo2661.802.57190504609.387551.9831067.40435.4144368

0a99da7198

[d0a21c54]

openbravo2378.682.2914331659.9333.905491739.67723991.7261433

43a80059e4

[bfd8039a]

openbravo2348.242.269392500.79221.539491813.77829593.922939

0d30ac7710

[faa0b8dc]

openbravo2321.352.245823988.58014.900491776.65037509.633582

af4ce1b038

[368ff015]

openbravo2303.752.2221010970.2592.534491735.07361823.406210

8be0d7c1e7

[baac2e1a]

openbravo2301.532.2220211393.7230.174491710.47062995.749202

8d2c8e833f

[f9b02264]

openbravo1924.031.8532962015.672911709.4241012321.92050306.2482

6aeca8addc

[e0869ab2]

openbravo1204.551.168728.6517624.06721939.9972096.145138

66933eedde

[a6742d25]

openbravo1177.421.1434739099.9870.022119241.648489.756117899

b76ef6c915

[84cd185c]

openbravo953.750.9293518341.4316466.230123054.47222048.41652

Top SQL by executions

Query IDDatabaseExecutions%TotalRowsMean(ms)Min(ms)Max(ms)StdErr(ms)Elapsed(s)

9a0540688d

[263f5b0b]

openbravo11204105.735812210.0030.00116.0360.0283.1

10410964a2

[6df21622]

openbravo9261624.749261620.0030.0023.3430.0072.8

a46753d96b

[d2788d4]

openbravo8318274.268318270.0030.0011.9710.0052.4

b280347c9b

[fc9c6197]

openbravo4238132.174238130.0110.0088.5930.0184.6

7247cdc8b5

[aada7118]

openbravo3436021.76417890.0170.00315.7910.1485.8

1b89da5cec

[6f9b1a85]

openbravo3287461.680.0010.0000.8190.0020.2

8a7672d920

[2049516b]

openbravo3242331.660.0010.0001.4800.0040.2

f2e5c3fd88

[2b8e321f]

openbravo2916481.492916480.0060.00215.1070.0291.7

784dd58a53

[c7e884e0]

openbravo2828511.452828050.0040.0022.2870.0081.0

03a1d4e90c

[1c1c8a81]

openbravo2633791.352633790.0030.0021.7460.0050.8

08c88cedcc

[6d0d7fc]

openbravo2236851.142236850.0070.0024.5140.0471.6

7f59edd627

[81592075]

openbravo1862960.951862960.0030.0026.9480.0160.5

1452c325d3

[880044aa]

openbravo1522100.781522100.0020.0011.8820.0060.3

b93f3a3e02

[30f21dca]

openbravo1471130.751471130.2580.2049.6810.06638.0

ab6445a3b6

[a5716dbe]

openbravo1471130.751471130.2300.2032.3830.04733.9

2bbd1014ed

[d9433e44]

openbravo1461640.751461640.0030.0022.0290.0060.5

281ee3922a

[5d6197e1]

openbravo1239460.631239180.0070.0041.2470.0080.9

1fbcf388f5

[588b10e0]

openbravo1184580.610.0020.0010.5330.0030.3

66933eedde

[a6742d25]

openbravo1178990.6034739099.9870.022119241.648489.7561177.4

fec93ea334

[2ff59f28]

openbravo1140530.581140530.2530.04545.7260.39928.8

Top SQL by shared blocks fetched

Query IDDatabaseblks fetched%TotalHits(%)Elapsed(s)RowsExecutions

dca3f71473

[f268953e]

openbravo208857876915.9698.234569.91505

4aae53f3da

[5b93a467]

openbravo148747569011.3696.263069.8138

66933eedde

[a6742d25]

openbravo8996804716.8799.931177.43473909117899

8d2c8e833f

[f9b02264]

openbravo8355567846.3898.531924.0322

6aeca8addc

[e0869ab2]

openbravo6614067875.0598.791204.6138

496be14648

[22c79513]

openbravo4806856193.6799.82626.37070

e17f13e4ac

[8e963014]

openbravo2678873922.0599.59277.54545

25ca5e8c6a

[77f16cf5]

openbravo2434022901.86100.00262.419221

6e47e0b2e7

[c4153bc0]

openbravo1852237361.4199.26468.72923158332

b76ef6c915

[84cd185c]

openbravo1537925991.1799.79953.893552

b99cde50b0

[980edddc]

openbravo1473967051.1399.54149.12424

d817a62e25

[c297f073]

openbravo1412193261.0898.12173.32323

59ed037ff5

[f51c7e38]

openbravo1314036551.0099.64675.0144516

634a705cf9

[3111e984]

openbravo1310914191.0099.64673.114451445

c180ac6f1a

[2266d068]

openbravo1292888520.9999.64160.459468

416d959161

[fb2a3095]

openbravo1254467280.9673.17619.2126

beb5c816db

[73183df]

openbravo1142264390.8797.29238.766

2fc2aa8125

[3fe437d2]

openbravo1139508680.8798.74292.61080010806

e4b8f19235

[464f8019]

openbravo1105190960.8499.53130.31818

6bc28a65f9

[5494e49a]

openbravo1065396190.8122.97153.19696

Top SQL by shared blocks read

Query IDDatabaseReads%TotalHits(%)Elapsed(s)RowsExecutions

fa1f738bce

[4960efab]

openbravo8218344515.5222.86166.39696

6bc28a65f9

[5494e49a]

openbravo8206791315.4922.97153.19696

4aae53f3da

[5b93a467]

openbravo5567133810.5196.263069.8138

dca3f71473

[f268953e]

openbravo369169996.9798.234569.91505

416d959161

[fb2a3095]

openbravo336624346.3673.17619.2126

6fe43f5091

[94a66f88]

openbravo273819915.1722.9056.13232

33ff47c769

[6fed39e5]

openbravo272953695.1523.1454.23232

6a1bba66a2

[131a43ac]

openbravo136402002.5823.1826.51616

096068c9bd

[d5f8441b]

openbravo136296712.5723.2425.21616

8d2c8e833f

[f9b02264]

openbravo123018602.3298.531924.0322

ec9393c1b5

[2fa4f443]

openbravo111810902.1116.7192.411

6aeca8addc

[e0869ab2]

openbravo79895271.5198.791204.6138

22615c404b

[c1020a32]

openbravo51227540.9763.86192.0341

0a92390e0d

[317531b3]

openbravo43789410.8388.0082.65

781daf8db9

[a28b2b86]

openbravo40165700.760.0024.51

67a75a3409

[7318d810]

openbravo40143740.76344.6380455731

f570d33a96

[57d3e9b9]

openbravo36922950.7081.9794.7132

beb5c816db

[73183df]

openbravo30942060.5897.29238.766

17592c9fe0

[871bdc0f]

openbravo29661010.5625.3830.24

18c54477aa

[5bd4159e]

openbravo27443950.5263.1258.0108

Top SQL by shared blocks dirtied

Query IDDatabaseDirtied%TotalHits(%)Elapsed(s)RowsExecutions

e54b22db57

[8797b6f9]

openbravo44340512.200.0346.41

1266b03316

[cd352352]

openbravo3462419.5263.7141220331

d545a87b3d

[a03a69a5]

openbravo1941555.3497.5833.55748057480

6758866a26

[eb67e33f]

openbravo1387263.8294.9329.68878188781

8d75ee1767

[3695269c]

openbravo1202763.3196.6427.23176531765

7efafc5af2

[74267a2]

openbravo703611.9493.297679.313581358

ff35139986

[a35d3b99]

openbravo703611.9493.297679.413581358

4cb9cc1cbf

[ea4e56b9]

openbravo703611.9493.297679.313581358

2c756b6487

[4211bbca]

openbravo552121.5243.397.71

fec93ea334

[2ff59f28]

openbravo529851.4699.9728.8114053114053

22615c404b

[c1020a32]

openbravo466661.2863.86192.0341

7cdb887c2a

[8f1d721]

openbravo450231.2499.5735.01020510205

26959f7c7a

[d3eb78]

openbravo411521.1391.6117.32008020080

fa5e805d20

[6bdd6481]

openbravo405341.1198.5813.098639863

75890e23a4

[baa0f6d7]

openbravo351170.9799.5822.71116311163

e1739d379d

[6f92ba97]

openbravo337700.939.6886.270275971

101ed24576

[205b8c88]

openbravo329150.9198.376.11125211252

43a80059e4

[bfd8039a]

openbravo277570.7699.352348.2939939

86ae00e408

[12018251]

openbravo276440.7686.926.777257725

d5c8e0e271

[89ff8432]

openbravo275640.7692.773.193559355

Top SQL by shared blocks written

Query IDDatabaseWritten%Total%BackendWHits(%)Elapsed(s)RowsExecutions

2c756b6487

[4211bbca]

openbravo420931.3720.5343.397.71

98d4183d4b

[6ee18a4d]

openbravo131370.436.4148.180.71

ec9393c1b5

[2fa4f443]

openbravo86570.284.2216.7192.411

1c688a8b54

[57e6c62c]

openbravo86570.284.228.8910.61

4aae53f3da

[5b93a467]

openbravo71750.233.5096.263069.8138

214f622e78

[ab56bf1d]

openbravo58710.192.8631.0319.0144

6aeca8addc

[e0869ab2]

openbravo57700.192.8198.791204.6138

8b47e0efaf

[429b2ffc]

openbravo39390.131.9270.610.41

2ce9536368

[76ede534]

openbravo38310.131.8750.790.11

beb5c816db

[73183df]

openbravo37950.121.8597.29238.766

d817a62e25

[c297f073]

openbravo37200.121.8198.12173.32323

30d8811b23

[b9515b09]

openbravo24330.081.190.038.722

09f3a2812f

[2e890cfd]

openbravo20680.071.0191.9489.144

f570d33a96

[57d3e9b9]

openbravo16080.050.7881.9794.7132

6759033aa8

[b6e0892c]

openbravo9600.030.475.834.522

c180ac6f1a

[2266d068]

openbravo9540.030.4799.64160.459468

4dea79c24d

[d87869f1]

openbravo7360.020.3692.8821.922

92c3ea2c6b

[427f2756]

openbravo6150.020.3098.8373.288

d3471812de

[aa92e059]

openbravo5670.020.2894.2614.811

5a62f392ad

[1e5d1bbf]

openbravo5200.020.2591.520.31

Top SQL by temp usage

Query IDDatabaseLocal fetchedHits(%)Local (blk)Temp (blk)Elapsed(s)RowsExecutions
Write%TotalRead%TotalWrite%TotalRead%Total

dca3f71473

[f268953e]

openbravo2787860666.672788294668.364569.91505

8d2c8e833f

[f9b02264]

openbravo1115136426.671115310027.351924.0322

3d36ea61d3

[4b4aa955]

openbravo11948152.8611950012.93201.3323

06ca21d7ba

[744752f]

openbravo9067932.172167690.5342.411

b76ef6c915

[84cd185c]

openbravo1845060.441845360.45953.893552

7e62f3b264

[6e3dad39]

openbravo1231910.29504570.1235.528611

8ec2df7b9d

[6e556c27]

openbravo895990.21366960.0925.82088

f66a111527

[46df0a8e]

openbravo1132320.2790720.028.622

ac7478aac8

[58a0d3d2]

openbravo819770.20257320.061.277

41ebce9415

[5cdbbbc1]

openbravo645760.15183400.0435.76822

4dea79c24d

[d87869f1]

openbravo153550.0476310.0221.922

e1d00b9071

[3ae0446c]

openbravo117110.0336760.010.111

18920cc811

[973920e6]

openbravo16910.0016900.001.72001

b91bad558a

[e0672fcb]

openbravo7726399.1863019.270.37538275382

c057bbbc51

[755dbd6e]

openbravo339098.55491.500.032523252

12af87b05a

[e7ce3860]

openbravo401798.78491.500.038793879

d0c28bf4b2

[1685db89]

openbravo317198.64431.320.030513051

30f874364a

[ad1734cd]

openbravo391398.90431.320.037903790

181bc0438f

[719f22ea]

openbravo265798.49401.220.025462546

69a0cb34e3

[1b4ce26d]

openbravo818199.52391.190.080718071

Complete list of SQL texts

QueryIDQuery Text
26959f7c7ainsert into M_Transaction_Cost (AD_Client_ID, AD_Org_ID, Created, Createdby, Updated, Updatedby, Isactive, M_Transaction_ID, Cost, CostDate, C_Currency_ID, IsUnitCost, DateAcct, M_Transaction_Cost_ID) values ($1, $2, $3, $4, $5, $6, $7, $8, $9, $10, $11, $12, $13, $14)
08c88cedccSELECT $2 FROM ONLY "public"."c_bpartner" x WHERE "c_bpartner_id"::pg_catalog.text OPERATOR(pg_catalog.=) $1::pg_catalog.text FOR KEY SHARE OF x
beb5c816dbselect array_to_string(array_agg(fin_paymen0_.FIN_Payment_Scheduledetail_ID), $12) as col_0_0_, array_to_string(array_agg(order3_.DocumentNo), $13) as col_1_0_, case when invoice7_.IsSOTrx=$14 and (organizati11_.AD_Org_ID is not null) and (organizati11_.EM_Aprm_Payment_Desc like $15) then invoice7_.POReference else invoice7_.DocumentNo end as col_2_0_, coalesce(fin_paymen6_.Fin_Paymentmethod_ID, fin_paymen2_.Fin_Paymentmethod_ID) as col_3_0_, coalesce(fin_paymen9_.Name, fin_paymen5_.Name) as col_4_0_, coalesce(fin_paymen6_.ExpectedDate, fin_paymen2_.ExpectedDate) as col_5_0_, max(coalesce(fin_paymen6_.Amount, fin_paymen2_.Amount)) as col_6_0_, max(coalesce(invoice7_.GrandTotal, $16)) as col_7_0_, businesspa1_.C_BPartner_ID as col_8_0_, businesspa1_.Name as col_9_0_, sum(fin_paymen0_.Amount+fin_paymen0_.Writeoffamt) as col_10_0_, coalesce(sum(fin_paymen12_.Amount), $17) as col_11_0_, case when sum(fin_paymen0_.Writeoffamt)<>$18 then $19 else $20 end as col_12_0_, case when max(fin_paymen13_.Fin_Payment_ID) is not null then $21 else $22 end as col_13_0_ from FIN_Payment_ScheduleDetail fin_paymen0_ inner join C_BPartner businesspa1_ on fin_paymen0_.C_Bpartner_ID=businesspa1_.C_BPartner_ID left outer join FIN_Payment_Schedule fin_paymen2_ on fin_paymen0_.FIN_Payment_Schedule_Order=fin_paymen2_.Fin_Payment_Schedule_ID left outer join C_Order order3_ on fin_paymen2_.C_Order_ID=order3_.C_Order_ID and (order3_.IsSOTrx=$1 and order3_.C_Currency_ID=$2) left outer join FIN_Payment_Priority fin_paymen4_ on fin_paymen2_.FIN_Payment_Priority_ID=fin_paymen4_.FIN_Payment_Priority_ID left outer join FIN_PaymentMethod fin_paymen5_ on fin_paymen2_.Fin_Paymentmethod_ID=fin_paymen5_.Fin_Paymentmethod_ID left outer join FIN_Payment_Schedule fin_paymen6_ on fin_paymen0_.FIN_Payment_Schedule_Invoice=fin_paymen6_.Fin_Payment_Schedule_ID left outer join C_Invoice invoice7_ on fin_paymen6_.C_Invoice_ID=invoice7_.C_Invoice_ID and (invoice7_.IsSOTrx=$3 and invoice7_.C_Currency_ID=$4) left outer join FIN_Payment_Priority fin_paymen8_ on fin_paymen6_.FIN_Payment_Priority_ID=fin_paymen8_.FIN_Payment_Priority_ID left outer join FIN_PaymentMethod fin_paymen9_ on fin_paymen6_.Fin_Paymentmethod_ID=fin_paymen9_.Fin_Paymentmethod_ID left outer join AD_Org organizati10_ on fin_paymen0_.AD_Org_ID=organizati10_.AD_Org_ID left outer join AD_OrgInfo organizati11_ on organizati10_.AD_Org_ID=organizati11_.AD_Org_ID left outer join FIN_Payment_Detail fin_paymen12_ on fin_paymen0_.FIN_Payment_Detail_ID=fin_paymen12_.Fin_Payment_Detail_ID left outer join FIN_Payment fin_paymen13_ on fin_paymen12_.Fin_Payment_ID=fin_paymen13_.Fin_Payment_ID where (fin_paymen0_.AD_Client_ID in ($23 , $5)) and (fin_paymen0_.FIN_Payment_Detail_ID is null or fin_paymen13_.Fin_Payment_ID=$6) and (coalesce(fin_paymen6_.Fin_Payment_Schedule_ID, fin_paymen2_.Fin_Payment_Schedule_ID) is not null) and (fin_paymen0_.AD_Org_ID in ($7)) and (organizati11_.AD_Org_ID is null or organizati11_.IsActive=$24) and invoice7_.IsSOTrx=$8 and invoice7_.C_Currency_ID=$9 group by invoice7_.C_Invoice_ID , invoice7_.DocumentNo , invoice7_.C_DocType_ID , coalesce(fin_paymen6_.Fin_Paymentmethod_ID, fin_paymen2_.Fin_Paymentmethod_ID) , coalesce(fin_paymen9_.Name, fin_paymen5_.Name) , coalesce(fin_paymen6_.ExpectedDate, fin_paymen2_.ExpectedDate) , coalesce(fin_paymen8_.Priority, fin_paymen4_.Priority) , invoice7_.IsSOTrx , organizati11_.AD_Org_ID , organizati11_.EM_Aprm_Payment_Desc , invoice7_.POReference , businesspa1_.C_BPartner_ID , businesspa1_.Name having upper(coalesce(fin_paymen9_.Name, fin_paymen5_.Name)) like upper($10) escape $25 order by case when max(fin_paymen13_.Fin_Payment_ID) is not null then $26 else $27 end, coalesce(fin_paymen8_.Priority, fin_paymen4_.Priority), coalesce(fin_paymen6_.ExpectedDate, fin_paymen2_.ExpectedDate), invoice7_.DocumentNo limit $11
7efafc5af2SELECT C_ORDER_POST1(p_PInstance_ID, $2)
06ca21d7baselect prpass_pas0_.Prpass_Pass_Inst_Hist_ID as Prpass_P1_879_, prpass_pas0_.AD_Client_ID as AD_Clien2_879_, prpass_pas0_.AD_Org_ID as AD_Org_I3_879_, prpass_pas0_.Isactive as Isactive4_879_, prpass_pas0_.Created as Created5_879_, prpass_pas0_.Createdby as Createdb6_879_, prpass_pas0_.Updated as Updated7_879_, prpass_pas0_.Updatedby as Updatedb8_879_, prpass_pas0_.Value as Value9_879_, prpass_pas0_.Status as Status10_879_, prpass_pas0_.C_Orderline_ID as C_Order11_879_, prpass_pas0_.C_Order_ID as C_Order12_879_, prpass_pas0_.Dateordered as Dateord13_879_, prpass_pas0_.C_Bpartner_ID as C_Bpart14_879_, prpass_pas0_.M_Product_ID as M_Produ15_879_, prpass_pas0_.Obpos_Applications_ID as Obpos_A16_879_, prpass_pas0_.Cancel as Cancel17_879_, prpass_pas0_.AD_Creation_Org_ID as AD_Crea18_879_, prpass_pas0_.Expirationdate as Expirat19_879_, prpass_pas0_.Prpass_Timeslots_Detail_ID as Prpass_20_879_, prpass_pas0_.Prpass_Timeslots_Res_ID as Prpass_21_879_, prpass_pas0_.Time_First_Pick as Time_Fi22_879_, prpass_pas0_.Validate_Manual as Validat23_879_, prpass_pas0_.Unlimited as Unlimit24_879_ from prpass_pass_inst_hist prpass_pas0_ where (prpass_pas0_.AD_Org_ID in ($1 , $2 , $3 , $4 , $5 , $6 , $7 , $8 , $9 , $10 , $11 , $12 , $13 , $14 , $15 , $16 , $17 , $18 , $19 , $20 , $21 , $22 , $23 , $24 , $25 , $26 , $27 , $28 , $29 , $30 , $31 , $32 , $33 , $34 , $35 , $36 , $37 , $38)) and (prpass_pas0_.AD_Client_ID in ($39 , $40)) order by prpass_pas0_.Value, prpass_pas0_.Prpass_Pass_Inst_Hist_ID limit $41
7cdb887c2ainsert into M_ProductionLine (AD_Client_ID, AD_Org_ID, IsActive, Created, CreatedBy, Updated, UpdatedBy, M_ProductionPlan_ID, Line, M_Product_ID, MovementQty, M_Locator_ID, M_AttributeSetInstance_ID, C_UOM_ID, Calculated, Rejectedquantity, EM_Cactl_Added_Manually, M_ProductionLine_ID) values ($1, $2, $3, $4, $5, $6, $7, $8, $9, $10, $11, $12, $13, $14, $15, $16, $17, $18)
a46753d96bSELECT $2 FROM ONLY "public"."ad_client" x WHERE "ad_client_id"::pg_catalog.text OPERATOR(pg_catalog.=) $1::pg_catalog.text FOR KEY SHARE OF x
86ae00e408insert into C_OrderLineTax (C_Orderline_ID, C_Tax_ID, AD_Client_ID, AD_Org_ID, Isactive, Created, Createdby, Updated, Updatedby, Taxbaseamt, Taxamt, Line, C_Order_ID, C_Orderlinetax_ID) values ($1, $2, $3, $4, $5, $6, $7, $8, $9, $10, $11, $12, $13, $14)
6a1bba66a2SELECT COUNT(*) AS ID FROM C_OrderLine WHERE Replacedorderline_id = $1 AND EXISTS (SELECT $2 FROM C_Order WHERE C_Order.C_Order_ID = C_OrderLine.C_Order_ID AND C_Order.IsSOTrx=$3 and exists ( select $4 from C_DocType where C_DocType_ID = C_Order.C_DocTypeTarget_ID and isreturn=$5)) AND AD_ORG_ID NOT IN ($6,$7,$8,$9,$10,$11,$12,$13,$14,$15,$16,$17,$18,$19,$20,$21,$22,$23,$24,$25,$26,$27,$28,$29,$30,$31,$32,$33,$34,$35,$36,$37,$38,$39,$40,$41,$42,$43)
d0c28bf4b2insert into ad_context_info (ad_user_id, ad_session_id, processType, processId) values ($1, $2, $3, $4)
69a0cb34e3insert into ad_context_info (ad_user_id, ad_session_id, processType, processId) values ($1, $2, $3, $4)
03a1d4e90cSELECT $2 FROM ONLY "public"."c_currency" x WHERE "c_currency_id"::pg_catalog.text OPERATOR(pg_catalog.=) $1::pg_catalog.text FOR KEY SHARE OF x
5a62f392advacuum analyze AD_PInstance
8a7672d920COMMIT
101ed24576update C_Invoice set Updated=$1, DaysTillDue=$2, LastCalculatedOnDate=$3 where C_Invoice_ID=$4
c180ac6f1aselect businesspa0_.C_BPartner_ID as C_BPartn1_203_, businesspa0_.AD_Client_ID as AD_Clien2_203_, businesspa0_.AD_Org_ID as AD_Org_I3_203_, businesspa0_.IsActive as IsActive4_203_, businesspa0_.Created as Created5_203_, businesspa0_.CreatedBy as CreatedB6_203_, businesspa0_.Updated as Updated7_203_, businesspa0_.UpdatedBy as UpdatedB8_203_, businesspa0_.Value as Value9_203_, businesspa0_.Name as Name10_203_, businesspa0_.Name2 as Name11_203_, businesspa0_.Description as Descrip12_203_, businesspa0_.IsSummary as IsSumma13_203_, businesspa0_.C_BP_Group_ID as C_BP_Gr14_203_, businesspa0_.IsOneTime as IsOneTi15_203_, businesspa0_.IsProspect as IsProsp16_203_, businesspa0_.IsVendor as IsVendo17_203_, businesspa0_.IsCustomer as IsCusto18_203_, businesspa0_.IsEmployee as IsEmplo19_203_, businesspa0_.IsSalesRep as IsSales20_203_, businesspa0_.ReferenceNo as Referen21_203_, businesspa0_.DUNS as DUNS22_203_, businesspa0_.URL as URL23_203_, businesspa0_.AD_Language as AD_Lang24_203_, businesspa0_.TaxID as TaxID25_203_, businesspa0_.IsTaxExempt as IsTaxEx26_203_, businesspa0_.C_InvoiceSchedule_ID as C_Invoi27_203_, businesspa0_.Rating as Rating28_203_, businesspa0_.SalesVolume as SalesVo29_203_, businesspa0_.NumberEmployees as NumberE30_203_, businesspa0_.NAICS as NAICS31_203_, businesspa0_.FirstSale as FirstSa32_203_, businesspa0_.AcqusitionCost as Acqusit33_203_, businesspa0_.PotentialLifeTimeValue as Potenti34_203_, businesspa0_.ActualLifeTimeValue as ActualL35_203_, businesspa0_.ShareOfCustomer as ShareOf36_203_, businesspa0_.PaymentRule as Payment37_203_, businesspa0_.SO_CreditLimit as SO_Cred38_203_, businesspa0_.SO_CreditUsed as SO_Cred39_203_, businesspa0_.C_PaymentTerm_ID as C_Payme40_203_, businesspa0_.M_PriceList_ID as M_Price41_203_, businesspa0_.IsDiscountPrinted as IsDisco42_203_, businesspa0_.SO_Description as SO_Desc43_203_, businesspa0_.POReference as PORefer44_203_, businesspa0_.PaymentRulePO as Payment45_203_, businesspa0_.PO_PriceList_ID as PO_Pric46_203_, businesspa0_.PO_PaymentTerm_ID as PO_Paym47_203_, businesspa0_.DocumentCopies as Documen48_203_, businesspa0_.C_Greeting_ID as C_Greet49_203_, businesspa0_.InvoiceRule as Invoice50_203_, businesspa0_.DeliveryRule as Deliver51_203_, businesspa0_.DeliveryViaRule as Deliver52_203_, businesspa0_.SalesRep_ID as SalesRe53_203_, businesspa0_.BPartner_Parent_ID as BPartne54_203_, businesspa0_.SOCreditStatus as SOCredi55_203_, businesspa0_.AD_Forced_Org_ID as AD_Forc56_203_, businesspa0_.ShowPriceInOrder as ShowPri57_203_, businesspa0_.Invoicegrouping as Invoice58_203_, businesspa0_.FixMonthDay as FixMont59_203_, businesspa0_.FixMonthDay2 as FixMont60_203_, businesspa0_.Fixmonthday3 as Fixmont61_203_, businesspa0_.Isworker as Isworke62_203_, businesspa0_.UPC as UPC63_203_, businesspa0_.C_Salary_Category_ID as C_Salar64_203_, businesspa0_.Invoice_Printformat as Invoice65_203_, businesspa0_.Last_Days as Last_Da66_203_, businesspa0_.PO_Bankaccount_ID as PO_Bank67_203_, businesspa0_.PO_BP_TaxCategory_ID as PO_BP_T68_203_, businesspa0_.PO_Fixmonthday as PO_Fixm69_203_, businesspa0_.PO_Fixmonthday2 as PO_Fixm70_203_, businesspa0_.PO_Fixmonthday3 as PO_Fixm71_203_, businesspa0_.SO_Bankaccount_ID as SO_Bank72_203_, businesspa0_.SO_Bp_Taxcategory_ID as SO_Bp_T73_203_, businesspa0_.Fiscalcode as Fiscalc74_203_, businesspa0_.Isofiscalcode as Isofisc75_203_, businesspa0_.EM_Einv_Einvoice as EM_Einv76_203_, businesspa0_.PO_C_Incoterms_ID as PO_C_In77_203_, businesspa0_.EM_Einv_Format_Id as EM_Einv78_203_, businesspa0_.SO_C_Incoterms_ID as SO_C_In79_203_, businesspa0_.EM_Einv_Platform_Id as EM_Einv80_203_, businesspa0_.FIN_Paymentmethod_ID as FIN_Pay81_203_, businesspa0_.EM_Einv_Email as EM_Einv82_203_, businesspa0_.PO_Paymentmethod_ID as PO_Paym83_203_, businesspa0_.FIN_Financial_Account_ID as FIN_Fin84_203_, businesspa0_.EM_Einv_Deliverymode as EM_Einv85_203_, businesspa0_.PO_Financial_Account_ID as PO_Fina86_203_, businesspa0_.Customer_Blocking as Custome87_203_, businesspa0_.Vendor_Blocking as Vendor_88_203_, businesspa0_.SO_Payment_Blocking as SO_Paym89_203_, businesspa0_.PO_Payment_Blocking as PO_Paym90_203_, businesspa0_.SO_Invoice_Blocking as SO_Invo91_203_, businesspa0_.PO_Invoice_Blocking as PO_Invo92_203_, businesspa0_.SO_Order_Blocking as SO_Orde93_203_, businesspa0_.PO_Order_Blocking as PO_Orde94_203_, businesspa0_.SO_Goods_Blocking as SO_Good95_203_, businesspa0_.PO_Goods_Blocking as PO_Good96_203_, businesspa0_.Iscashvat as Iscashv97_203_, businesspa0_.EM_Advcrm_Newactivity as EM_Advc98_203_, businesspa0_.Update_Currency as Update_99_203_, businesspa0_.BP_Currency_ID as BP_Cur100_203_, businesspa0_.Birthplace as Birthp101_203_, businesspa0_.Birthday as Birthd102_203_, businesspa0_.EM_Sgpcrm_Securitygroups_ID as EM_Sgp103_203_, businesspa0_.Is_Customer_Consent as Is_Cus104_203_, businesspa0_.EM_OBSMAIL_INVOICEVIAEMAIL as EM_OBS105_203_, businesspa0_.EM_Obsepad_Mandate_Identifier as EM_Obs106_203_, businesspa0_.EM_Obsmail_Language as EM_Obs107_203_, businesspa0_.EM_Obsepad_Mandate_Date as EM_Obs108_203_, businesspa0_.EM_Aeatsii_Rep_Taxid as EM_Aea109_203_, businesspa0_.EM_Aeatsii_Menor as EM_Aea110_203_, businesspa0_.EM_Pricm_Isintercompany as EM_Pri111_203_, businesspa0_.EM_Psat_Billtobpartner_ID as EM_Psa112_203_, businesspa0_.EM_Psat_Locator_ID as EM_Psa113_203_, businesspa0_.EM_Psat_Mobile_Request as EM_Psa114_203_, businesspa0_.EM_Prges_Glitem_ID as EM_Prg115_203_, businesspa0_.EM_Rrhh_Exemployee as EM_Rrh116_203_, businesspa0_.EM_Rrhh_Candidate as EM_Rrh117_203_, businesspa0_.EM_Prpass_No_Print_Pass as EM_Prp118_203_, businesspa0_.EM_Rrhh_Holidays_Supervisor as EM_Rrh119_203_, businesspa0_.EM_Cactal_Emp_No as EM_Cac120_203_, businesspa0_.EM_Cactal_Emp_Relationship_No as EM_Cac121_203_, businesspa0_.EM_Obwpl_Bp_Block_Pickinglist as EM_Obw122_203_, businesspa0_.EM_Pruti_Addbp as EM_Pru123_203_, businesspa0_.EM_Prpass_Generatepassemployee as EM_Prp124_203_, businesspa0_.EM_Rrhh_Mainworkstation_ID as EM_Rrh125_203_, businesspa0_.EM_Rrhh_Bp_Transfer_Code as EM_Rrh126_203_, businesspa0_.EM_OBTIK_Tax_ID_Key as EM_OBT127_203_ from C_BPartner businesspa0_ where (upper((businesspa0_.Value||$3||businesspa0_.Name||$4||coalesce(to_char(businesspa0_.TaxID), $5)||$6||coalesce(to_char(businesspa0_.Name2), $7))) like upper($1) escape $8) and (exists (select $9 from C_Order order1_ inner join C_BPartner businesspa2_ on order1_.C_BPartner_ID=businesspa2_.C_BPartner_ID cross join C_DocType documentty3_ where order1_.C_DocTypeTarget_ID=documentty3_.C_DocType_ID and order1_.IsSOTrx=$10 and documentty3_.IsReturn=$11 and businesspa2_.C_BPartner_ID=businesspa0_.C_BPartner_ID and (order1_.AD_Org_ID in ($12 , $13 , $14 , $15 , $16 , $17 , $18 , $19 , $20 , $21 , $22 , $23 , $24 , $25 , $26 , $27 , $28 , $29 , $30 , $31 , $32 , $33 , $34 , $35 , $36 , $37 , $38 , $39 , $40 , $41 , $42 , $43 , $44 , $45 , $46 , $47 , $48 , $49)) and (order1_.AD_Client_ID in ($50 , $51)))) order by businesspa0_.Value, businesspa0_.Name, businesspa0_.TaxID, businesspa0_.Name2 limit $2
496be14648select array_to_string(array_agg(fin_paymen0_.FIN_Payment_Scheduledetail_ID), $15) as col_0_0_, array_to_string(array_agg(order3_.DocumentNo), $16) as col_1_0_, case when invoice7_.IsSOTrx=$17 and (organizati11_.AD_Org_ID is not null) and (organizati11_.EM_Aprm_Payment_Desc like $18) then invoice7_.POReference else invoice7_.DocumentNo end as col_2_0_, coalesce(fin_paymen6_.Fin_Paymentmethod_ID, fin_paymen2_.Fin_Paymentmethod_ID) as col_3_0_, coalesce(fin_paymen9_.Name, fin_paymen5_.Name) as col_4_0_, coalesce(fin_paymen6_.ExpectedDate, fin_paymen2_.ExpectedDate) as col_5_0_, max(coalesce(fin_paymen6_.Amount, fin_paymen2_.Amount)) as col_6_0_, max(coalesce(invoice7_.GrandTotal, $19)) as col_7_0_, businesspa1_.C_BPartner_ID as col_8_0_, businesspa1_.Name as col_9_0_, sum(fin_paymen0_.Amount+fin_paymen0_.Writeoffamt) as col_10_0_, coalesce(sum(fin_paymen12_.Amount), $20) as col_11_0_, case when sum(fin_paymen0_.Writeoffamt)<>$21 then $22 else $23 end as col_12_0_, case when max(fin_paymen13_.Fin_Payment_ID) is not null then $24 else $25 end as col_13_0_ from FIN_Payment_ScheduleDetail fin_paymen0_ inner join C_BPartner businesspa1_ on fin_paymen0_.C_Bpartner_ID=businesspa1_.C_BPartner_ID left outer join FIN_Payment_Schedule fin_paymen2_ on fin_paymen0_.FIN_Payment_Schedule_Order=fin_paymen2_.Fin_Payment_Schedule_ID left outer join C_Order order3_ on fin_paymen2_.C_Order_ID=order3_.C_Order_ID and (order3_.IsSOTrx=$1 and order3_.C_Currency_ID=$2) left outer join FIN_Payment_Priority fin_paymen4_ on fin_paymen2_.FIN_Payment_Priority_ID=fin_paymen4_.FIN_Payment_Priority_ID left outer join FIN_PaymentMethod fin_paymen5_ on fin_paymen2_.Fin_Paymentmethod_ID=fin_paymen5_.Fin_Paymentmethod_ID left outer join FIN_Payment_Schedule fin_paymen6_ on fin_paymen0_.FIN_Payment_Schedule_Invoice=fin_paymen6_.Fin_Payment_Schedule_ID left outer join C_Invoice invoice7_ on fin_paymen6_.C_Invoice_ID=invoice7_.C_Invoice_ID and (invoice7_.IsSOTrx=$3 and invoice7_.C_Currency_ID=$4) left outer join FIN_Payment_Priority fin_paymen8_ on fin_paymen6_.FIN_Payment_Priority_ID=fin_paymen8_.FIN_Payment_Priority_ID left outer join FIN_PaymentMethod fin_paymen9_ on fin_paymen6_.Fin_Paymentmethod_ID=fin_paymen9_.Fin_Paymentmethod_ID left outer join AD_Org organizati10_ on fin_paymen0_.AD_Org_ID=organizati10_.AD_Org_ID left outer join AD_OrgInfo organizati11_ on organizati10_.AD_Org_ID=organizati11_.AD_Org_ID left outer join FIN_Payment_Detail fin_paymen12_ on fin_paymen0_.FIN_Payment_Detail_ID=fin_paymen12_.Fin_Payment_Detail_ID left outer join FIN_Payment fin_paymen13_ on fin_paymen12_.Fin_Payment_ID=fin_paymen13_.Fin_Payment_ID where (fin_paymen0_.AD_Client_ID in ($26 , $5)) and (fin_paymen0_.FIN_Payment_Detail_ID is null or fin_paymen13_.Fin_Payment_ID=$6) and (coalesce(fin_paymen6_.Fin_Payment_Schedule_ID, fin_paymen2_.Fin_Payment_Schedule_ID) is not null) and (fin_paymen0_.AD_Org_ID in ($7)) and (organizati11_.AD_Org_ID is null or organizati11_.IsActive=$27) and invoice7_.IsSOTrx=$8 and invoice7_.C_Currency_ID=$9 group by invoice7_.C_Invoice_ID , invoice7_.DocumentNo , invoice7_.C_DocType_ID , coalesce(fin_paymen6_.Fin_Paymentmethod_ID, fin_paymen2_.Fin_Paymentmethod_ID) , coalesce(fin_paymen9_.Name, fin_paymen5_.Name) , coalesce(fin_paymen6_.ExpectedDate, fin_paymen2_.ExpectedDate) , coalesce(fin_paymen8_.Priority, fin_paymen4_.Priority) , invoice7_.IsSOTrx , organizati11_.AD_Org_ID , organizati11_.EM_Aprm_Payment_Desc , invoice7_.POReference , businesspa1_.C_BPartner_ID , businesspa1_.Name having (upper(coalesce(fin_paymen9_.Name, fin_paymen5_.Name)) like upper($10) escape $28) and coalesce(fin_paymen6_.ExpectedDate, fin_paymen2_.ExpectedDate)>=$11 and coalesce(fin_paymen6_.ExpectedDate, fin_paymen2_.ExpectedDate)<=$12 order by case when max(fin_paymen13_.Fin_Payment_ID) is not null then $29 else $30 end, coalesce(fin_paymen8_.Priority, fin_paymen4_.Priority), coalesce(fin_paymen6_.ExpectedDate, fin_paymen2_.ExpectedDate), invoice7_.DocumentNo limit $13 offset $14
9a0540688dSELECT LEVELNO FROM AD_ORG_TREE WHERE AD_ORG_ID = p_orgid AND AD_PARENT_ORG_ID = p_parentorgid AND AD_CLIENT_ID = p_clientid
f2e5c3fd88SELECT $2 FROM ONLY "public"."m_product" x WHERE "m_product_id"::pg_catalog.text OPERATOR(pg_catalog.=) $1::pg_catalog.text FOR KEY SHARE OF x
09f3a2812fselect invoice0_.C_Invoice_ID as C_Invoic1_260_, invoice0_.AD_Client_ID as AD_Clien2_260_, invoice0_.AD_Org_ID as AD_Org_I3_260_, invoice0_.IsActive as IsActive4_260_, invoice0_.Created as Created5_260_, invoice0_.CreatedBy as CreatedB6_260_, invoice0_.Updated as Updated7_260_, invoice0_.UpdatedBy as UpdatedB8_260_, invoice0_.IsSOTrx as IsSOTrx9_260_, invoice0_.DocumentNo as Documen10_260_, invoice0_.DocStatus as DocStat11_260_, invoice0_.DocAction as DocActi12_260_, invoice0_.Processing as Process13_260_, invoice0_.Processed as Process14_260_, invoice0_.Posted as Posted15_260_, invoice0_.C_DocType_ID as C_DocTy16_260_, invoice0_.C_DocTypeTarget_ID as C_DocTy17_260_, invoice0_.C_Order_ID as C_Order18_260_, invoice0_.Description as Descrip19_260_, invoice0_.IsPrinted as IsPrint20_260_, invoice0_.SalesRep_ID as SalesRe21_260_, invoice0_.DateInvoiced as DateInv22_260_, invoice0_.DatePrinted as DatePri23_260_, invoice0_.DateAcct as DateAcc24_260_, invoice0_.C_BPartner_ID as C_BPart25_260_, invoice0_.C_BPartner_Location_ID as C_BPart26_260_, invoice0_.POReference as PORefer27_260_, invoice0_.IsDiscountPrinted as IsDisco28_260_, invoice0_.DateOrdered as DateOrd29_260_, invoice0_.C_Currency_ID as C_Curre30_260_, invoice0_.C_PaymentTerm_ID as C_Payme31_260_, invoice0_.C_Charge_ID as C_Charg32_260_, invoice0_.ChargeAmt as ChargeA33_260_, invoice0_.TotalLines as TotalLi34_260_, invoice0_.GrandTotal as GrandTo35_260_, invoice0_.M_PriceList_ID as M_Price36_260_, invoice0_.IsTaxIncluded as IsTaxIn37_260_, invoice0_.C_Campaign_ID as C_Campa38_260_, invoice0_.C_Project_ID as C_Proje39_260_, invoice0_.C_Activity_ID as C_Activ40_260_, invoice0_.CreateFrom as CreateF41_260_, invoice0_.GenerateTo as Generat42_260_, invoice0_.AD_User_ID as AD_User43_260_, invoice0_.CopyFrom as CopyFro44_260_, invoice0_.IsSelfService as IsSelfS45_260_, invoice0_.AD_OrgTrx_ID as AD_OrgT46_260_, invoice0_.User1_ID as User47_260_, invoice0_.User2_ID as User48_260_, invoice0_.Withholdingamount as Withhol49_260_, invoice0_.Taxdate as Taxdate50_260_, invoice0_.C_Withholding_ID as C_Withh51_260_, invoice0_.Ispaid as Ispaid52_260_, invoice0_.EM_Einv_Generated as EM_Einv53_260_, invoice0_.Totalpaid as Totalpa54_260_, invoice0_.EM_Einv_Sent as EM_Einv55_260_, invoice0_.OutstandingAmt as Outstan56_260_, invoice0_.DaysTillDue as DaysTil57_260_, invoice0_.DueAmt as DueAmt58_260_, invoice0_.LastCalculatedOnDate as LastCal59_260_, invoice0_.FIN_Paymentmethod_ID as FIN_Pay60_260_, invoice0_.FIN_Payment_Priority_ID as FIN_Pay61_260_, invoice0_.Finalsettlement as Finalse62_260_, invoice0_.Daysoutstanding as Daysout63_260_, invoice0_.Percentageoverdue as Percent64_260_, invoice0_.C_Costcenter_ID as C_Costc65_260_, invoice0_.Calculate_Promotions as Calcula66_260_, invoice0_.A_Asset_ID as A_Asset67_260_, invoice0_.EM_APRM_Addpayment as EM_APRM68_260_, invoice0_.Iscashvat as Iscashv69_260_, invoice0_.EM_APRM_Processinvoice as EM_APRM70_260_, invoice0_.EM_Obcma_C_Poc_Email_ID as EM_Obcm71_260_, invoice0_.Prepaymentamt as Prepaym72_260_, invoice0_.Createfromorders as Createf73_260_, invoice0_.Createfrominouts as Createf74_260_, invoice0_.EM_Advcrm_Newactivity as EM_Advc75_260_, invoice0_.Paidamtatinvoicing as Paidamt76_260_, invoice0_.EM_Obpos_Rounding_Amount as EM_Obpo77_260_, invoice0_.EM_Sgpcrm_Securitygroups_ID as EM_Sgpc78_260_, invoice0_.BPartner_ExtRef as BPartne79_260_, invoice0_.EM_Aeatsii_Send as EM_Aeat80_260_, invoice0_.EM_Obpos_Sequencename as EM_Obpo81_260_, invoice0_.EM_Aeatsii_Issent as EM_Aeat82_260_, invoice0_.EM_Obpos_Sequencenumber as EM_Obpo83_260_, invoice0_.EM_Aeatsii_Fecha_Operacion as EM_Aeat84_260_, invoice0_.EM_Aeatsii_Clave_Tipo as EM_Aeat85_260_, invoice0_.EM_Aeatsii_Motivo_Rectif as EM_Aeat86_260_, invoice0_.EM_Prouti_Recalculate_Price as EM_Prou87_260_, invoice0_.EM_Aeatsii_Clave_Tipo_Fc as EM_Aeat88_260_, invoice0_.EM_Ml_Select_Product as EM_Ml_S89_260_, invoice0_.EM_Prouti_Pricecalculatetdate as EM_Prou90_260_, invoice0_.EM_Aeatsii_Tipo_Rectif as EM_Aeat91_260_, invoice0_.EM_Prouti_Totalizations as EM_Prou92_260_, invoice0_.EM_Aeatsii_Dua as EM_Aeat93_260_, invoice0_.EM_Aeatsii_Fecha_Dua as EM_Aeat94_260_, invoice0_.EM_Aeatsii_Estado as EM_Aeat95_260_, invoice0_.EM_Aeatsii_Error_Registral as EM_Aeat96_260_, invoice0_.EM_Aeatsii_Modif as EM_Aeat97_260_, invoice0_.EM_Aeatsii_Modified as EM_Aeat98_260_, invoice0_.EM_Aeatsii_Description_ID as EM_Aeat99_260_, invoice0_.EM_Aeatsii_Descripcion_Sii as EM_Aea100_260_, invoice0_.EM_Aeatsii_Fecha_Reg_Cont as EM_Aea101_260_, invoice0_.EM_Aeatsii_Dup as EM_Aea102_260_, invoice0_.EM_Aeatsii_Error_Code as EM_Aea103_260_, invoice0_.EM_Aeatsii_Error_Msg as EM_Aea104_260_, invoice0_.EM_Aeatsii_Unsubscribe as EM_Aea105_260_, invoice0_.EM_Aeatsii_Pur_Description_ID as EM_Aea106_260_, invoice0_.EM_Aeatsii_Multi_Dua as EM_Aea107_260_, invoice0_.EM_Aeatsii_Ejercicio as EM_Aea108_260_, invoice0_.EM_Aeatsii_Periodo as EM_Aea109_260_, invoice0_.EM_Aeatsii_Autofactura as EM_Aea110_260_, invoice0_.EM_Aeatsii_Invoice_ID as EM_Aea111_260_, invoice0_.EM_Aeatsii_Insiidate as EM_Aea112_260_, invoice0_.EM_Aeatsii_Cause_Exemption_ID as EM_Aea113_260_, invoice0_.EM_Aeatsii_Isauthorization as EM_Aea114_260_, invoice0_.EM_Aeatsii_Authorizationno as EM_Aea115_260_, invoice0_.EM_Priuti_Createpurchinv as EM_Pri116_260_, invoice0_.EM_Priuti_Generated as EM_Pri117_260_, invoice0_.EM_Priuti_Date_Complete as EM_Pri118_260_, invoice0_.EM_Prges_Expediente_ID as EM_Prg119_260_, invoice0_.EM_Priuti_User_Complete_ID as EM_Pri120_260_, invoice0_.EM_Prges_Annotation_ID as EM_Prg121_260_, invoice0_.EM_Prges_Record_Number as EM_Prg122_260_, invoice0_.EM_Priuti_Status_Of_Review as EM_Pri123_260_, invoice0_.EM_Prges_Grantotal as EM_Prg124_260_, invoice0_.EM_Priuti_Validate as EM_Pri125_260_, invoice0_.EM_Priuti_Start_Review as EM_Pri126_260_, invoice0_.EM_Prges_Poreference as EM_Prg127_260_, invoice0_.em_cactl_createfromship as em_cac128_260_ from C_Invoice invoice0_ where invoice0_.IsSOTrx=$42 and invoice0_.DocStatus<>$43 and (invoice0_.AD_Org_ID in ($1 , $2 , $3 , $4 , $5 , $6 , $7 , $8 , $9 , $10 , $11 , $12 , $13 , $14 , $15 , $16 , $17 , $18 , $19 , $20 , $21 , $22 , $23 , $24 , $25 , $26 , $27 , $28 , $29 , $30 , $31 , $32 , $33 , $34 , $35 , $36 , $37 , $38)) and (invoice0_.AD_Client_ID in ($39 , $40)) order by invoice0_.DateInvoiced desc, invoice0_.C_Invoice_ID desc limit $41
ec9393c1b5delete from C_UOM where C_UOM_ID=$1
fec93ea334UPDATE M_STORAGE_DETAIL SET QTYONHAND=QTYONHAND + COALESCE(p_qty, $20), QTYORDERONHAND=QTYORDERONHAND + v_qtyorder, DATELASTINVENTORY=COALESCE(p_datelastinventory, DATELASTINVENTORY), PREQTYONHAND=PREQTYONHAND + COALESCE(p_preqty, $21), PREQTYORDERONHAND=PREQTYORDERONHAND + v_preqtyorder, AD_CLIENT_ID=p_client, UPDATED=TO_DATE(NOW()), UPDATEDBY=p_user WHERE M_PRODUCT_ID=p_product AND M_LOCATOR_ID=p_locator AND M_ATTRIBUTESETINSTANCE_ID=v_attributesetinstance AND C_UOM_ID=p_uom AND COALESCE(M_PRODUCT_UOM_ID, $22)=COALESCE(p_product_uom, $23)
b93f3a3e02select count(*) as y0_ from AD_TreeNode this_ where this_.Node_ID=$1 and this_.Parent_ID<>$2 and this_.IsActive=$3
634a705cf9WITH orders AS ( SELECT SUM(ol.qtyordered) AS total FROM c_orderline ol JOIN c_order o ON o.c_order_id = ol.c_order_id WHERE ol.m_product_id = p_product AND o.ad_org_id = p_org AND o.issotrx = $6 AND o.dateordered BETWEEN current_date - v_days_consum AND current_date - $7 ), production AS ( SELECT SUM(pl.movementqty) AS total FROM m_productionline pl JOIN m_productionplan pp ON pp.m_productionplan_id = pl.m_productionplan_id JOIN m_production p ON p.m_production_id = pp.m_production_id WHERE pl.m_product_id = p_product AND pl.ad_org_id = p_org AND p.movementdate BETWEEN current_date - v_days_consum AND current_date - $8 ) SELECT COALESCE(orders.total, $9) + COALESCE(production.total, $10) FROM orders, production
0a92390e0dselect invoice0_.DocumentNo as col_0_0_, businesspa2_.Name as col_1_0_, invoice0_.DateInvoiced as col_2_0_, organizati3_.Name as col_3_0_, adlisttrl1_.Name as col_4_0_ from C_Invoice invoice0_ cross join C_BPartner businesspa2_ cross join AD_Org organizati3_ cross join AD_Ref_List_Trl adlisttrl1_ cross join AD_Ref_List adlist4_ where invoice0_.C_BPartner_ID=businesspa2_.C_BPartner_ID and invoice0_.AD_Org_ID=organizati3_.AD_Org_ID and adlisttrl1_.AD_Ref_List_ID=adlist4_.AD_Ref_List_ID and invoice0_.EM_Priuti_Status_Of_Review<>$4 and adlist4_.Value=invoice0_.EM_Priuti_Status_Of_Review and adlist4_.AD_Reference_ID=$5 and adlisttrl1_.AD_Language=$1 and ($2 in (select priuti_inv6_.AD_User_ID from priuti_invoice_reviewers priuti_inv6_ where priuti_inv6_.C_Invoice_ID=invoice0_.C_Invoice_ID and (priuti_inv6_.Sequence in (select coalesce(min(priuti_inv7_.Sequence), $6) from priuti_invoice_reviewers priuti_inv7_ where priuti_inv7_.C_Invoice_ID=invoice0_.C_Invoice_ID and (priuti_inv7_.Result is null))))) limit $3
af4ce1b038SELECT aprm_gen_paymentschedule_inv($1) FROM DUAL
8d75ee1767INSERT INTO Fact_Acct (Fact_Acct_ID,AD_Client_ID,AD_Org_ID,IsActive,Created,CreatedBy,Updated,UpdatedBy, C_AcctSchema_ID,Account_ID, AcctValue, AcctDescription,DateTrx,DateAcct, C_Period_ID,AD_Table_ID,Record_ID,Line_ID, GL_Category_ID,C_Tax_ID,PostingType,C_Currency_ID, AmtSourceDR,AmtSourceCR,AmtAcctDR,AmtAcctCR, C_UOM_ID,Qty,M_Locator_ID,M_Product_ID,C_BPartner_ID,AD_OrgTrx_ID,C_LocFrom_ID,C_LocTo_ID,C_SalesRegion_ID, C_Project_ID,C_Campaign_ID,C_Activity_ID,User1_ID,User2_ID,Description, Fact_Acct_Group_ID, SeqNo, DocBaseType, Record_ID2, A_ASSET_ID, C_WithHolding_ID, C_DocType_ID, C_Costcenter_ID, FACTACCTTYPE) VALUES ($1, $2, $3,$48,now(),$4,now(),$5, $6, $7, $8, $9, TO_DATE($10), TO_DATE($11), $12, $13, $14, $15, $16, $17, $18, $19, TO_NUMBER($20), TO_NUMBER($21), TO_NUMBER($22), TO_NUMBER($23), $24, TO_NUMBER($25), $26,$27, $28, $29,$30, $31, $32,$33, $34, $35,$36, $37, $38, $39, TO_NUMBER($40), $41, $42, $43, $44, $45, $46, $47)
e1d00b9071select prges_reco0_.Prges_Records_ID as Prges_Re1_831_, prges_reco0_.AD_Client_ID as AD_Clien2_831_, prges_reco0_.AD_Org_ID as AD_Org_I3_831_, prges_reco0_.Created as Created4_831_, prges_reco0_.Createdby as Createdb5_831_, prges_reco0_.Updated as Updated6_831_, prges_reco0_.Updatedby as Updatedb7_831_, prges_reco0_.Isactive as Isactive8_831_, prges_reco0_.Action as Action9_831_, prges_reco0_.Url as Url10_831_, prges_reco0_.Jsoninfo as Jsoninf11_831_, prges_reco0_.Error as Error12_831_, prges_reco0_.Process as Process13_831_, prges_reco0_.Status as Status14_831_, prges_reco0_.C_Invoice_ID as C_Invoi15_831_, prges_reco0_.Prges_Config_ID as Prges_C16_831_ from prges_records prges_reco0_ where prges_reco0_.Prges_Config_ID=$1 and (prges_reco0_.AD_Org_ID in ($2 , $3 , $4 , $5 , $6 , $7 , $8 , $9 , $10 , $11 , $12 , $13 , $14 , $15 , $16 , $17 , $18 , $19 , $20 , $21 , $22 , $23 , $24 , $25 , $26 , $27 , $28 , $29 , $30 , $31 , $32 , $33 , $34 , $35 , $36 , $37 , $38 , $39)) and (prges_reco0_.AD_Client_ID in ($40 , $41)) order by prges_reco0_.Created desc, prges_reco0_.Prges_Records_ID desc limit $42 offset $43
2fc2aa8125select materialmg0_.M_Costing_ID as M_Costin1_453_, materialmg0_.Created as Created2_453_, materialmg0_.Createdby as Createdb3_453_, materialmg0_.Updated as Updated4_453_, materialmg0_.Updatedby as Updatedb5_453_, materialmg0_.AD_Client_ID as AD_Clien6_453_, materialmg0_.AD_Org_ID as AD_Org_I7_453_, materialmg0_.M_Product_ID as M_Produc8_453_, materialmg0_.DateFrom as DateFrom9_453_, materialmg0_.DateTo as DateTo10_453_, materialmg0_.IsManual as IsManua11_453_, materialmg0_.C_InvoiceLine_ID as C_Invoi12_453_, materialmg0_.Qty as Qty13_453_, materialmg0_.Price as Price14_453_, materialmg0_.Cumstock as Cumstoc15_453_, materialmg0_.Costtype as Costtyp16_453_, materialmg0_.Ispermanent as Isperma17_453_, materialmg0_.Cost as Cost18_453_, materialmg0_.Cumcost as Cumcost19_453_, materialmg0_.Isproduction as Isprodu20_453_, materialmg0_.Isactive as Isactiv21_453_, materialmg0_.M_Warehouse_ID as M_Wareh22_453_, materialmg0_.M_Transaction_ID as M_Trans23_453_, materialmg0_.C_Currency_ID as C_Curre24_453_, materialmg0_.Originalcost as Origina25_453_ from M_Costing materialmg0_ where materialmg0_.M_Product_ID=$1 and materialmg0_.DateFrom<=$2 and materialmg0_.Costtype='AVA' and (materialmg0_.Cost is not null) and (materialmg0_.Cumstock is not null) and (materialmg0_.Cumcost is not null) and (materialmg0_.M_Warehouse_ID is null) and materialmg0_.AD_Org_ID=$3 and (materialmg0_.AD_Client_ID in ($4 , $5)) and materialmg0_.Isactive='Y' order by materialmg0_.DateFrom desc, materialmg0_.DateTo desc, materialmg0_.Created desc limit $6
2c756b6487vacuum analyze obmobc_logclient
92c3ea2c6bselect sum(order0_.GrandTotal) as col_0_0_ from C_Order order0_ cross join C_DocType documentty1_ where order0_.C_DocTypeTarget_ID=documentty1_.C_DocType_ID and order0_.IsSOTrx=$43 and documentty1_.IsReturn=$44 and (order0_.Updated>$1 or order0_.Processed=$45) and (order0_.AD_Org_ID in ($2 , $3 , $4 , $5 , $6 , $7 , $8 , $9 , $10 , $11 , $12 , $13 , $14 , $15 , $16 , $17 , $18 , $19 , $20 , $21 , $22 , $23 , $24 , $25 , $26 , $27 , $28 , $29 , $30 , $31 , $32 , $33 , $34 , $35 , $36 , $37 , $38 , $39)) and (order0_.AD_Client_ID in ($40 , $41)) limit $42
8b47e0efafvacuum analyze M_Stock_Proposed
e4b8f19235select order0_.C_Order_ID as C_Order_1_276_, order0_.AD_Client_ID as AD_Clien2_276_, order0_.AD_Org_ID as AD_Org_I3_276_, order0_.IsActive as IsActive4_276_, order0_.Created as Created5_276_, order0_.CreatedBy as CreatedB6_276_, order0_.Updated as Updated7_276_, order0_.UpdatedBy as UpdatedB8_276_, order0_.IsSOTrx as IsSOTrx9_276_, order0_.DocumentNo as Documen10_276_, order0_.DocStatus as DocStat11_276_, order0_.DocAction as DocActi12_276_, order0_.Processing as Process13_276_, order0_.Processed as Process14_276_, order0_.C_DocType_ID as C_DocTy15_276_, order0_.C_DocTypeTarget_ID as C_DocTy16_276_, order0_.Description as Descrip17_276_, order0_.IsDelivered as IsDeliv18_276_, order0_.IsInvoiced as IsInvoi19_276_, order0_.IsPrinted as IsPrint20_276_, order0_.IsSelected as IsSelec21_276_, order0_.SalesRep_ID as SalesRe22_276_, order0_.DateOrdered as DateOrd23_276_, order0_.DatePromised as DatePro24_276_, order0_.DatePrinted as DatePri25_276_, order0_.DateAcct as DateAcc26_276_, order0_.C_BPartner_ID as C_BPart27_276_, order0_.BillTo_ID as BillTo_28_276_, order0_.C_BPartner_Location_ID as C_BPart29_276_, order0_.POReference as PORefer30_276_, order0_.IsDiscountPrinted as IsDisco31_276_, order0_.C_Currency_ID as C_Curre32_276_, order0_.PaymentRule as Payment33_276_, order0_.C_PaymentTerm_ID as C_Payme34_276_, order0_.InvoiceRule as Invoice35_276_, order0_.DeliveryRule as Deliver36_276_, order0_.FreightCostRule as Freight37_276_, order0_.FreightAmt as Freight38_276_, order0_.DeliveryViaRule as Deliver39_276_, order0_.M_Shipper_ID as M_Shipp40_276_, order0_.C_Charge_ID as C_Charg41_276_, order0_.ChargeAmt as ChargeA42_276_, order0_.PriorityRule as Priorit43_276_, order0_.TotalLines as TotalLi44_276_, order0_.GrandTotal as GrandTo45_276_, order0_.M_Warehouse_ID as M_Wareh46_276_, order0_.M_PriceList_ID as M_Price47_276_, order0_.IsTaxIncluded as IsTaxIn48_276_, order0_.C_Campaign_ID as C_Campa49_276_, order0_.C_Project_ID as C_Proje50_276_, order0_.C_Activity_ID as C_Activ51_276_, order0_.Posted as Posted52_276_, order0_.AD_User_ID as AD_User53_276_, order0_.CopyFrom as CopyFro54_276_, order0_.DropShip_BPartner_ID as DropShi55_276_, order0_.DropShip_Location_ID as DropShi56_276_, order0_.DropShip_User_ID as DropShi57_276_, order0_.IsSelfService as IsSelfS58_276_, order0_.AD_OrgTrx_ID as AD_OrgT59_276_, order0_.User1_ID as User60_276_, order0_.User2_ID as User61_276_, order0_.Deliverynotes as Deliver62_276_, order0_.C_Incoterms_ID as C_Incot63_276_, order0_.Incotermsdescription as Incoter64_276_, order0_.Generatetemplate as Generat65_276_, order0_.Delivery_Location_ID as Deliver66_276_, order0_.CopyFromPO as CopyFro67_276_, order0_.FIN_Paymentmethod_ID as FIN_Pay68_276_, order0_.FIN_Payment_Priority_ID as FIN_Pay69_276_, order0_.RM_PickFromShipment as RM_Pick70_276_, order0_.RM_ReceiveMaterials as RM_Rece71_276_, order0_.EM_Obcma_C_Poc_Email_ID as EM_Obcm72_276_, order0_.RM_CreateInvoice as RM_Crea73_276_, order0_.C_Return_Reason_ID as C_Retur74_276_, order0_.RM_AddOrphanLine as RM_AddO75_276_, order0_.A_Asset_ID as A_Asset76_276_, order0_.Calculate_Promotions as Calcula77_276_, order0_.C_Costcenter_ID as C_Costc78_276_, order0_.Convertquotation as Convert79_276_, order0_.C_Reject_Reason_ID as C_Rejec80_276_, order0_.validuntil as validun81_276_, order0_.Quotation_ID as Quotati82_276_, order0_.SO_Res_Status as SO_Res_83_276_, order0_.Create_POLines as Create_84_276_, order0_.EM_Obdisc_Addpack as EM_Obdi85_276_, order0_.Iscashvat as Iscashv86_276_, order0_.EM_OBMFM_Selectfreight as EM_OBMF87_276_, order0_.EM_OBMFM_Delivery_Period_ID as EM_OBMF88_276_, order0_.RM_Pickfromreceipt as RM_Pick89_276_, order0_.Cancelandreplace as Cancela90_276_, order0_.EM_Advcrm_Newactivity as EM_Advc91_276_, order0_.EM_APRM_AddPayment as EM_APRM92_276_, order0_.EM_OBMFM_Delivery_Charges as EM_OBMF93_276_, order0_.EM_OBMFM_Freight_ID as EM_OBMF94_276_, order0_.EM_Obwpl_Generatepicking as EM_Obwp95_276_, order0_.EM_Advcrm_Opportunity_ID as EM_Advc96_276_, order0_.EM_OBMFM_Weight as EM_OBMF97_276_, order0_.EM_Obwpl_Isinpickinglist as EM_Obwp98_276_, order0_.EM_Rcinv_Contractdate as EM_Rcin99_276_, order0_.EM_Obwpl_Readypl as EM_Obw100_276_, order0_.EM_Rcinv_Initialdate as EM_Rci101_276_, order0_.EM_Rcinv_Enddate as EM_Rci102_276_, order0_.EM_Sgpcrm_Securitygroups_ID as EM_Sgp103_276_, order0_.EM_OBMFM_Weight_Uom_ID as EM_OBM104_276_, order0_.EM_Rcinv_Frequency as EM_Rci105_276_, order0_.EM_OBMFM_Set_Weight as EM_OBM106_276_, order0_.EM_Rcinv_Renewautomatically as EM_Rci107_276_, order0_.EM_Aeatsii_Fecha_Operacion as EM_Aea108_276_, order0_.EM_Ml_Select_Product as EM_Ml_109_276_, order0_.EM_Rcinv_Renovationtimes as EM_Rci110_276_, order0_.Confirmcancelandreplace as Confir111_276_, order0_.EM_Aeatsii_Descripcion_Sii as EM_Aea112_276_, order0_.EM_Obpos_Applications_ID as EM_Obp113_276_, order0_.EM_Rcinv_Freqrenovationtime as EM_Rci114_276_, order0_.EM_Obpos_Sendemail as EM_Obp115_276_, order0_.EM_Rcinv_Ordercontract_ID as EM_Rci116_276_, order0_.EM_Obpos_Email_Status as EM_Obp117_276_, order0_.EM_Rcinv_Freqtime as EM_Rci118_276_, order0_.Cancelledorder_id as Cancel119_276_, order0_.EM_Obpos_App_Cashup_ID as EM_Obp120_276_, order0_.EM_Obpos_Createdabsolute as EM_Obp121_276_, order0_.Replacedorder_id as Replac122_276_, order0_.EM_OBPOS_NotInvoiceOnCashUp as EM_OBP123_276_, order0_.EM_Obpos_Rejected_Quotat_ID as EM_Obp124_276_, order0_.EM_Obpos_Isdeleted as EM_Obp125_276_, order0_.Iscancelled as Iscanc126_276_, order0_.EM_Obpos_Islayaway as EM_Obp127_276_, order0_.EM_Obpos_Prepaymentamt as EM_Obp128_276_, order0_.Replacementorder_ID as Replac129_276_, order0_.EM_Obpos_Prepaymentlimitamt as EM_Obp130_276_, order0_.EM_Obpos_Prepaymentlaylimitamt as EM_Obp131_276_, order0_.EM_Obpos_Rounding_Amount as EM_Obp132_276_, order0_.BPartner_ExtRef as BPartn133_276_, order0_.EM_Obpos_Sequencename as EM_Obp134_276_, order0_.EM_Prqc_Clauses_Selector as EM_Prq135_276_, order0_.EM_Obpos_Sequencenumber as EM_Obp136_276_, order0_.EM_Rcinv_Cancelcontract as EM_Rci137_276_, order0_.EM_Rcinv_Cancelleddate as EM_Rci138_276_, order0_.EM_Rcinv_Iscancelled as EM_Rci139_276_, order0_.EM_Psat_Activity_ID as EM_Psa140_276_, order0_.EM_OBSMAIL_EmailAddress as EM_OBS141_276_, order0_.EM_Prouti_Order_Stock as EM_Pro142_276_, order0_.EM_Prouti_Pregenerate_Minout as EM_Pro143_276_, order0_.EM_Prouti_Sotopo as EM_Pro144_276_, order0_.EM_Prouti_Generate_Pick_Inv as EM_Pro145_276_, order0_.EM_Pricm_Order_ID as EM_Pri146_276_, order0_.EM_Prouti_Order_ID as EM_Pro147_276_, order0_.EM_Prouti_Grandtotalinitial as EM_Pro148_276_, order0_.EM_Prouti_Dateclosed as EM_Pro149_276_, order0_.EM_Prouti_Totallinesinitial as EM_Pro150_276_, order0_.EM_Prouti_Changebpartner as EM_Pro151_276_, order0_.EM_Prouti_Recalculate_Price as EM_Pro152_276_, order0_.em_prqr_execute as em_prq153_276_, order0_.EM_Prouti_Pricecalculatetdate as EM_Pro154_276_, order0_.EM_Prqr_Execute_Purchase as EM_Prq155_276_, order0_.EM_Prouti_Reactiveorder as EM_Pro156_276_, order0_.EM_Prqr_Return_Select_Prod as EM_Prq157_276_, order0_.EM_Prouti_Totalizations as EM_Pro158_276_, order0_.em_prouti_Invoiced as em_pro159_276_, order0_.em_prouti_Received as em_pro160_276_, order0_.em_prouti_initial_received as em_pro161_276_, order0_.EM_Prouti_Status_Of_Review as EM_Pro162_276_, order0_.EM_Prouti_Validate_Order as EM_Pro163_276_, order0_.EM_Prouti_Start_Review as EM_Pro164_276_, order0_.EM_Ml_Select_Product_Byattrib as EM_Ml_165_276_, order0_.EM_Prres_Reservation_ID as EM_Prr166_276_, order0_.EM_Prres_Responsible_ID as EM_Prr167_276_, order0_.EM_Prres_Diners as EM_Prr168_276_, order0_.EM_Prres_Sended as EM_Prr169_276_, order0_.EM_Prres_Printed as EM_Prr170_276_, order0_.EM_Prouti_Initial_Bp_ID as EM_Pro171_276_, order0_.EM_Prouti_Addlines_Btn as EM_Pro172_276_, order0_.EM_Prtoma_Tomaticket_ID as EM_Prt173_276_, order0_.EM_Cactl_IsCopy as EM_Cac174_276_, order0_.EM_Prtoma_Jsonorder as EM_Prt175_276_, order0_.EM_Prres_Paid_On_Credit as EM_Prr176_276_, order0_.EM_Prtoma_Grossamount as EM_Prt177_276_, order0_.EM_Cactl_Internal_Notes_Group as EM_Cac178_276_, order0_.EM_Prouti_Changebpartner_Bgt as EM_Pro179_276_, order0_.EM_Prrgr_Locator_ID as EM_Prr180_276_, order0_.EM_Paytef_Transactionreference as EM_Pay181_276_, order0_.EM_Cactl_Indirect_Cost_ID as EM_Cac182_276_, order0_.EM_Cactl_Calculate_Cost as EM_Cac183_276_, order0_.EM_Cactl_Totalcost as EM_Cac184_276_, order0_.EM_Cactl_Forceselectedproject as EM_Cac185_276_, order0_.EM_Cactl_Verified_Return as EM_Cac186_276_, order0_.EM_Cactl_Duplicate_Budget as EM_Cac187_276_, order0_.EM_Prres_Orig_Order_ID as EM_Prr188_276_, order0_.EM_Prcpr_Is_Cloned as EM_Prc189_276_, order0_.EM_Prouti_Select_Soline as EM_Pro190_276_, order0_.EM_Prouti_Return_Quantity as EM_Pro191_276_, order0_.EM_Prqr_Executecredit as EM_Prq192_276_, order0_.Em_Prqr_Credit_Purchase_ID as Em_Prq193_276_ from C_Order order0_ cross join C_DocType documentty1_ where order0_.C_DocTypeTarget_ID=documentty1_.C_DocType_ID and order0_.IsSOTrx=$42 and documentty1_.IsReturn=$43 and (order0_.AD_Org_ID in ($1 , $2 , $3 , $4 , $5 , $6 , $7 , $8 , $9 , $10 , $11 , $12 , $13 , $14 , $15 , $16 , $17 , $18 , $19 , $20 , $21 , $22 , $23 , $24 , $25 , $26 , $27 , $28 , $29 , $30 , $31 , $32 , $33 , $34 , $35 , $36 , $37 , $38)) and (order0_.AD_Client_ID in ($39 , $40)) order by order0_.DatePromised desc, order0_.C_Order_ID desc limit $41
f66a111527select materialmg0_.M_Production_ID as M_Produc1_526_, materialmg0_.AD_Client_ID as AD_Clien2_526_, materialmg0_.AD_Org_ID as AD_Org_I3_526_, materialmg0_.IsActive as IsActive4_526_, materialmg0_.Created as Created5_526_, materialmg0_.CreatedBy as CreatedB6_526_, materialmg0_.Updated as Updated7_526_, materialmg0_.UpdatedBy as UpdatedB8_526_, materialmg0_.Name as Name9_526_, materialmg0_.Description as Descrip10_526_, materialmg0_.MovementDate as Movemen11_526_, materialmg0_.IsCreated as IsCreat12_526_, materialmg0_.Posted as Posted13_526_, materialmg0_.Processed as Process14_526_, materialmg0_.Processing as Process15_526_, materialmg0_.AD_OrgTrx_ID as AD_OrgT16_526_, materialmg0_.C_Project_ID as C_Proje17_526_, materialmg0_.C_Campaign_ID as C_Campa18_526_, materialmg0_.C_Activity_ID as C_Activ19_526_, materialmg0_.User1_ID as User20_526_, materialmg0_.User2_ID as User21_526_, materialmg0_.DocumentNo as Documen22_526_, materialmg0_.Endtime as Endtime23_526_, materialmg0_.IsSOTrx as IsSOTrx24_526_, materialmg0_.Starttime as Startti25_526_, materialmg0_.Validating as Validat26_526_, materialmg0_.C_Costcenter_ID as C_Costc27_526_, materialmg0_.A_Asset_ID as A_Asset28_526_, materialmg0_.EM_Obbom_C_Order_ID as EM_Obbo29_526_, materialmg0_.EM_Pruti_Add_Bom_Product as EM_Prut30_526_, materialmg0_.EM_Prres_Isreturned as EM_Prre31_526_ from M_Production materialmg0_ where materialmg0_.IsSOTrx=$42 and (materialmg0_.AD_Org_ID in ($1 , $2 , $3 , $4 , $5 , $6 , $7 , $8 , $9 , $10 , $11 , $12 , $13 , $14 , $15 , $16 , $17 , $18 , $19 , $20 , $21 , $22 , $23 , $24 , $25 , $26 , $27 , $28 , $29 , $30 , $31 , $32 , $33 , $34 , $35 , $36 , $37 , $38)) and (materialmg0_.AD_Client_ID in ($39 , $40)) order by materialmg0_.MovementDate desc, materialmg0_.M_Production_ID desc limit $41
fa1f738bceSELECT COUNT(*) AS ID FROM C_OrderLine WHERE Replacedorderline_id = $1 AND EXISTS (SELECT $2 FROM C_Order WHERE C_Order.C_Order_ID = C_OrderLine.C_Order_ID AND C_Order.IsSOTrx=$3) AND AD_ORG_ID NOT IN ($4,$5,$6,$7,$8,$9,$10,$11,$12,$13,$14,$15,$16,$17,$18,$19,$20,$21,$22,$23,$24,$25,$26,$27,$28,$29,$30,$31,$32,$33,$34,$35,$36,$37,$38,$39,$40,$41)
3d36ea61d3SELECT NIVEL1, NIVEL2, NIVEL3, NIVEL4, NIVEL5, NIVEL6, NIVEL7, NIVEL8, NIVEL9, SUM(AMOUNT) AS AMOUNT, SUM(QTY) AS QTY, SUM(WEIGHT) AS WEIGHT, SUM(AMOUNTREF) AS AMOUNTREF, SUM(QTYREF) AS QTYREF, SUM(WEIGHTREF) AS WEIGHTREF, SUM(CONVAMOUNT) AS CONVAMOUNT, C_CURRENCY_SYMBOL($1, $8, $9) AS CONVSYM, SUM(CONVAMOUNTREF) AS CONVAMOUNTREF, C_CURRENCY_ISOSYM($2) AS CONVISOSYM FROM (SELECT NIVEL1, NIVEL2, NIVEL3, NIVEL4, NIVEL5, NIVEL6, NIVEL7, NIVEL8, NIVEL9, SUM(LINENETAMT) AS AMOUNT, SUM(MOVEMENTQTY) AS QTY, SUM(WEIGHT) AS WEIGHT, SUM(LINENETREF) AS AMOUNTREF, SUM(MOVEMENTQTYREF) AS QTYREF, SUM(WEIGHTREF) AS WEIGHTREF, C_CURRENCY_CONVERT(SUM(LINENETAMT), TRCURRENCYID, $3, TO_DATE(TRDATE), $10, TRCLIENTID, TRORGID) AS CONVAMOUNT, $11 AS CONVAMOUNTREF, TRCURRENCYID, TRDATE, TRCLIENTID, TRORGID FROM (SELECT to_char(AD_COLUMN_IDENTIFIER(to_char($12), to_char( M_PRODUCT.M_PRODUCT_ID), to_char($13))|| CASE WHEN uomsymbol IS NULL THEN $14 ELSE to_char($15||uomsymbol||$16) END) AS NIVEL1, to_char(AD_ORG.NAME) AS NIVEL2, to_char(M_INOUT.DOCUMENTNO) AS NIVEL3, to_char($17) AS NIVEL4, to_char($18) AS NIVEL5, to_char($19) AS NIVEL6, to_char($20) AS NIVEL7, to_char($21) AS NIVEL8, to_char($22) AS NIVEL9, COALESCE(M_INOUTLINE.MOVEMENTQTY*C_ORDERLINE.PRICEACTUAL,$23) AS LINENETAMT, M_INOUTLINE.MOVEMENTQTY, M_INOUTLINE.MOVEMENTQTY*M_PRODUCT.WEIGHT AS WEIGHT, $24 AS LINENETREF, $25 AS MOVEMENTQTYREF, $26 AS WEIGHTREF, C_UOM.UOMSYMBOL, C_ORDERLINE.C_CURRENCY_ID AS TRCURRENCYID, TO_DATE(COALESCE(C_ORDER.DATEORDERED, NOW())) AS TRDATE, C_ORDERLINE.AD_CLIENT_ID AS TRCLIENTID, C_ORDERLINE.AD_ORG_ID AS TRORGID FROM M_INOUTLINE left join C_ORDERLINE on M_INOUTLINE.C_ORDERLINE_ID = C_ORDERLINE.C_ORDERLINE_ID left join C_ORDER on C_ORDERLINE.C_ORDER_ID = C_ORDER.C_ORDER_ID, M_INOUT left join AD_USER on M_INOUT.SALESREP_ID = AD_USER.AD_USER_ID, C_BPARTNER left join C_BPARTNER CB on C_BPARTNER.SALESREP_ID = CB.C_BPARTNER_ID, C_BP_GROUP, M_PRODUCT, M_PRODUCT_CATEGORY, M_WAREHOUSE, C_UOM, AD_ORG WHERE M_INOUT.C_BPARTNER_ID = C_BPARTNER.C_BPARTNER_ID AND C_BPARTNER.C_BP_GROUP_ID = C_BP_GROUP.C_BP_GROUP_ID AND M_INOUT.M_INOUT_ID = M_INOUTLINE.M_INOUT_ID AND M_INOUTLINE.M_PRODUCT_ID = M_PRODUCT.M_PRODUCT_ID AND M_PRODUCT.M_PRODUCT_CATEGORY_ID = M_PRODUCT_CATEGORY.M_PRODUCT_CATEGORY_ID AND M_INOUT.M_WAREHOUSE_ID = M_WAREHOUSE.M_WAREHOUSE_ID AND M_INOUTLINE.C_UOM_ID = C_UOM.C_UOM_ID AND M_INOUT.AD_ORG_ID = AD_ORG.AD_ORG_ID AND M_INOUT.ISSOTRX = $27 AND M_INOUT.PROCESSED = $28 AND $29=$30 AND M_INOUT.AD_ORG_ID IN ($31) AND M_INOUT.AD_CLIENT_ID IN ($32,$33) AND $34=$35 AND M_INOUT.MOVEMENTDATE >= TO_DATE($4) AND M_INOUT.MOVEMENTDATE < TO_DATE($5) AND C_BP_GROUP.C_BP_GROUP_ID = $6 AND C_BPARTNER.C_BPARTNER_ID IN($36) AND M_PRODUCT_CATEGORY.M_PRODUCT_CATEGORY_ID = $7 ) AA GROUP BY NIVEL1, NIVEL2, NIVEL3, NIVEL4, NIVEL5, NIVEL6, NIVEL7, NIVEL8, NIVEL9, TRCURRENCYID, TRDATE, TRCLIENTID, TRORGID) ZZ GROUP BY NIVEL1, NIVEL2, NIVEL3, NIVEL4, NIVEL5, NIVEL6, NIVEL7, NIVEL8, NIVEL9 ORDER BY NIVEL1,NIVEL2,NIVEL3
6bc28a65f9SELECT COUNT(*) AS ID FROM C_OrderLine WHERE Replacedorderline_id = $1 AND EXISTS (SELECT $2 FROM C_Order WHERE C_Order.C_Order_ID = C_OrderLine.C_Order_ID AND C_Order.IsSOTrx=$3) AND AD_ORG_ID IN ($4,$5,$6,$7,$8,$9,$10,$11,$12,$13,$14,$15,$16,$17,$18,$19,$20,$21,$22,$23,$24,$25,$26,$27,$28,$29,$30,$31,$32,$33,$34,$35,$36,$37,$38,$39,$40,$41) AND AD_CLIENT_ID IN ($42)
f570d33a96SELECT * FROM (select f.c_invoice_id as referencekey_id, $2 as ad_role_id, $3 as ad_user_id, $4 || f.documentno|| $5 as description, $6 as isActive, f.ad_org_id, f.ad_client_id, now() as created, $7 as createdBy, now() as updated, $8 as updatedBy, ad_column_identifier($9, f.c_invoice_id, $10) AS RECORD_ID FROM ( select ci.documentno, max(dateinvoiced) as dateinvoiced, max(ci.c_invoice_id) as c_invoice_id, max(ci.ad_org_id) as ad_org_id, max(ci.ad_client_id) as ad_client_id from c_invoice ci join c_order co on co.c_order_id=ci.c_order_id where ci.issotrx=$11 and co.em_obpos_applications_id is not null and ci.dateinvoiced >= current_date - $12 group by ci.documentno, EXTRACT($13 FROM dateinvoiced), ci.c_doctype_id having count(ci.documentno)>$14 order by max(dateinvoiced) desc ) as f) AAA where not exists (select $15 from ad_alert a where a.ad_alertrule_id = $1 and a.referencekey_id = aaa.referencekey_id and coalesce(a.status, $16) != $17)
1c688a8b54SELECT $2 FROM ONLY "public"."m_inoutline" x WHERE $1::pg_catalog.text OPERATOR(pg_catalog.=) "c_aum"::pg_catalog.text FOR KEY SHARE OF x
1fbcf388f5select producttrl0_.M_Product_Trl_ID as M_Produc1_524_, producttrl0_.M_Product_ID as M_Produc2_524_, producttrl0_.AD_Language as AD_Langu3_524_, producttrl0_.AD_Client_ID as AD_Clien4_524_, producttrl0_.AD_Org_ID as AD_Org_I5_524_, producttrl0_.IsActive as IsActive6_524_, producttrl0_.Created as Created7_524_, producttrl0_.CreatedBy as CreatedB8_524_, producttrl0_.Updated as Updated9_524_, producttrl0_.UpdatedBy as Updated10_524_, producttrl0_.Name as Name11_524_, producttrl0_.DocumentNote as Documen12_524_, producttrl0_.IsTranslated as IsTrans13_524_ from M_Product_Trl producttrl0_ where producttrl0_.M_Product_ID=$1 and producttrl0_.AD_Language=$2 and producttrl0_.IsActive=$4 limit $3
ac7478aac8select prges_reco0_.Prges_Records_ID as Prges_Re1_831_, prges_reco0_.AD_Client_ID as AD_Clien2_831_, prges_reco0_.AD_Org_ID as AD_Org_I3_831_, prges_reco0_.Created as Created4_831_, prges_reco0_.Createdby as Createdb5_831_, prges_reco0_.Updated as Updated6_831_, prges_reco0_.Updatedby as Updatedb7_831_, prges_reco0_.Isactive as Isactive8_831_, prges_reco0_.Action as Action9_831_, prges_reco0_.Url as Url10_831_, prges_reco0_.Jsoninfo as Jsoninf11_831_, prges_reco0_.Error as Error12_831_, prges_reco0_.Process as Process13_831_, prges_reco0_.Status as Status14_831_, prges_reco0_.C_Invoice_ID as C_Invoi15_831_, prges_reco0_.Prges_Config_ID as Prges_C16_831_ from prges_records prges_reco0_ where prges_reco0_.Prges_Config_ID=$1 and (prges_reco0_.AD_Org_ID in ($2 , $3 , $4 , $5 , $6 , $7 , $8 , $9 , $10 , $11 , $12 , $13 , $14 , $15 , $16 , $17 , $18 , $19 , $20 , $21 , $22 , $23 , $24 , $25 , $26 , $27 , $28 , $29 , $30 , $31 , $32 , $33 , $34 , $35 , $36 , $37 , $38 , $39)) and (prges_reco0_.AD_Client_ID in ($40 , $41)) order by prges_reco0_.Created desc, prges_reco0_.Prges_Records_ID desc limit $42
4aae53f3daSELECT * FROM (select c_order_id AS referencekey_id, ad_column_identifier_std($2, c_order_id) AS record_id, $3 AS ad_role_id, $4 AS ad_user_id, $5 || documentno AS description, $6 AS isActive, $7 AS ad_org_id, ad_client_id AS ad_client_id, now() AS created, $8 AS createdBy, now() AS updated, $9 AS updatedBy from c_order where ( em_prouti_Received <> (coalesce((select case when sum(abs(ol.qtyordered)) = $10 then $11 else trunc(coalesce(sum(abs(coalesce(( select least(coalesce(abs(sum(il.movementqty)), $12), abs(ol.qtyordered)) from m_inoutline il left join m_inout i on i.m_inout_id=il.m_inout_id where i.docstatus<>$13 and il.c_orderline_id=ol.c_orderline_id ),$14))), $15)/sum(abs(ol.qtyordered)) * $16, $17) end from c_orderline ol where ol.c_order_id=c_order.c_order_id and ol.c_order_discount_id is null ),$18)) or em_prouti_Invoiced <> (coalesce(( select case when sum(abs(ol.qtyordered)) = $19 then $20 else round(coalesce(sum(abs(coalesce(( select least(coalesce(abs(sum(il.qtyinvoiced)), $21), abs(ol.qtyordered)) from c_invoiceline il left join c_invoice i on i.c_invoice_id=il.c_invoice_id where i.docstatus<>$22 and il.c_orderline_id=ol.c_orderline_id ),$23))), $24)/sum(abs(ol.qtyordered)) * $25, $26) end from c_orderline ol where ol.c_order_id=c_order.c_order_id and ol.c_order_discount_id is null), $27)) ) and issotrx=$28 and docstatus <> $29) AAA where not exists (select $30 from ad_alert a where a.ad_alertrule_id = $1 and a.referencekey_id = aaa.referencekey_id and coalesce(a.status, $31) != $32)
18c54477aaSELECT * FROM (select aat.ad_audit_trail_id as referencekey_id, $2 as ad_role_id, $3 as ad_user_id, $4 || co.documentno || $5 || us."name" || $6||co.updated as description, $7 as isActive, aat.ad_org_id, aat.ad_client_id, now() as created, $8 as createdBy, now() as updated, $9 as updatedBy, ad_column_identifier($10, co.c_order_id, $11) AS RECORD_ID from ad_audit_trail aat left join c_order co on co.c_order_id=aat.record_id left join c_doctype cd on cd.c_doctype_id=co.c_doctype_id left join ad_user us on us.ad_user_id= co.updatedby where aat.old_char=$12 and aat.new_char=$13 and co.docstatus = $14 and aat.event_time >= current_date -$15 and cd.em_prres_restaurant=$16) AAA where not exists (select $17 from ad_alert a where a.ad_alertrule_id = $1 and a.referencekey_id = aaa.referencekey_id and coalesce(a.status, $18) != $19)
41ebce9415select order0_.C_Order_ID as C_Order_1_276_, order0_.AD_Client_ID as AD_Clien2_276_, order0_.AD_Org_ID as AD_Org_I3_276_, order0_.IsActive as IsActive4_276_, order0_.Created as Created5_276_, order0_.CreatedBy as CreatedB6_276_, order0_.Updated as Updated7_276_, order0_.UpdatedBy as UpdatedB8_276_, order0_.IsSOTrx as IsSOTrx9_276_, order0_.DocumentNo as Documen10_276_, order0_.DocStatus as DocStat11_276_, order0_.DocAction as DocActi12_276_, order0_.Processing as Process13_276_, order0_.Processed as Process14_276_, order0_.C_DocType_ID as C_DocTy15_276_, order0_.C_DocTypeTarget_ID as C_DocTy16_276_, order0_.Description as Descrip17_276_, order0_.IsDelivered as IsDeliv18_276_, order0_.IsInvoiced as IsInvoi19_276_, order0_.IsPrinted as IsPrint20_276_, order0_.IsSelected as IsSelec21_276_, order0_.SalesRep_ID as SalesRe22_276_, order0_.DateOrdered as DateOrd23_276_, order0_.DatePromised as DatePro24_276_, order0_.DatePrinted as DatePri25_276_, order0_.DateAcct as DateAcc26_276_, order0_.C_BPartner_ID as C_BPart27_276_, order0_.BillTo_ID as BillTo_28_276_, order0_.C_BPartner_Location_ID as C_BPart29_276_, order0_.POReference as PORefer30_276_, order0_.IsDiscountPrinted as IsDisco31_276_, order0_.C_Currency_ID as C_Curre32_276_, order0_.PaymentRule as Payment33_276_, order0_.C_PaymentTerm_ID as C_Payme34_276_, order0_.InvoiceRule as Invoice35_276_, order0_.DeliveryRule as Deliver36_276_, order0_.FreightCostRule as Freight37_276_, order0_.FreightAmt as Freight38_276_, order0_.DeliveryViaRule as Deliver39_276_, order0_.M_Shipper_ID as M_Shipp40_276_, order0_.C_Charge_ID as C_Charg41_276_, order0_.ChargeAmt as ChargeA42_276_, order0_.PriorityRule as Priorit43_276_, order0_.TotalLines as TotalLi44_276_, order0_.GrandTotal as GrandTo45_276_, order0_.M_Warehouse_ID as M_Wareh46_276_, order0_.M_PriceList_ID as M_Price47_276_, order0_.IsTaxIncluded as IsTaxIn48_276_, order0_.C_Campaign_ID as C_Campa49_276_, order0_.C_Project_ID as C_Proje50_276_, order0_.C_Activity_ID as C_Activ51_276_, order0_.Posted as Posted52_276_, order0_.AD_User_ID as AD_User53_276_, order0_.CopyFrom as CopyFro54_276_, order0_.DropShip_BPartner_ID as DropShi55_276_, order0_.DropShip_Location_ID as DropShi56_276_, order0_.DropShip_User_ID as DropShi57_276_, order0_.IsSelfService as IsSelfS58_276_, order0_.AD_OrgTrx_ID as AD_OrgT59_276_, order0_.User1_ID as User60_276_, order0_.User2_ID as User61_276_, order0_.Deliverynotes as Deliver62_276_, order0_.C_Incoterms_ID as C_Incot63_276_, order0_.Incotermsdescription as Incoter64_276_, order0_.Generatetemplate as Generat65_276_, order0_.Delivery_Location_ID as Deliver66_276_, order0_.CopyFromPO as CopyFro67_276_, order0_.FIN_Paymentmethod_ID as FIN_Pay68_276_, order0_.FIN_Payment_Priority_ID as FIN_Pay69_276_, order0_.RM_PickFromShipment as RM_Pick70_276_, order0_.RM_ReceiveMaterials as RM_Rece71_276_, order0_.EM_Obcma_C_Poc_Email_ID as EM_Obcm72_276_, order0_.RM_CreateInvoice as RM_Crea73_276_, order0_.C_Return_Reason_ID as C_Retur74_276_, order0_.RM_AddOrphanLine as RM_AddO75_276_, order0_.A_Asset_ID as A_Asset76_276_, order0_.Calculate_Promotions as Calcula77_276_, order0_.C_Costcenter_ID as C_Costc78_276_, order0_.Convertquotation as Convert79_276_, order0_.C_Reject_Reason_ID as C_Rejec80_276_, order0_.validuntil as validun81_276_, order0_.Quotation_ID as Quotati82_276_, order0_.SO_Res_Status as SO_Res_83_276_, order0_.Create_POLines as Create_84_276_, order0_.EM_Obdisc_Addpack as EM_Obdi85_276_, order0_.Iscashvat as Iscashv86_276_, order0_.EM_OBMFM_Selectfreight as EM_OBMF87_276_, order0_.EM_OBMFM_Delivery_Period_ID as EM_OBMF88_276_, order0_.RM_Pickfromreceipt as RM_Pick89_276_, order0_.Cancelandreplace as Cancela90_276_, order0_.EM_Advcrm_Newactivity as EM_Advc91_276_, order0_.EM_APRM_AddPayment as EM_APRM92_276_, order0_.EM_OBMFM_Delivery_Charges as EM_OBMF93_276_, order0_.EM_OBMFM_Freight_ID as EM_OBMF94_276_, order0_.EM_Obwpl_Generatepicking as EM_Obwp95_276_, order0_.EM_Advcrm_Opportunity_ID as EM_Advc96_276_, order0_.EM_OBMFM_Weight as EM_OBMF97_276_, order0_.EM_Obwpl_Isinpickinglist as EM_Obwp98_276_, order0_.EM_Rcinv_Contractdate as EM_Rcin99_276_, order0_.EM_Obwpl_Readypl as EM_Obw100_276_, order0_.EM_Rcinv_Initialdate as EM_Rci101_276_, order0_.EM_Rcinv_Enddate as EM_Rci102_276_, order0_.EM_Sgpcrm_Securitygroups_ID as EM_Sgp103_276_, order0_.EM_OBMFM_Weight_Uom_ID as EM_OBM104_276_, order0_.EM_Rcinv_Frequency as EM_Rci105_276_, order0_.EM_OBMFM_Set_Weight as EM_OBM106_276_, order0_.EM_Rcinv_Renewautomatically as EM_Rci107_276_, order0_.EM_Aeatsii_Fecha_Operacion as EM_Aea108_276_, order0_.EM_Ml_Select_Product as EM_Ml_109_276_, order0_.EM_Rcinv_Renovationtimes as EM_Rci110_276_, order0_.Confirmcancelandreplace as Confir111_276_, order0_.EM_Aeatsii_Descripcion_Sii as EM_Aea112_276_, order0_.EM_Obpos_Applications_ID as EM_Obp113_276_, order0_.EM_Rcinv_Freqrenovationtime as EM_Rci114_276_, order0_.EM_Obpos_Sendemail as EM_Obp115_276_, order0_.EM_Rcinv_Ordercontract_ID as EM_Rci116_276_, order0_.EM_Obpos_Email_Status as EM_Obp117_276_, order0_.EM_Rcinv_Freqtime as EM_Rci118_276_, order0_.Cancelledorder_id as Cancel119_276_, order0_.EM_Obpos_App_Cashup_ID as EM_Obp120_276_, order0_.EM_Obpos_Createdabsolute as EM_Obp121_276_, order0_.Replacedorder_id as Replac122_276_, order0_.EM_OBPOS_NotInvoiceOnCashUp as EM_OBP123_276_, order0_.EM_Obpos_Rejected_Quotat_ID as EM_Obp124_276_, order0_.EM_Obpos_Isdeleted as EM_Obp125_276_, order0_.Iscancelled as Iscanc126_276_, order0_.EM_Obpos_Islayaway as EM_Obp127_276_, order0_.EM_Obpos_Prepaymentamt as EM_Obp128_276_, order0_.Replacementorder_ID as Replac129_276_, order0_.EM_Obpos_Prepaymentlimitamt as EM_Obp130_276_, order0_.EM_Obpos_Prepaymentlaylimitamt as EM_Obp131_276_, order0_.EM_Obpos_Rounding_Amount as EM_Obp132_276_, order0_.BPartner_ExtRef as BPartn133_276_, order0_.EM_Obpos_Sequencename as EM_Obp134_276_, order0_.EM_Prqc_Clauses_Selector as EM_Prq135_276_, order0_.EM_Obpos_Sequencenumber as EM_Obp136_276_, order0_.EM_Rcinv_Cancelcontract as EM_Rci137_276_, order0_.EM_Rcinv_Cancelleddate as EM_Rci138_276_, order0_.EM_Rcinv_Iscancelled as EM_Rci139_276_, order0_.EM_Psat_Activity_ID as EM_Psa140_276_, order0_.EM_OBSMAIL_EmailAddress as EM_OBS141_276_, order0_.EM_Prouti_Order_Stock as EM_Pro142_276_, order0_.EM_Prouti_Pregenerate_Minout as EM_Pro143_276_, order0_.EM_Prouti_Sotopo as EM_Pro144_276_, order0_.EM_Prouti_Generate_Pick_Inv as EM_Pro145_276_, order0_.EM_Pricm_Order_ID as EM_Pri146_276_, order0_.EM_Prouti_Order_ID as EM_Pro147_276_, order0_.EM_Prouti_Grandtotalinitial as EM_Pro148_276_, order0_.EM_Prouti_Dateclosed as EM_Pro149_276_, order0_.EM_Prouti_Totallinesinitial as EM_Pro150_276_, order0_.EM_Prouti_Changebpartner as EM_Pro151_276_, order0_.EM_Prouti_Recalculate_Price as EM_Pro152_276_, order0_.em_prqr_execute as em_prq153_276_, order0_.EM_Prouti_Pricecalculatetdate as EM_Pro154_276_, order0_.EM_Prqr_Execute_Purchase as EM_Prq155_276_, order0_.EM_Prouti_Reactiveorder as EM_Pro156_276_, order0_.EM_Prqr_Return_Select_Prod as EM_Prq157_276_, order0_.EM_Prouti_Totalizations as EM_Pro158_276_, order0_.em_prouti_Invoiced as em_pro159_276_, order0_.em_prouti_Received as em_pro160_276_, order0_.em_prouti_initial_received as em_pro161_276_, order0_.EM_Prouti_Status_Of_Review as EM_Pro162_276_, order0_.EM_Prouti_Validate_Order as EM_Pro163_276_, order0_.EM_Prouti_Start_Review as EM_Pro164_276_, order0_.EM_Ml_Select_Product_Byattrib as EM_Ml_165_276_, order0_.EM_Prres_Reservation_ID as EM_Prr166_276_, order0_.EM_Prres_Responsible_ID as EM_Prr167_276_, order0_.EM_Prres_Diners as EM_Prr168_276_, order0_.EM_Prres_Sended as EM_Prr169_276_, order0_.EM_Prres_Printed as EM_Prr170_276_, order0_.EM_Prouti_Initial_Bp_ID as EM_Pro171_276_, order0_.EM_Prouti_Addlines_Btn as EM_Pro172_276_, order0_.EM_Prtoma_Tomaticket_ID as EM_Prt173_276_, order0_.EM_Cactl_IsCopy as EM_Cac174_276_, order0_.EM_Prtoma_Jsonorder as EM_Prt175_276_, order0_.EM_Prres_Paid_On_Credit as EM_Prr176_276_, order0_.EM_Prtoma_Grossamount as EM_Prt177_276_, order0_.EM_Cactl_Internal_Notes_Group as EM_Cac178_276_, order0_.EM_Prouti_Changebpartner_Bgt as EM_Pro179_276_, order0_.EM_Prrgr_Locator_ID as EM_Prr180_276_, order0_.EM_Paytef_Transactionreference as EM_Pay181_276_, order0_.EM_Cactl_Indirect_Cost_ID as EM_Cac182_276_, order0_.EM_Cactl_Calculate_Cost as EM_Cac183_276_, order0_.EM_Cactl_Totalcost as EM_Cac184_276_, order0_.EM_Cactl_Forceselectedproject as EM_Cac185_276_, order0_.EM_Cactl_Verified_Return as EM_Cac186_276_, order0_.EM_Cactl_Duplicate_Budget as EM_Cac187_276_, order0_.EM_Prres_Orig_Order_ID as EM_Prr188_276_, order0_.EM_Prcpr_Is_Cloned as EM_Prc189_276_, order0_.EM_Prouti_Select_Soline as EM_Pro190_276_, order0_.EM_Prouti_Return_Quantity as EM_Pro191_276_, order0_.EM_Prqr_Executecredit as EM_Prq192_276_, order0_.Em_Prqr_Credit_Purchase_ID as Em_Prq193_276_ from C_Order order0_ cross join C_DocType documentty1_ where order0_.C_DocTypeTarget_ID=documentty1_.C_DocType_ID and (upper(order0_.DocumentNo) like upper($1) escape $43) and order0_.IsSOTrx=$44 and documentty1_.IsReturn=$45 and (order0_.AD_Org_ID in ($2 , $3 , $4 , $5 , $6 , $7 , $8 , $9 , $10 , $11 , $12 , $13 , $14 , $15 , $16 , $17 , $18 , $19 , $20 , $21 , $22 , $23 , $24 , $25 , $26 , $27 , $28 , $29 , $30 , $31 , $32 , $33 , $34 , $35 , $36 , $37 , $38 , $39)) and (order0_.AD_Client_ID in ($40 , $41)) order by order0_.DatePromised desc, order0_.C_Order_ID desc limit $42
281ee3922aSELECT $2 FROM ONLY "public"."c_order" x WHERE "c_order_id"::pg_catalog.text OPERATOR(pg_catalog.=) $1::pg_catalog.text FOR KEY SHARE OF x
77c9f44e37SELECT * FROM M_INOUT_CREATE($1, $3, $4, $5, $6)
fa5e805d20insert into M_Transaction (AD_Client_ID, AD_Org_ID, IsActive, Created, CreatedBy, Updated, UpdatedBy, MovementType, M_Locator_ID, M_Product_ID, MovementDate, MovementQty, M_ProductionLine_ID, M_AttributeSetInstance_ID, C_UOM_ID, TrxProcessDate, IsCostCalculated, Costing_Status, Checkreservedqty, Isprocessed, Checkpricedifference, EM_Prouti_Exported, Manualcostadjustment, IsCostPermanent, M_Transaction_ID) values ($1, $2, $3, $4, $5, $6, $7, $8, $9, $10, $11, $12, $13, $14, $15, $16, $17, $18, $19, $20, $21, $22, $23, $24, $25)
10410964a2SELECT $2 FROM ONLY "public"."ad_org" x WHERE "ad_org_id"::pg_catalog.text OPERATOR(pg_catalog.=) $1::pg_catalog.text FOR KEY SHARE OF x
7e62f3b264select cactl_vari0_.Cactl_Variety_Product_ID as Cactl_Va1_366_, cactl_vari0_.AD_Client_ID as AD_Clien2_366_, cactl_vari0_.AD_Org_ID as AD_Org_I3_366_, cactl_vari0_.Isactive as Isactive4_366_, cactl_vari0_.Created as Created5_366_, cactl_vari0_.Createdby as Createdb6_366_, cactl_vari0_.Updated as Updated7_366_, cactl_vari0_.Updatedby as Updatedb8_366_, cactl_vari0_.M_Product_ID as M_Produc9_366_, cactl_vari0_.C_Bpartner_ID as C_Bpart10_366_, cactl_vari0_.C_Uom_ID as C_Uom_I11_366_, cactl_vari0_.Price as Price12_366_, cactl_vari0_.Cactl_Variety_ID as Cactl_V13_366_, cactl_vari0_.Pricelist as Priceli14_366_, cactl_vari0_.Date_From as Date_Fr15_366_, cactl_vari0_.Date_To as Date_To16_366_, cactl_vari0_.Vendorproductno as Vendorp17_366_, cactl_vari0_.Iscurrentvendor as Iscurre18_366_, cactl_vari0_.Isprocessing as Isproce19_366_ from cactl_variety_product cactl_vari0_ left outer join C_BPartner businesspa1_ on cactl_vari0_.C_Bpartner_ID=businesspa1_.C_BPartner_ID left outer join C_UOM uom2_ on cactl_vari0_.C_Uom_ID=uom2_.C_UOM_ID left outer join cactl_variety cactl_vari3_ on cactl_vari0_.Cactl_Variety_ID=cactl_vari3_.Cactl_Variety_ID where (cactl_vari0_.AD_Org_ID in ($4 , $5 , $6 , $7 , $8 , $9 , $10)) and (cactl_vari0_.AD_Client_ID in ($1 , $2)) and cactl_vari0_.Isactive=$11 order by businesspa1_.Value, businesspa1_.Name, businesspa1_.TaxID, businesspa1_.Name2, uom2_.Name, cactl_vari0_.Price, cactl_vari3_.Name, cactl_vari3_.Value, cactl_vari0_.Cactl_Variety_Product_ID limit $3
8ec2df7b9dselect cactl_vari0_.Cactl_Variety_Product_ID as Cactl_Va1_366_, cactl_vari0_.AD_Client_ID as AD_Clien2_366_, cactl_vari0_.AD_Org_ID as AD_Org_I3_366_, cactl_vari0_.Isactive as Isactive4_366_, cactl_vari0_.Created as Created5_366_, cactl_vari0_.Createdby as Createdb6_366_, cactl_vari0_.Updated as Updated7_366_, cactl_vari0_.Updatedby as Updatedb8_366_, cactl_vari0_.M_Product_ID as M_Produc9_366_, cactl_vari0_.C_Bpartner_ID as C_Bpart10_366_, cactl_vari0_.C_Uom_ID as C_Uom_I11_366_, cactl_vari0_.Price as Price12_366_, cactl_vari0_.Cactl_Variety_ID as Cactl_V13_366_, cactl_vari0_.Pricelist as Priceli14_366_, cactl_vari0_.Date_From as Date_Fr15_366_, cactl_vari0_.Date_To as Date_To16_366_, cactl_vari0_.Vendorproductno as Vendorp17_366_, cactl_vari0_.Iscurrentvendor as Iscurre18_366_, cactl_vari0_.Isprocessing as Isproce19_366_ from cactl_variety_product cactl_vari0_ left outer join C_BPartner businesspa1_ on cactl_vari0_.C_Bpartner_ID=businesspa1_.C_BPartner_ID left outer join C_UOM uom2_ on cactl_vari0_.C_Uom_ID=uom2_.C_UOM_ID left outer join cactl_variety cactl_vari3_ on cactl_vari0_.Cactl_Variety_ID=cactl_vari3_.Cactl_Variety_ID where (cactl_vari0_.AD_Org_ID in ($4 , $5 , $6 , $7 , $8)) and (cactl_vari0_.AD_Client_ID in ($1 , $2)) and cactl_vari0_.Isactive=$9 order by businesspa1_.Value, businesspa1_.Name, businesspa1_.TaxID, businesspa1_.Name2, uom2_.Name, cactl_vari0_.Price, cactl_vari3_.Name, cactl_vari3_.Value, cactl_vari0_.Cactl_Variety_Product_ID limit $3
98d4183d4bvacuum analyze C_Import_Entry_Archive
e1739d379dCOPY public.c_invoice (c_invoice_id, ad_client_id, ad_org_id, isactive, created, createdby, updated, updatedby, issotrx, documentno, docstatus, docaction, processing, processed, posted, c_doctype_id, c_doctypetarget_id, c_order_id, description, isprinted, salesrep_id, dateinvoiced, dateprinted, dateacct, c_bpartner_id, c_bpartner_location_id, poreference, isdiscountprinted, dateordered, c_currency_id, c_paymentterm_id, c_charge_id, chargeamt, totallines, grandtotal, m_pricelist_id, istaxincluded, c_campaign_id, c_project_id, c_activity_id, createfrom, generateto, ad_user_id, copyfrom, isselfservice, ad_orgtrx_id, user1_id, user2_id, withholdingamount, taxdate, c_withholding_id, ispaid, totalpaid, outstandingamt, daystilldue, dueamt, lastcalculatedondate, fin_paymentmethod_id, fin_payment_priority_id, finalsettlement, daysoutstanding, percentageoverdue, c_costcenter_id, calculate_promotions, a_asset_id, iscashvat, prepaymentamt, createfromorders, createfrominouts, em_aprm_addpayment, em_aprm_processinvoice, paidamtatinvoicing, bpartner_extref, em_einv_generated, em_einv_sent, em_aeatsii_send, em_aeatsii_issent, em_aeatsii_fecha_operacion, em_aeatsii_clave_tipo, em_aeatsii_motivo_rectif, em_aeatsii_clave_tipo_fc, em_aeatsii_tipo_rectif, em_aeatsii_dua, em_aeatsii_fecha_dua, em_aeatsii_estado, em_aeatsii_error_registral, em_aeatsii_modif, em_aeatsii_modified, em_aeatsii_description_id, em_aeatsii_descripcion_sii, em_aeatsii_fecha_reg_cont, em_aeatsii_dup, em_aeatsii_error_code, em_aeatsii_error_msg, em_aeatsii_unsubscribe, em_aeatsii_pur_description_id, em_aeatsii_multi_dua, em_aeatsii_ejercicio, em_aeatsii_periodo, em_aeatsii_autofactura, em_aeatsii_invoice_id, em_aeatsii_insiidate, em_aeatsii_cause_exemption_id, em_aeatsii_isauthorization, em_aeatsii_authorizationno, em_obpos_rounding_amount, em_ml_select_product, em_prouti_recalculate_price, em_prouti_pricecalculatetdate, em_prouti_totalizations, em_obcma_c_poc_email_id, em_obpos_sequencename, em_obpos_sequencenumber, em_advcrm_newactivity, em_priuti_createpurchinv, em_priuti_generated, em_priuti_date_complete, em_priuti_user_complete_id, em_priuti_status_of_review, em_priuti_validate, em_priuti_start_review, em_prges_expediente_id, em_prges_annotation_id, em_prges_record_number, em_prges_grantotal, em_sgpcrm_securitygroups_id, em_prges_poreference, em_cactl_createfromship) TO stdout
1b89da5cecBEGIN
33ff47c769SELECT COUNT(*) AS ID FROM C_OrderLine WHERE Replacedorderline_id = $1 AND EXISTS (SELECT $2 FROM C_Order WHERE C_Order.C_Order_ID = C_OrderLine.C_Order_ID AND EXISTS (SELECT $3 FROM C_BPartner WHERE C_BPartner.C_BPartner_ID = C_Order.C_BPartner_ID AND EXISTS (SELECT $4 FROM C_BPartner WHERE C_BPartner.C_BPartner_ID = C_BPartner.C_BPartner_ID))) AND AD_ORG_ID NOT IN ($5,$6,$7,$8,$9,$10,$11,$12,$13,$14,$15,$16,$17,$18,$19,$20,$21,$22,$23,$24,$25,$26,$27,$28,$29,$30,$31,$32,$33,$34,$35,$36,$37,$38,$39,$40,$41,$42)
181bc0438finsert into ad_context_info (ad_user_id, ad_session_id, processType, processId) values ($1, $2, $3, $4)
67a75a3409COPY public.fact_acct (fact_acct_id, ad_client_id, ad_org_id, isactive, created, createdby, updated, updatedby, c_acctschema_id, account_id, datetrx, dateacct, c_period_id, ad_table_id, record_id, line_id, gl_category_id, c_tax_id, m_locator_id, postingtype, c_currency_id, amtsourcedr, amtsourcecr, amtacctdr, amtacctcr, c_uom_id, qty, m_product_id, c_bpartner_id, ad_orgtrx_id, c_locfrom_id, c_locto_id, c_salesregion_id, c_project_id, c_campaign_id, c_activity_id, user1_id, user2_id, description, a_asset_id, fact_acct_group_id, seqno, factaccttype, docbasetype, acctvalue, acctdescription, record_id2, c_withholding_id, c_doctype_id, c_costcenter_id, ismodify, datebalanced) TO stdout
c057bbbc51insert into ad_context_info (ad_user_id, ad_session_id, processType, processId) values ($1, $2, $3, $4)
2ce9536368vacuum analyze prsync_entry
25ca5e8c6aselect warehouse0_.M_Warehouse_ID as M_Wareho1_563_, warehouse0_.AD_Client_ID as AD_Clien2_563_, warehouse0_.AD_Org_ID as AD_Org_I3_563_, warehouse0_.IsActive as IsActive4_563_, warehouse0_.Created as Created5_563_, warehouse0_.CreatedBy as CreatedB6_563_, warehouse0_.Updated as Updated7_563_, warehouse0_.UpdatedBy as UpdatedB8_563_, warehouse0_.Value as Value9_563_, warehouse0_.Name as Name10_563_, warehouse0_.Description as Descrip11_563_, warehouse0_.C_Location_ID as C_Locat12_563_, warehouse0_.Separator as Separat13_563_, warehouse0_.IsShipper as IsShipp14_563_, warehouse0_.Shippercode as Shipper15_563_, warehouse0_.FromDocumentNo as FromDoc16_563_, warehouse0_.ToDocumentNo as ToDocum17_563_, warehouse0_.M_Returnlocator_ID as M_Retur18_563_, warehouse0_.M_Warehouse_Rule_ID as M_Wareh19_563_, warehouse0_.Isallocated as Isalloc20_563_, warehouse0_.EM_Pricm_Isintransit as EM_Pric21_563_, warehouse0_.EM_Cactl_Centralwh as EM_Cact22_563_, warehouse0_.EM_Prinv_Org_ID as EM_Prin23_563_, warehouse0_.EM_Prdo_Istransit as EM_Prdo24_563_, warehouse0_.EM_Obwpl_Outlocator_ID as EM_Obwp25_563_, warehouse0_.EM_Prdo_Priority as EM_Prdo26_563_, warehouse0_.EM_Prqr_Process_Customer_Ret as EM_Prqr27_563_ from M_Warehouse warehouse0_ where (upper(warehouse0_.Name) like upper($1) escape $3) and (exists (select $4 from C_Order order1_ inner join M_Warehouse warehouse2_ on order1_.M_Warehouse_ID=warehouse2_.M_Warehouse_ID cross join C_DocType documentty3_ where order1_.C_DocTypeTarget_ID=documentty3_.C_DocType_ID and order1_.IsSOTrx=$5 and documentty3_.IsReturn=$6 and warehouse2_.M_Warehouse_ID=warehouse0_.M_Warehouse_ID and (order1_.AD_Org_ID in ($7 , $8 , $9 , $10 , $11 , $12 , $13 , $14 , $15 , $16 , $17 , $18 , $19 , $20 , $21 , $22 , $23 , $24 , $25 , $26 , $27 , $28 , $29 , $30 , $31 , $32 , $33 , $34 , $35 , $36 , $37 , $38 , $39 , $40 , $41 , $42 , $43 , $44)) and (order1_.AD_Client_ID in ($45 , $46)))) order by warehouse0_.Name limit $2
7f59edd627SELECT 1 FROM ONLY "public"."m_locator" x WHERE "m_locator_id"::pg_catalog.text OPERATOR(pg_catalog.=) $1::pg_catalog.text FOR KEY SHARE OF x
b76ef6c915select order0_.C_Order_ID as C_Order_1_276_, order0_.AD_Client_ID as AD_Clien2_276_, order0_.AD_Org_ID as AD_Org_I3_276_, order0_.IsActive as IsActive4_276_, order0_.Created as Created5_276_, order0_.CreatedBy as CreatedB6_276_, order0_.Updated as Updated7_276_, order0_.UpdatedBy as UpdatedB8_276_, order0_.IsSOTrx as IsSOTrx9_276_, order0_.DocumentNo as Documen10_276_, order0_.DocStatus as DocStat11_276_, order0_.DocAction as DocActi12_276_, order0_.Processing as Process13_276_, order0_.Processed as Process14_276_, order0_.C_DocType_ID as C_DocTy15_276_, order0_.C_DocTypeTarget_ID as C_DocTy16_276_, order0_.Description as Descrip17_276_, order0_.IsDelivered as IsDeliv18_276_, order0_.IsInvoiced as IsInvoi19_276_, order0_.IsPrinted as IsPrint20_276_, order0_.IsSelected as IsSelec21_276_, order0_.SalesRep_ID as SalesRe22_276_, order0_.DateOrdered as DateOrd23_276_, order0_.DatePromised as DatePro24_276_, order0_.DatePrinted as DatePri25_276_, order0_.DateAcct as DateAcc26_276_, order0_.C_BPartner_ID as C_BPart27_276_, order0_.BillTo_ID as BillTo_28_276_, order0_.C_BPartner_Location_ID as C_BPart29_276_, order0_.POReference as PORefer30_276_, order0_.IsDiscountPrinted as IsDisco31_276_, order0_.C_Currency_ID as C_Curre32_276_, order0_.PaymentRule as Payment33_276_, order0_.C_PaymentTerm_ID as C_Payme34_276_, order0_.InvoiceRule as Invoice35_276_, order0_.DeliveryRule as Deliver36_276_, order0_.FreightCostRule as Freight37_276_, order0_.FreightAmt as Freight38_276_, order0_.DeliveryViaRule as Deliver39_276_, order0_.M_Shipper_ID as M_Shipp40_276_, order0_.C_Charge_ID as C_Charg41_276_, order0_.ChargeAmt as ChargeA42_276_, order0_.PriorityRule as Priorit43_276_, order0_.TotalLines as TotalLi44_276_, order0_.GrandTotal as GrandTo45_276_, order0_.M_Warehouse_ID as M_Wareh46_276_, order0_.M_PriceList_ID as M_Price47_276_, order0_.IsTaxIncluded as IsTaxIn48_276_, order0_.C_Campaign_ID as C_Campa49_276_, order0_.C_Project_ID as C_Proje50_276_, order0_.C_Activity_ID as C_Activ51_276_, order0_.Posted as Posted52_276_, order0_.AD_User_ID as AD_User53_276_, order0_.CopyFrom as CopyFro54_276_, order0_.DropShip_BPartner_ID as DropShi55_276_, order0_.DropShip_Location_ID as DropShi56_276_, order0_.DropShip_User_ID as DropShi57_276_, order0_.IsSelfService as IsSelfS58_276_, order0_.AD_OrgTrx_ID as AD_OrgT59_276_, order0_.User1_ID as User60_276_, order0_.User2_ID as User61_276_, order0_.Deliverynotes as Deliver62_276_, order0_.C_Incoterms_ID as C_Incot63_276_, order0_.Incotermsdescription as Incoter64_276_, order0_.Generatetemplate as Generat65_276_, order0_.Delivery_Location_ID as Deliver66_276_, order0_.CopyFromPO as CopyFro67_276_, order0_.FIN_Paymentmethod_ID as FIN_Pay68_276_, order0_.FIN_Payment_Priority_ID as FIN_Pay69_276_, order0_.RM_PickFromShipment as RM_Pick70_276_, order0_.RM_ReceiveMaterials as RM_Rece71_276_, order0_.EM_Obcma_C_Poc_Email_ID as EM_Obcm72_276_, order0_.RM_CreateInvoice as RM_Crea73_276_, order0_.C_Return_Reason_ID as C_Retur74_276_, order0_.RM_AddOrphanLine as RM_AddO75_276_, order0_.A_Asset_ID as A_Asset76_276_, order0_.Calculate_Promotions as Calcula77_276_, order0_.C_Costcenter_ID as C_Costc78_276_, order0_.Convertquotation as Convert79_276_, order0_.C_Reject_Reason_ID as C_Rejec80_276_, order0_.validuntil as validun81_276_, order0_.Quotation_ID as Quotati82_276_, order0_.SO_Res_Status as SO_Res_83_276_, order0_.Create_POLines as Create_84_276_, order0_.EM_Obdisc_Addpack as EM_Obdi85_276_, order0_.Iscashvat as Iscashv86_276_, order0_.EM_OBMFM_Selectfreight as EM_OBMF87_276_, order0_.EM_OBMFM_Delivery_Period_ID as EM_OBMF88_276_, order0_.RM_Pickfromreceipt as RM_Pick89_276_, order0_.Cancelandreplace as Cancela90_276_, order0_.EM_Advcrm_Newactivity as EM_Advc91_276_, order0_.EM_APRM_AddPayment as EM_APRM92_276_, order0_.EM_OBMFM_Delivery_Charges as EM_OBMF93_276_, order0_.EM_OBMFM_Freight_ID as EM_OBMF94_276_, order0_.EM_Obwpl_Generatepicking as EM_Obwp95_276_, order0_.EM_Advcrm_Opportunity_ID as EM_Advc96_276_, order0_.EM_OBMFM_Weight as EM_OBMF97_276_, order0_.EM_Obwpl_Isinpickinglist as EM_Obwp98_276_, order0_.EM_Rcinv_Contractdate as EM_Rcin99_276_, order0_.EM_Obwpl_Readypl as EM_Obw100_276_, order0_.EM_Rcinv_Initialdate as EM_Rci101_276_, order0_.EM_Rcinv_Enddate as EM_Rci102_276_, order0_.EM_Sgpcrm_Securitygroups_ID as EM_Sgp103_276_, order0_.EM_OBMFM_Weight_Uom_ID as EM_OBM104_276_, order0_.EM_Rcinv_Frequency as EM_Rci105_276_, order0_.EM_OBMFM_Set_Weight as EM_OBM106_276_, order0_.EM_Rcinv_Renewautomatically as EM_Rci107_276_, order0_.EM_Aeatsii_Fecha_Operacion as EM_Aea108_276_, order0_.EM_Ml_Select_Product as EM_Ml_109_276_, order0_.EM_Rcinv_Renovationtimes as EM_Rci110_276_, order0_.Confirmcancelandreplace as Confir111_276_, order0_.EM_Aeatsii_Descripcion_Sii as EM_Aea112_276_, order0_.EM_Obpos_Applications_ID as EM_Obp113_276_, order0_.EM_Rcinv_Freqrenovationtime as EM_Rci114_276_, order0_.EM_Obpos_Sendemail as EM_Obp115_276_, order0_.EM_Rcinv_Ordercontract_ID as EM_Rci116_276_, order0_.EM_Obpos_Email_Status as EM_Obp117_276_, order0_.EM_Rcinv_Freqtime as EM_Rci118_276_, order0_.Cancelledorder_id as Cancel119_276_, order0_.EM_Obpos_App_Cashup_ID as EM_Obp120_276_, order0_.EM_Obpos_Createdabsolute as EM_Obp121_276_, order0_.Replacedorder_id as Replac122_276_, order0_.EM_OBPOS_NotInvoiceOnCashUp as EM_OBP123_276_, order0_.EM_Obpos_Rejected_Quotat_ID as EM_Obp124_276_, order0_.EM_Obpos_Isdeleted as EM_Obp125_276_, order0_.Iscancelled as Iscanc126_276_, order0_.EM_Obpos_Islayaway as EM_Obp127_276_, order0_.EM_Obpos_Prepaymentamt as EM_Obp128_276_, order0_.Replacementorder_ID as Replac129_276_, order0_.EM_Obpos_Prepaymentlimitamt as EM_Obp130_276_, order0_.EM_Obpos_Prepaymentlaylimitamt as EM_Obp131_276_, order0_.EM_Obpos_Rounding_Amount as EM_Obp132_276_, order0_.BPartner_ExtRef as BPartn133_276_, order0_.EM_Obpos_Sequencename as EM_Obp134_276_, order0_.EM_Prqc_Clauses_Selector as EM_Prq135_276_, order0_.EM_Obpos_Sequencenumber as EM_Obp136_276_, order0_.EM_Rcinv_Cancelcontract as EM_Rci137_276_, order0_.EM_Rcinv_Cancelleddate as EM_Rci138_276_, order0_.EM_Rcinv_Iscancelled as EM_Rci139_276_, order0_.EM_Psat_Activity_ID as EM_Psa140_276_, order0_.EM_OBSMAIL_EmailAddress as EM_OBS141_276_, order0_.EM_Prouti_Order_Stock as EM_Pro142_276_, order0_.EM_Prouti_Pregenerate_Minout as EM_Pro143_276_, order0_.EM_Prouti_Sotopo as EM_Pro144_276_, order0_.EM_Prouti_Generate_Pick_Inv as EM_Pro145_276_, order0_.EM_Pricm_Order_ID as EM_Pri146_276_, order0_.EM_Prouti_Order_ID as EM_Pro147_276_, order0_.EM_Prouti_Grandtotalinitial as EM_Pro148_276_, order0_.EM_Prouti_Dateclosed as EM_Pro149_276_, order0_.EM_Prouti_Totallinesinitial as EM_Pro150_276_, order0_.EM_Prouti_Changebpartner as EM_Pro151_276_, order0_.EM_Prouti_Recalculate_Price as EM_Pro152_276_, order0_.em_prqr_execute as em_prq153_276_, order0_.EM_Prouti_Pricecalculatetdate as EM_Pro154_276_, order0_.EM_Prqr_Execute_Purchase as EM_Prq155_276_, order0_.EM_Prouti_Reactiveorder as EM_Pro156_276_, order0_.EM_Prqr_Return_Select_Prod as EM_Prq157_276_, order0_.EM_Prouti_Totalizations as EM_Pro158_276_, order0_.em_prouti_Invoiced as em_pro159_276_, order0_.em_prouti_Received as em_pro160_276_, order0_.em_prouti_initial_received as em_pro161_276_, order0_.EM_Prouti_Status_Of_Review as EM_Pro162_276_, order0_.EM_Prouti_Validate_Order as EM_Pro163_276_, order0_.EM_Prouti_Start_Review as EM_Pro164_276_, order0_.EM_Ml_Select_Product_Byattrib as EM_Ml_165_276_, order0_.EM_Prres_Reservation_ID as EM_Prr166_276_, order0_.EM_Prres_Responsible_ID as EM_Prr167_276_, order0_.EM_Prres_Diners as EM_Prr168_276_, order0_.EM_Prres_Sended as EM_Prr169_276_, order0_.EM_Prres_Printed as EM_Prr170_276_, order0_.EM_Prouti_Initial_Bp_ID as EM_Pro171_276_, order0_.EM_Prouti_Addlines_Btn as EM_Pro172_276_, order0_.EM_Prtoma_Tomaticket_ID as EM_Prt173_276_, order0_.EM_Cactl_IsCopy as EM_Cac174_276_, order0_.EM_Prtoma_Jsonorder as EM_Prt175_276_, order0_.EM_Prres_Paid_On_Credit as EM_Prr176_276_, order0_.EM_Prtoma_Grossamount as EM_Prt177_276_, order0_.EM_Cactl_Internal_Notes_Group as EM_Cac178_276_, order0_.EM_Prouti_Changebpartner_Bgt as EM_Pro179_276_, order0_.EM_Prrgr_Locator_ID as EM_Prr180_276_, order0_.EM_Paytef_Transactionreference as EM_Pay181_276_, order0_.EM_Cactl_Indirect_Cost_ID as EM_Cac182_276_, order0_.EM_Cactl_Calculate_Cost as EM_Cac183_276_, order0_.EM_Cactl_Totalcost as EM_Cac184_276_, order0_.EM_Cactl_Forceselectedproject as EM_Cac185_276_, order0_.EM_Cactl_Verified_Return as EM_Cac186_276_, order0_.EM_Cactl_Duplicate_Budget as EM_Cac187_276_, order0_.EM_Prres_Orig_Order_ID as EM_Prr188_276_, order0_.EM_Prcpr_Is_Cloned as EM_Prc189_276_, order0_.EM_Prouti_Select_Soline as EM_Pro190_276_, order0_.EM_Prouti_Return_Quantity as EM_Pro191_276_, order0_.EM_Prqr_Executecredit as EM_Prq192_276_, order0_.Em_Prqr_Credit_Purchase_ID as Em_Prq193_276_ from C_Order order0_ where (upper((order0_.DocumentNo||$3||coalesce(to_char(order0_.DateOrdered), $4)||$5||coalesce(to_char(order0_.GrandTotal), $6))) like upper($1) escape $7) and (exists (select $8 from M_InOut materialmg1_ inner join C_Order order2_ on materialmg1_.C_Order_ID=order2_.C_Order_ID cross join C_DocType documentty3_ where materialmg1_.C_DocType_ID=documentty3_.C_DocType_ID and (materialmg1_.MovementType in ($9 , $10)) and materialmg1_.Islogistic=$11 and documentty3_.IsReturn=$12 and order2_.C_Order_ID=order0_.C_Order_ID and (materialmg1_.AD_Org_ID in ($13 , $14 , $15 , $16 , $17 , $18 , $19 , $20 , $21 , $22 , $23 , $24 , $25 , $26 , $27 , $28 , $29 , $30 , $31 , $32 , $33 , $34 , $35 , $36 , $37 , $38 , $39 , $40 , $41 , $42 , $43 , $44 , $45 , $46 , $47 , $48 , $49 , $50)) and (materialmg1_.AD_Client_ID in ($51 , $52)))) order by order0_.DocumentNo, order0_.DateOrdered, order0_.GrandTotal limit $2
17592c9fe0select order0_.DocumentNo as col_0_0_, businesspa2_.Name as col_1_0_, order0_.DateOrdered as col_2_0_, organizati3_.Name as col_3_0_, adlisttrl1_.Name as col_4_0_ from C_Order order0_ cross join C_BPartner businesspa2_ cross join AD_Org organizati3_ cross join AD_Ref_List_Trl adlisttrl1_ cross join AD_Ref_List adlist4_ where order0_.C_BPartner_ID=businesspa2_.C_BPartner_ID and order0_.AD_Org_ID=organizati3_.AD_Org_ID and adlisttrl1_.AD_Ref_List_ID=adlist4_.AD_Ref_List_ID and order0_.EM_Prouti_Status_Of_Review<>$4 and adlist4_.Value=order0_.EM_Prouti_Status_Of_Review and adlist4_.AD_Reference_ID=$5 and adlisttrl1_.AD_Language=$1 and ($2 in (select prouti_ord6_.AD_User_ID from prouti_order_reviewers prouti_ord6_ where prouti_ord6_.C_Order_ID=order0_.C_Order_ID and (prouti_ord6_.Sequence in (select coalesce(min(prouti_ord7_.Sequence), $6) from prouti_order_reviewers prouti_ord7_ where prouti_ord7_.C_Order_ID=order0_.C_Order_ID and (prouti_ord7_.Result is null))))) limit $3
e54b22db57CREATE INDEX prpass_pass_inst_hist_ord_ix ON prpass_pass_inst_hist (c_order_id) WHERE c_order_id IS NOT NULL
1452c325d3SELECT 1 FROM ONLY "public"."m_attributesetinstance" x WHERE "m_attributesetinstance_id"::pg_catalog.text OPERATOR(pg_catalog.=) $1::pg_catalog.text FOR KEY SHARE OF x
d5c8e0e271INSERT INTO m_stock_proposed ( m_stock_proposed_id, ad_client_id, ad_org_id, isactive, created , createdby, updated, updatedby, ad_pinstance_id, priority, m_storage_detail_id, quantity, qtyorder, isfinal ) VALUES ( get_uuid(), v_ClientID, v_OrgID, $60, TO_DATE(NOW()), v_AD_User_ID, TO_DATE(NOW()), v_AD_User_ID, p_uuid, v_Count, Cur_Stock.M_STORAGE_DETAIL_ID, Cur_Stock.Qty, Cur_Stock.QtyOrder, $61 )
e17f13e4acselect order0_.C_Order_ID as C_Order_1_276_, order0_.AD_Client_ID as AD_Clien2_276_, order0_.AD_Org_ID as AD_Org_I3_276_, order0_.IsActive as IsActive4_276_, order0_.Created as Created5_276_, order0_.CreatedBy as CreatedB6_276_, order0_.Updated as Updated7_276_, order0_.UpdatedBy as UpdatedB8_276_, order0_.IsSOTrx as IsSOTrx9_276_, order0_.DocumentNo as Documen10_276_, order0_.DocStatus as DocStat11_276_, order0_.DocAction as DocActi12_276_, order0_.Processing as Process13_276_, order0_.Processed as Process14_276_, order0_.C_DocType_ID as C_DocTy15_276_, order0_.C_DocTypeTarget_ID as C_DocTy16_276_, order0_.Description as Descrip17_276_, order0_.IsDelivered as IsDeliv18_276_, order0_.IsInvoiced as IsInvoi19_276_, order0_.IsPrinted as IsPrint20_276_, order0_.IsSelected as IsSelec21_276_, order0_.SalesRep_ID as SalesRe22_276_, order0_.DateOrdered as DateOrd23_276_, order0_.DatePromised as DatePro24_276_, order0_.DatePrinted as DatePri25_276_, order0_.DateAcct as DateAcc26_276_, order0_.C_BPartner_ID as C_BPart27_276_, order0_.BillTo_ID as BillTo_28_276_, order0_.C_BPartner_Location_ID as C_BPart29_276_, order0_.POReference as PORefer30_276_, order0_.IsDiscountPrinted as IsDisco31_276_, order0_.C_Currency_ID as C_Curre32_276_, order0_.PaymentRule as Payment33_276_, order0_.C_PaymentTerm_ID as C_Payme34_276_, order0_.InvoiceRule as Invoice35_276_, order0_.DeliveryRule as Deliver36_276_, order0_.FreightCostRule as Freight37_276_, order0_.FreightAmt as Freight38_276_, order0_.DeliveryViaRule as Deliver39_276_, order0_.M_Shipper_ID as M_Shipp40_276_, order0_.C_Charge_ID as C_Charg41_276_, order0_.ChargeAmt as ChargeA42_276_, order0_.PriorityRule as Priorit43_276_, order0_.TotalLines as TotalLi44_276_, order0_.GrandTotal as GrandTo45_276_, order0_.M_Warehouse_ID as M_Wareh46_276_, order0_.M_PriceList_ID as M_Price47_276_, order0_.IsTaxIncluded as IsTaxIn48_276_, order0_.C_Campaign_ID as C_Campa49_276_, order0_.C_Project_ID as C_Proje50_276_, order0_.C_Activity_ID as C_Activ51_276_, order0_.Posted as Posted52_276_, order0_.AD_User_ID as AD_User53_276_, order0_.CopyFrom as CopyFro54_276_, order0_.DropShip_BPartner_ID as DropShi55_276_, order0_.DropShip_Location_ID as DropShi56_276_, order0_.DropShip_User_ID as DropShi57_276_, order0_.IsSelfService as IsSelfS58_276_, order0_.AD_OrgTrx_ID as AD_OrgT59_276_, order0_.User1_ID as User60_276_, order0_.User2_ID as User61_276_, order0_.Deliverynotes as Deliver62_276_, order0_.C_Incoterms_ID as C_Incot63_276_, order0_.Incotermsdescription as Incoter64_276_, order0_.Generatetemplate as Generat65_276_, order0_.Delivery_Location_ID as Deliver66_276_, order0_.CopyFromPO as CopyFro67_276_, order0_.FIN_Paymentmethod_ID as FIN_Pay68_276_, order0_.FIN_Payment_Priority_ID as FIN_Pay69_276_, order0_.RM_PickFromShipment as RM_Pick70_276_, order0_.RM_ReceiveMaterials as RM_Rece71_276_, order0_.EM_Obcma_C_Poc_Email_ID as EM_Obcm72_276_, order0_.RM_CreateInvoice as RM_Crea73_276_, order0_.C_Return_Reason_ID as C_Retur74_276_, order0_.RM_AddOrphanLine as RM_AddO75_276_, order0_.A_Asset_ID as A_Asset76_276_, order0_.Calculate_Promotions as Calcula77_276_, order0_.C_Costcenter_ID as C_Costc78_276_, order0_.Convertquotation as Convert79_276_, order0_.C_Reject_Reason_ID as C_Rejec80_276_, order0_.validuntil as validun81_276_, order0_.Quotation_ID as Quotati82_276_, order0_.SO_Res_Status as SO_Res_83_276_, order0_.Create_POLines as Create_84_276_, order0_.EM_Obdisc_Addpack as EM_Obdi85_276_, order0_.Iscashvat as Iscashv86_276_, order0_.EM_OBMFM_Selectfreight as EM_OBMF87_276_, order0_.EM_OBMFM_Delivery_Period_ID as EM_OBMF88_276_, order0_.RM_Pickfromreceipt as RM_Pick89_276_, order0_.Cancelandreplace as Cancela90_276_, order0_.EM_Advcrm_Newactivity as EM_Advc91_276_, order0_.EM_APRM_AddPayment as EM_APRM92_276_, order0_.EM_OBMFM_Delivery_Charges as EM_OBMF93_276_, order0_.EM_OBMFM_Freight_ID as EM_OBMF94_276_, order0_.EM_Obwpl_Generatepicking as EM_Obwp95_276_, order0_.EM_Advcrm_Opportunity_ID as EM_Advc96_276_, order0_.EM_OBMFM_Weight as EM_OBMF97_276_, order0_.EM_Obwpl_Isinpickinglist as EM_Obwp98_276_, order0_.EM_Rcinv_Contractdate as EM_Rcin99_276_, order0_.EM_Obwpl_Readypl as EM_Obw100_276_, order0_.EM_Rcinv_Initialdate as EM_Rci101_276_, order0_.EM_Rcinv_Enddate as EM_Rci102_276_, order0_.EM_Sgpcrm_Securitygroups_ID as EM_Sgp103_276_, order0_.EM_OBMFM_Weight_Uom_ID as EM_OBM104_276_, order0_.EM_Rcinv_Frequency as EM_Rci105_276_, order0_.EM_OBMFM_Set_Weight as EM_OBM106_276_, order0_.EM_Rcinv_Renewautomatically as EM_Rci107_276_, order0_.EM_Aeatsii_Fecha_Operacion as EM_Aea108_276_, order0_.EM_Ml_Select_Product as EM_Ml_109_276_, order0_.EM_Rcinv_Renovationtimes as EM_Rci110_276_, order0_.Confirmcancelandreplace as Confir111_276_, order0_.EM_Aeatsii_Descripcion_Sii as EM_Aea112_276_, order0_.EM_Obpos_Applications_ID as EM_Obp113_276_, order0_.EM_Rcinv_Freqrenovationtime as EM_Rci114_276_, order0_.EM_Obpos_Sendemail as EM_Obp115_276_, order0_.EM_Rcinv_Ordercontract_ID as EM_Rci116_276_, order0_.EM_Obpos_Email_Status as EM_Obp117_276_, order0_.EM_Rcinv_Freqtime as EM_Rci118_276_, order0_.Cancelledorder_id as Cancel119_276_, order0_.EM_Obpos_App_Cashup_ID as EM_Obp120_276_, order0_.EM_Obpos_Createdabsolute as EM_Obp121_276_, order0_.Replacedorder_id as Replac122_276_, order0_.EM_OBPOS_NotInvoiceOnCashUp as EM_OBP123_276_, order0_.EM_Obpos_Rejected_Quotat_ID as EM_Obp124_276_, order0_.EM_Obpos_Isdeleted as EM_Obp125_276_, order0_.Iscancelled as Iscanc126_276_, order0_.EM_Obpos_Islayaway as EM_Obp127_276_, order0_.EM_Obpos_Prepaymentamt as EM_Obp128_276_, order0_.Replacementorder_ID as Replac129_276_, order0_.EM_Obpos_Prepaymentlimitamt as EM_Obp130_276_, order0_.EM_Obpos_Prepaymentlaylimitamt as EM_Obp131_276_, order0_.EM_Obpos_Rounding_Amount as EM_Obp132_276_, order0_.BPartner_ExtRef as BPartn133_276_, order0_.EM_Obpos_Sequencename as EM_Obp134_276_, order0_.EM_Prqc_Clauses_Selector as EM_Prq135_276_, order0_.EM_Obpos_Sequencenumber as EM_Obp136_276_, order0_.EM_Rcinv_Cancelcontract as EM_Rci137_276_, order0_.EM_Rcinv_Cancelleddate as EM_Rci138_276_, order0_.EM_Rcinv_Iscancelled as EM_Rci139_276_, order0_.EM_Psat_Activity_ID as EM_Psa140_276_, order0_.EM_OBSMAIL_EmailAddress as EM_OBS141_276_, order0_.EM_Prouti_Order_Stock as EM_Pro142_276_, order0_.EM_Prouti_Pregenerate_Minout as EM_Pro143_276_, order0_.EM_Prouti_Sotopo as EM_Pro144_276_, order0_.EM_Prouti_Generate_Pick_Inv as EM_Pro145_276_, order0_.EM_Pricm_Order_ID as EM_Pri146_276_, order0_.EM_Prouti_Order_ID as EM_Pro147_276_, order0_.EM_Prouti_Grandtotalinitial as EM_Pro148_276_, order0_.EM_Prouti_Dateclosed as EM_Pro149_276_, order0_.EM_Prouti_Totallinesinitial as EM_Pro150_276_, order0_.EM_Prouti_Changebpartner as EM_Pro151_276_, order0_.EM_Prouti_Recalculate_Price as EM_Pro152_276_, order0_.em_prqr_execute as em_prq153_276_, order0_.EM_Prouti_Pricecalculatetdate as EM_Pro154_276_, order0_.EM_Prqr_Execute_Purchase as EM_Prq155_276_, order0_.EM_Prouti_Reactiveorder as EM_Pro156_276_, order0_.EM_Prqr_Return_Select_Prod as EM_Prq157_276_, order0_.EM_Prouti_Totalizations as EM_Pro158_276_, order0_.em_prouti_Invoiced as em_pro159_276_, order0_.em_prouti_Received as em_pro160_276_, order0_.em_prouti_initial_received as em_pro161_276_, order0_.EM_Prouti_Status_Of_Review as EM_Pro162_276_, order0_.EM_Prouti_Validate_Order as EM_Pro163_276_, order0_.EM_Prouti_Start_Review as EM_Pro164_276_, order0_.EM_Ml_Select_Product_Byattrib as EM_Ml_165_276_, order0_.EM_Prres_Reservation_ID as EM_Prr166_276_, order0_.EM_Prres_Responsible_ID as EM_Prr167_276_, order0_.EM_Prres_Diners as EM_Prr168_276_, order0_.EM_Prres_Sended as EM_Prr169_276_, order0_.EM_Prres_Printed as EM_Prr170_276_, order0_.EM_Prouti_Initial_Bp_ID as EM_Pro171_276_, order0_.EM_Prouti_Addlines_Btn as EM_Pro172_276_, order0_.EM_Prtoma_Tomaticket_ID as EM_Prt173_276_, order0_.EM_Cactl_IsCopy as EM_Cac174_276_, order0_.EM_Prtoma_Jsonorder as EM_Prt175_276_, order0_.EM_Prres_Paid_On_Credit as EM_Prr176_276_, order0_.EM_Prtoma_Grossamount as EM_Prt177_276_, order0_.EM_Cactl_Internal_Notes_Group as EM_Cac178_276_, order0_.EM_Prouti_Changebpartner_Bgt as EM_Pro179_276_, order0_.EM_Prrgr_Locator_ID as EM_Prr180_276_, order0_.EM_Paytef_Transactionreference as EM_Pay181_276_, order0_.EM_Cactl_Indirect_Cost_ID as EM_Cac182_276_, order0_.EM_Cactl_Calculate_Cost as EM_Cac183_276_, order0_.EM_Cactl_Totalcost as EM_Cac184_276_, order0_.EM_Cactl_Forceselectedproject as EM_Cac185_276_, order0_.EM_Cactl_Verified_Return as EM_Cac186_276_, order0_.EM_Cactl_Duplicate_Budget as EM_Cac187_276_, order0_.EM_Prres_Orig_Order_ID as EM_Prr188_276_, order0_.EM_Prcpr_Is_Cloned as EM_Prc189_276_, order0_.EM_Prouti_Select_Soline as EM_Pro190_276_, order0_.EM_Prouti_Return_Quantity as EM_Pro191_276_, order0_.EM_Prqr_Executecredit as EM_Prq192_276_, order0_.Em_Prqr_Credit_Purchase_ID as Em_Prq193_276_ from C_Order order0_ cross join C_DocType documentty1_ where order0_.C_DocTypeTarget_ID=documentty1_.C_DocType_ID and order0_.IsSOTrx=$42 and documentty1_.IsReturn=$43 and (order0_.AD_Org_ID in ($1 , $2 , $3 , $4 , $5 , $6 , $7 , $8 , $9 , $10 , $11 , $12 , $13 , $14 , $15 , $16 , $17 , $18 , $19 , $20 , $21 , $22 , $23 , $24 , $25 , $26 , $27 , $28 , $29 , $30 , $31 , $32 , $33 , $34 , $35 , $36 , $37 , $38)) and (order0_.AD_Client_ID in ($39 , $40)) order by order0_.DocumentNo, order0_.C_Order_ID limit $41
6fe43f5091SELECT COUNT(*) AS ID FROM C_OrderLine WHERE Replacedorderline_id = $1 AND EXISTS (SELECT $2 FROM C_Order WHERE C_Order.C_Order_ID = C_OrderLine.C_Order_ID AND EXISTS (SELECT $3 FROM C_BPartner WHERE C_BPartner.C_BPartner_ID = C_Order.C_BPartner_ID AND EXISTS (SELECT $4 FROM C_BPartner WHERE C_BPartner.C_BPartner_ID = C_BPartner.C_BPartner_ID))) AND AD_ORG_ID IN ($5,$6,$7,$8,$9,$10,$11,$12,$13,$14,$15,$16,$17,$18,$19,$20,$21,$22,$23,$24,$25,$26,$27,$28,$29,$30,$31,$32,$33,$34,$35,$36,$37,$38,$39,$40,$41,$42) AND AD_CLIENT_ID IN ($43)
9918228dbaselect prges_conf0_.Prges_Config_ID as Prges_Co1_830_1_, prges_conf0_.AD_Client_ID as AD_Clien2_830_1_, prges_conf0_.AD_Org_ID as AD_Org_I3_830_1_, prges_conf0_.Created as Created4_830_1_, prges_conf0_.Createdby as Createdb5_830_1_, prges_conf0_.Updated as Updated6_830_1_, prges_conf0_.Updatedby as Updatedb7_830_1_, prges_conf0_.Isactive as Isactive8_830_1_, prges_conf0_.Url as Url9_830_1_, prges_conf0_.Token as Token10_830_1_, prges_conf0_.C_Doctype_ID as C_Docty11_830_1_, prges_conf0_.Hold_Seconds as Hold_Se12_830_1_, prges_conf0_.Addon as Addon13_830_1_, prgesrecor1_.Prges_Config_ID as Prges_C16_831_3_, prgesrecor1_.Prges_Records_ID as Prges_Re1_831_3_, prgesrecor1_.Prges_Records_ID as Prges_Re1_831_0_, prgesrecor1_.AD_Client_ID as AD_Clien2_831_0_, prgesrecor1_.AD_Org_ID as AD_Org_I3_831_0_, prgesrecor1_.Created as Created4_831_0_, prgesrecor1_.Createdby as Createdb5_831_0_, prgesrecor1_.Updated as Updated6_831_0_, prgesrecor1_.Updatedby as Updatedb7_831_0_, prgesrecor1_.Isactive as Isactive8_831_0_, prgesrecor1_.Action as Action9_831_0_, prgesrecor1_.Url as Url10_831_0_, prgesrecor1_.Jsoninfo as Jsoninf11_831_0_, prgesrecor1_.Error as Error12_831_0_, prgesrecor1_.Process as Process13_831_0_, prgesrecor1_.Status as Status14_831_0_, prgesrecor1_.C_Invoice_ID as C_Invoi15_831_0_, prgesrecor1_.Prges_Config_ID as Prges_C16_831_0_ from prges_config prges_conf0_ left outer join prges_records prgesrecor1_ on prges_conf0_.Prges_Config_ID=prgesrecor1_.Prges_Config_ID where prges_conf0_.Prges_Config_ID=$1
18920cc811select created , unlimited from prpass_pass_inst ppi order by created asc
b99cde50b0select order0_.C_Order_ID as C_Order_1_276_, order0_.AD_Client_ID as AD_Clien2_276_, order0_.AD_Org_ID as AD_Org_I3_276_, order0_.IsActive as IsActive4_276_, order0_.Created as Created5_276_, order0_.CreatedBy as CreatedB6_276_, order0_.Updated as Updated7_276_, order0_.UpdatedBy as UpdatedB8_276_, order0_.IsSOTrx as IsSOTrx9_276_, order0_.DocumentNo as Documen10_276_, order0_.DocStatus as DocStat11_276_, order0_.DocAction as DocActi12_276_, order0_.Processing as Process13_276_, order0_.Processed as Process14_276_, order0_.C_DocType_ID as C_DocTy15_276_, order0_.C_DocTypeTarget_ID as C_DocTy16_276_, order0_.Description as Descrip17_276_, order0_.IsDelivered as IsDeliv18_276_, order0_.IsInvoiced as IsInvoi19_276_, order0_.IsPrinted as IsPrint20_276_, order0_.IsSelected as IsSelec21_276_, order0_.SalesRep_ID as SalesRe22_276_, order0_.DateOrdered as DateOrd23_276_, order0_.DatePromised as DatePro24_276_, order0_.DatePrinted as DatePri25_276_, order0_.DateAcct as DateAcc26_276_, order0_.C_BPartner_ID as C_BPart27_276_, order0_.BillTo_ID as BillTo_28_276_, order0_.C_BPartner_Location_ID as C_BPart29_276_, order0_.POReference as PORefer30_276_, order0_.IsDiscountPrinted as IsDisco31_276_, order0_.C_Currency_ID as C_Curre32_276_, order0_.PaymentRule as Payment33_276_, order0_.C_PaymentTerm_ID as C_Payme34_276_, order0_.InvoiceRule as Invoice35_276_, order0_.DeliveryRule as Deliver36_276_, order0_.FreightCostRule as Freight37_276_, order0_.FreightAmt as Freight38_276_, order0_.DeliveryViaRule as Deliver39_276_, order0_.M_Shipper_ID as M_Shipp40_276_, order0_.C_Charge_ID as C_Charg41_276_, order0_.ChargeAmt as ChargeA42_276_, order0_.PriorityRule as Priorit43_276_, order0_.TotalLines as TotalLi44_276_, order0_.GrandTotal as GrandTo45_276_, order0_.M_Warehouse_ID as M_Wareh46_276_, order0_.M_PriceList_ID as M_Price47_276_, order0_.IsTaxIncluded as IsTaxIn48_276_, order0_.C_Campaign_ID as C_Campa49_276_, order0_.C_Project_ID as C_Proje50_276_, order0_.C_Activity_ID as C_Activ51_276_, order0_.Posted as Posted52_276_, order0_.AD_User_ID as AD_User53_276_, order0_.CopyFrom as CopyFro54_276_, order0_.DropShip_BPartner_ID as DropShi55_276_, order0_.DropShip_Location_ID as DropShi56_276_, order0_.DropShip_User_ID as DropShi57_276_, order0_.IsSelfService as IsSelfS58_276_, order0_.AD_OrgTrx_ID as AD_OrgT59_276_, order0_.User1_ID as User60_276_, order0_.User2_ID as User61_276_, order0_.Deliverynotes as Deliver62_276_, order0_.C_Incoterms_ID as C_Incot63_276_, order0_.Incotermsdescription as Incoter64_276_, order0_.Generatetemplate as Generat65_276_, order0_.Delivery_Location_ID as Deliver66_276_, order0_.CopyFromPO as CopyFro67_276_, order0_.FIN_Paymentmethod_ID as FIN_Pay68_276_, order0_.FIN_Payment_Priority_ID as FIN_Pay69_276_, order0_.RM_PickFromShipment as RM_Pick70_276_, order0_.RM_ReceiveMaterials as RM_Rece71_276_, order0_.EM_Obcma_C_Poc_Email_ID as EM_Obcm72_276_, order0_.RM_CreateInvoice as RM_Crea73_276_, order0_.C_Return_Reason_ID as C_Retur74_276_, order0_.RM_AddOrphanLine as RM_AddO75_276_, order0_.A_Asset_ID as A_Asset76_276_, order0_.Calculate_Promotions as Calcula77_276_, order0_.C_Costcenter_ID as C_Costc78_276_, order0_.Convertquotation as Convert79_276_, order0_.C_Reject_Reason_ID as C_Rejec80_276_, order0_.validuntil as validun81_276_, order0_.Quotation_ID as Quotati82_276_, order0_.SO_Res_Status as SO_Res_83_276_, order0_.Create_POLines as Create_84_276_, order0_.EM_Obdisc_Addpack as EM_Obdi85_276_, order0_.Iscashvat as Iscashv86_276_, order0_.EM_OBMFM_Selectfreight as EM_OBMF87_276_, order0_.EM_OBMFM_Delivery_Period_ID as EM_OBMF88_276_, order0_.RM_Pickfromreceipt as RM_Pick89_276_, order0_.Cancelandreplace as Cancela90_276_, order0_.EM_Advcrm_Newactivity as EM_Advc91_276_, order0_.EM_APRM_AddPayment as EM_APRM92_276_, order0_.EM_OBMFM_Delivery_Charges as EM_OBMF93_276_, order0_.EM_OBMFM_Freight_ID as EM_OBMF94_276_, order0_.EM_Obwpl_Generatepicking as EM_Obwp95_276_, order0_.EM_Advcrm_Opportunity_ID as EM_Advc96_276_, order0_.EM_OBMFM_Weight as EM_OBMF97_276_, order0_.EM_Obwpl_Isinpickinglist as EM_Obwp98_276_, order0_.EM_Rcinv_Contractdate as EM_Rcin99_276_, order0_.EM_Obwpl_Readypl as EM_Obw100_276_, order0_.EM_Rcinv_Initialdate as EM_Rci101_276_, order0_.EM_Rcinv_Enddate as EM_Rci102_276_, order0_.EM_Sgpcrm_Securitygroups_ID as EM_Sgp103_276_, order0_.EM_OBMFM_Weight_Uom_ID as EM_OBM104_276_, order0_.EM_Rcinv_Frequency as EM_Rci105_276_, order0_.EM_OBMFM_Set_Weight as EM_OBM106_276_, order0_.EM_Rcinv_Renewautomatically as EM_Rci107_276_, order0_.EM_Aeatsii_Fecha_Operacion as EM_Aea108_276_, order0_.EM_Ml_Select_Product as EM_Ml_109_276_, order0_.EM_Rcinv_Renovationtimes as EM_Rci110_276_, order0_.Confirmcancelandreplace as Confir111_276_, order0_.EM_Aeatsii_Descripcion_Sii as EM_Aea112_276_, order0_.EM_Obpos_Applications_ID as EM_Obp113_276_, order0_.EM_Rcinv_Freqrenovationtime as EM_Rci114_276_, order0_.EM_Obpos_Sendemail as EM_Obp115_276_, order0_.EM_Rcinv_Ordercontract_ID as EM_Rci116_276_, order0_.EM_Obpos_Email_Status as EM_Obp117_276_, order0_.EM_Rcinv_Freqtime as EM_Rci118_276_, order0_.Cancelledorder_id as Cancel119_276_, order0_.EM_Obpos_App_Cashup_ID as EM_Obp120_276_, order0_.EM_Obpos_Createdabsolute as EM_Obp121_276_, order0_.Replacedorder_id as Replac122_276_, order0_.EM_OBPOS_NotInvoiceOnCashUp as EM_OBP123_276_, order0_.EM_Obpos_Rejected_Quotat_ID as EM_Obp124_276_, order0_.EM_Obpos_Isdeleted as EM_Obp125_276_, order0_.Iscancelled as Iscanc126_276_, order0_.EM_Obpos_Islayaway as EM_Obp127_276_, order0_.EM_Obpos_Prepaymentamt as EM_Obp128_276_, order0_.Replacementorder_ID as Replac129_276_, order0_.EM_Obpos_Prepaymentlimitamt as EM_Obp130_276_, order0_.EM_Obpos_Prepaymentlaylimitamt as EM_Obp131_276_, order0_.EM_Obpos_Rounding_Amount as EM_Obp132_276_, order0_.BPartner_ExtRef as BPartn133_276_, order0_.EM_Obpos_Sequencename as EM_Obp134_276_, order0_.EM_Prqc_Clauses_Selector as EM_Prq135_276_, order0_.EM_Obpos_Sequencenumber as EM_Obp136_276_, order0_.EM_Rcinv_Cancelcontract as EM_Rci137_276_, order0_.EM_Rcinv_Cancelleddate as EM_Rci138_276_, order0_.EM_Rcinv_Iscancelled as EM_Rci139_276_, order0_.EM_Psat_Activity_ID as EM_Psa140_276_, order0_.EM_OBSMAIL_EmailAddress as EM_OBS141_276_, order0_.EM_Prouti_Order_Stock as EM_Pro142_276_, order0_.EM_Prouti_Pregenerate_Minout as EM_Pro143_276_, order0_.EM_Prouti_Sotopo as EM_Pro144_276_, order0_.EM_Prouti_Generate_Pick_Inv as EM_Pro145_276_, order0_.EM_Pricm_Order_ID as EM_Pri146_276_, order0_.EM_Prouti_Order_ID as EM_Pro147_276_, order0_.EM_Prouti_Grandtotalinitial as EM_Pro148_276_, order0_.EM_Prouti_Dateclosed as EM_Pro149_276_, order0_.EM_Prouti_Totallinesinitial as EM_Pro150_276_, order0_.EM_Prouti_Changebpartner as EM_Pro151_276_, order0_.EM_Prouti_Recalculate_Price as EM_Pro152_276_, order0_.em_prqr_execute as em_prq153_276_, order0_.EM_Prouti_Pricecalculatetdate as EM_Pro154_276_, order0_.EM_Prqr_Execute_Purchase as EM_Prq155_276_, order0_.EM_Prouti_Reactiveorder as EM_Pro156_276_, order0_.EM_Prqr_Return_Select_Prod as EM_Prq157_276_, order0_.EM_Prouti_Totalizations as EM_Pro158_276_, order0_.em_prouti_Invoiced as em_pro159_276_, order0_.em_prouti_Received as em_pro160_276_, order0_.em_prouti_initial_received as em_pro161_276_, order0_.EM_Prouti_Status_Of_Review as EM_Pro162_276_, order0_.EM_Prouti_Validate_Order as EM_Pro163_276_, order0_.EM_Prouti_Start_Review as EM_Pro164_276_, order0_.EM_Ml_Select_Product_Byattrib as EM_Ml_165_276_, order0_.EM_Prres_Reservation_ID as EM_Prr166_276_, order0_.EM_Prres_Responsible_ID as EM_Prr167_276_, order0_.EM_Prres_Diners as EM_Prr168_276_, order0_.EM_Prres_Sended as EM_Prr169_276_, order0_.EM_Prres_Printed as EM_Prr170_276_, order0_.EM_Prouti_Initial_Bp_ID as EM_Pro171_276_, order0_.EM_Prouti_Addlines_Btn as EM_Pro172_276_, order0_.EM_Prtoma_Tomaticket_ID as EM_Prt173_276_, order0_.EM_Cactl_IsCopy as EM_Cac174_276_, order0_.EM_Prtoma_Jsonorder as EM_Prt175_276_, order0_.EM_Prres_Paid_On_Credit as EM_Prr176_276_, order0_.EM_Prtoma_Grossamount as EM_Prt177_276_, order0_.EM_Cactl_Internal_Notes_Group as EM_Cac178_276_, order0_.EM_Prouti_Changebpartner_Bgt as EM_Pro179_276_, order0_.EM_Prrgr_Locator_ID as EM_Prr180_276_, order0_.EM_Paytef_Transactionreference as EM_Pay181_276_, order0_.EM_Cactl_Indirect_Cost_ID as EM_Cac182_276_, order0_.EM_Cactl_Calculate_Cost as EM_Cac183_276_, order0_.EM_Cactl_Totalcost as EM_Cac184_276_, order0_.EM_Cactl_Forceselectedproject as EM_Cac185_276_, order0_.EM_Cactl_Verified_Return as EM_Cac186_276_, order0_.EM_Cactl_Duplicate_Budget as EM_Cac187_276_, order0_.EM_Prres_Orig_Order_ID as EM_Prr188_276_, order0_.EM_Prcpr_Is_Cloned as EM_Prc189_276_, order0_.EM_Prouti_Select_Soline as EM_Pro190_276_, order0_.EM_Prouti_Return_Quantity as EM_Pro191_276_, order0_.EM_Prqr_Executecredit as EM_Prq192_276_, order0_.Em_Prqr_Credit_Purchase_ID as Em_Prq193_276_ from C_Order order0_ inner join M_Warehouse warehouse1_ on order0_.M_Warehouse_ID=warehouse1_.M_Warehouse_ID cross join C_DocType documentty2_ where order0_.C_DocTypeTarget_ID=documentty2_.C_DocType_ID and order0_.IsSOTrx=$43 and documentty2_.IsReturn=$44 and (order0_.Updated>$1 or order0_.Processed=$45) and (order0_.AD_Org_ID in ($2 , $3 , $4 , $5 , $6 , $7 , $8 , $9 , $10 , $11 , $12 , $13 , $14 , $15 , $16 , $17 , $18 , $19 , $20 , $21 , $22 , $23 , $24 , $25 , $26 , $27 , $28 , $29 , $30 , $31 , $32 , $33 , $34 , $35 , $36 , $37 , $38 , $39)) and (order0_.AD_Client_ID in ($40 , $41)) order by warehouse1_.Name desc, order0_.C_Order_ID desc limit $42
d545a87b3dupdate C_Invoice set Updated=$1, LastCalculatedOnDate=$2 where C_Invoice_ID=$3
781daf8db9SELECT $2 FROM ONLY "public"."fact_acct" x WHERE $1::pg_catalog.text OPERATOR(pg_catalog.=) "c_uom_id"::pg_catalog.text FOR KEY SHARE OF x
ff35139986SELECT * FROM C_Order_Post($1)
ab6445a3b6select this_.AD_TreeNode_ID as AD_TreeN1_125_0_, this_.AD_Tree_ID as AD_Tree_2_125_0_, this_.Node_ID as Node_ID3_125_0_, this_.AD_Client_ID as AD_Clien4_125_0_, this_.AD_Org_ID as AD_Org_I5_125_0_, this_.IsActive as IsActive6_125_0_, this_.Created as Created7_125_0_, this_.CreatedBy as CreatedB8_125_0_, this_.Updated as Updated9_125_0_, this_.UpdatedBy as Updated10_125_0_, this_.Parent_ID as Parent_11_125_0_, this_.SeqNo as SeqNo12_125_0_ from AD_TreeNode this_ where this_.Node_ID=$1 and this_.Parent_ID<>$2 and this_.IsActive=$3
66933eeddeselect f.id, f.hour, CASE WHEN f.reservation_type = $1 AND f.multiplier is not null THEN f.available * f.multiplier ELSE f.available END as available, CASE WHEN f.reservation_type = $2 AND f.multiplier is not null THEN f.reserved * f.multiplier ELSE f.reserved END as reserved, f.slot_type FROM ( select ptd.prpass_timeslots_detail_id as id, to_char(ptd.hour, $3) as hour, coalesce( (select qtyavailable from prpass_timeslots_exceptions pte where pte.prpass_timeslots_id = ptd.prpass_timeslots_id and (ptd.hour is null OR (to_char(pte.hour, $4) = to_char(ptd.hour, $5))) and pte.date = $6::date), CASE WHEN (EXTRACT($7 FROM ($8::timestamp - CURRENT_DATE)) / $9 >= pt.agency_reservation_time) OR (ptd.qtyavailable_agency > $10 AND pt.agency_reservation_time is null) THEN CASE WHEN $11 THEN COALESCE(ptd.qtyavailable_agency, COALESCE(ptd.qtyavailable_online, qtyavailable)) WHEN $12 AND ptd.qtyavailable_online = $13 THEN ptd.qtyavailable_online ELSE (COALESCE(ptd.qtyavailable_online, qtyavailable)) - ptd.qtyavailable_agency END ELSE CASE WHEN pt.slot_type = $14 AND $15 THEN COALESCE(ptd.qtyavailable_online, ptd.qtyavailable) ELSE ptd.qtyavailable END END) as available, coalesce( (select sum( CASE WHEN pt.reservation_type = $16 AND f.cart is not null AND pt.multiplier is not null THEN floor((f.qtyreservation + pt.multiplier - $17) / pt.multiplier) ELSE f.qtyreservation END) from( select CASE WHEN max(ptr.c_orderline_id) is not null THEN count(ppi.prpass_pass_inst_id) ELSE max(ptr.qtyreservation) END as qtyreservation, cart from prpass_timeslots_res ptr left join c_orderline col on col.c_orderline_id = ptr.c_orderline_id left join c_order co on co.c_order_id = col.c_order_id left join prpass_pass_inst ppi on ppi.c_orderline_id = col.c_orderline_id where ptr.prpass_timeslots_detail_id = ptd.prpass_timeslots_detail_id and ptr.date = $18::date and (pt.slot_type <> $19 or (pt.slot_type = $20 and CASE WHEN $21 THEN co.em_obpos_applications_id is null OR ptr.c_orderline_id is null ELSE co.em_obpos_applications_id is not null OR ptr.c_orderline_id is null END)) and (CASE WHEN (EXTRACT($22 FROM (ptr.date - CURRENT_DATE)) / $23 >= pt.agency_reservation_time) OR (ptd.qtyavailable_agency > $24 AND pt.agency_reservation_time is null) THEN CASE WHEN $25 THEN ptr.agency = $26 ELSE ptr.agency = $27 END ELSE $28 END) and (ppi.status <>$29 or ppi.status is null) and cart is not null group by cart ) as f), $30) as reserved, pt.multiplier, pt.reservation_type, pt.slot_type from prpass_timeslots_detail ptd join prpass_timeslots pt on pt.prpass_timeslots_id = ptd.prpass_timeslots_id where ptd.prpass_timeslots_id = $31 order by 2 asc) AS f
1ca54a7d1eSELECT * FROM AD_SEQUENCE_DOC($1,$2,$3)
d3471812deselect invoice0_.C_Invoice_ID as C_Invoic1_260_, invoice0_.AD_Client_ID as AD_Clien2_260_, invoice0_.AD_Org_ID as AD_Org_I3_260_, invoice0_.IsActive as IsActive4_260_, invoice0_.Created as Created5_260_, invoice0_.CreatedBy as CreatedB6_260_, invoice0_.Updated as Updated7_260_, invoice0_.UpdatedBy as UpdatedB8_260_, invoice0_.IsSOTrx as IsSOTrx9_260_, invoice0_.DocumentNo as Documen10_260_, invoice0_.DocStatus as DocStat11_260_, invoice0_.DocAction as DocActi12_260_, invoice0_.Processing as Process13_260_, invoice0_.Processed as Process14_260_, invoice0_.Posted as Posted15_260_, invoice0_.C_DocType_ID as C_DocTy16_260_, invoice0_.C_DocTypeTarget_ID as C_DocTy17_260_, invoice0_.C_Order_ID as C_Order18_260_, invoice0_.Description as Descrip19_260_, invoice0_.IsPrinted as IsPrint20_260_, invoice0_.SalesRep_ID as SalesRe21_260_, invoice0_.DateInvoiced as DateInv22_260_, invoice0_.DatePrinted as DatePri23_260_, invoice0_.DateAcct as DateAcc24_260_, invoice0_.C_BPartner_ID as C_BPart25_260_, invoice0_.C_BPartner_Location_ID as C_BPart26_260_, invoice0_.POReference as PORefer27_260_, invoice0_.IsDiscountPrinted as IsDisco28_260_, invoice0_.DateOrdered as DateOrd29_260_, invoice0_.C_Currency_ID as C_Curre30_260_, invoice0_.C_PaymentTerm_ID as C_Payme31_260_, invoice0_.C_Charge_ID as C_Charg32_260_, invoice0_.ChargeAmt as ChargeA33_260_, invoice0_.TotalLines as TotalLi34_260_, invoice0_.GrandTotal as GrandTo35_260_, invoice0_.M_PriceList_ID as M_Price36_260_, invoice0_.IsTaxIncluded as IsTaxIn37_260_, invoice0_.C_Campaign_ID as C_Campa38_260_, invoice0_.C_Project_ID as C_Proje39_260_, invoice0_.C_Activity_ID as C_Activ40_260_, invoice0_.CreateFrom as CreateF41_260_, invoice0_.GenerateTo as Generat42_260_, invoice0_.AD_User_ID as AD_User43_260_, invoice0_.CopyFrom as CopyFro44_260_, invoice0_.IsSelfService as IsSelfS45_260_, invoice0_.AD_OrgTrx_ID as AD_OrgT46_260_, invoice0_.User1_ID as User47_260_, invoice0_.User2_ID as User48_260_, invoice0_.Withholdingamount as Withhol49_260_, invoice0_.Taxdate as Taxdate50_260_, invoice0_.C_Withholding_ID as C_Withh51_260_, invoice0_.Ispaid as Ispaid52_260_, invoice0_.EM_Einv_Generated as EM_Einv53_260_, invoice0_.Totalpaid as Totalpa54_260_, invoice0_.EM_Einv_Sent as EM_Einv55_260_, invoice0_.OutstandingAmt as Outstan56_260_, invoice0_.DaysTillDue as DaysTil57_260_, invoice0_.DueAmt as DueAmt58_260_, invoice0_.LastCalculatedOnDate as LastCal59_260_, invoice0_.FIN_Paymentmethod_ID as FIN_Pay60_260_, invoice0_.FIN_Payment_Priority_ID as FIN_Pay61_260_, invoice0_.Finalsettlement as Finalse62_260_, invoice0_.Daysoutstanding as Daysout63_260_, invoice0_.Percentageoverdue as Percent64_260_, invoice0_.C_Costcenter_ID as C_Costc65_260_, invoice0_.Calculate_Promotions as Calcula66_260_, invoice0_.A_Asset_ID as A_Asset67_260_, invoice0_.EM_APRM_Addpayment as EM_APRM68_260_, invoice0_.Iscashvat as Iscashv69_260_, invoice0_.EM_APRM_Processinvoice as EM_APRM70_260_, invoice0_.EM_Obcma_C_Poc_Email_ID as EM_Obcm71_260_, invoice0_.Prepaymentamt as Prepaym72_260_, invoice0_.Createfromorders as Createf73_260_, invoice0_.Createfrominouts as Createf74_260_, invoice0_.EM_Advcrm_Newactivity as EM_Advc75_260_, invoice0_.Paidamtatinvoicing as Paidamt76_260_, invoice0_.EM_Obpos_Rounding_Amount as EM_Obpo77_260_, invoice0_.EM_Sgpcrm_Securitygroups_ID as EM_Sgpc78_260_, invoice0_.BPartner_ExtRef as BPartne79_260_, invoice0_.EM_Aeatsii_Send as EM_Aeat80_260_, invoice0_.EM_Obpos_Sequencename as EM_Obpo81_260_, invoice0_.EM_Aeatsii_Issent as EM_Aeat82_260_, invoice0_.EM_Obpos_Sequencenumber as EM_Obpo83_260_, invoice0_.EM_Aeatsii_Fecha_Operacion as EM_Aeat84_260_, invoice0_.EM_Aeatsii_Clave_Tipo as EM_Aeat85_260_, invoice0_.EM_Aeatsii_Motivo_Rectif as EM_Aeat86_260_, invoice0_.EM_Prouti_Recalculate_Price as EM_Prou87_260_, invoice0_.EM_Aeatsii_Clave_Tipo_Fc as EM_Aeat88_260_, invoice0_.EM_Ml_Select_Product as EM_Ml_S89_260_, invoice0_.EM_Prouti_Pricecalculatetdate as EM_Prou90_260_, invoice0_.EM_Aeatsii_Tipo_Rectif as EM_Aeat91_260_, invoice0_.EM_Prouti_Totalizations as EM_Prou92_260_, invoice0_.EM_Aeatsii_Dua as EM_Aeat93_260_, invoice0_.EM_Aeatsii_Fecha_Dua as EM_Aeat94_260_, invoice0_.EM_Aeatsii_Estado as EM_Aeat95_260_, invoice0_.EM_Aeatsii_Error_Registral as EM_Aeat96_260_, invoice0_.EM_Aeatsii_Modif as EM_Aeat97_260_, invoice0_.EM_Aeatsii_Modified as EM_Aeat98_260_, invoice0_.EM_Aeatsii_Description_ID as EM_Aeat99_260_, invoice0_.EM_Aeatsii_Descripcion_Sii as EM_Aea100_260_, invoice0_.EM_Aeatsii_Fecha_Reg_Cont as EM_Aea101_260_, invoice0_.EM_Aeatsii_Dup as EM_Aea102_260_, invoice0_.EM_Aeatsii_Error_Code as EM_Aea103_260_, invoice0_.EM_Aeatsii_Error_Msg as EM_Aea104_260_, invoice0_.EM_Aeatsii_Unsubscribe as EM_Aea105_260_, invoice0_.EM_Aeatsii_Pur_Description_ID as EM_Aea106_260_, invoice0_.EM_Aeatsii_Multi_Dua as EM_Aea107_260_, invoice0_.EM_Aeatsii_Ejercicio as EM_Aea108_260_, invoice0_.EM_Aeatsii_Periodo as EM_Aea109_260_, invoice0_.EM_Aeatsii_Autofactura as EM_Aea110_260_, invoice0_.EM_Aeatsii_Invoice_ID as EM_Aea111_260_, invoice0_.EM_Aeatsii_Insiidate as EM_Aea112_260_, invoice0_.EM_Aeatsii_Cause_Exemption_ID as EM_Aea113_260_, invoice0_.EM_Aeatsii_Isauthorization as EM_Aea114_260_, invoice0_.EM_Aeatsii_Authorizationno as EM_Aea115_260_, invoice0_.EM_Priuti_Createpurchinv as EM_Pri116_260_, invoice0_.EM_Priuti_Generated as EM_Pri117_260_, invoice0_.EM_Priuti_Date_Complete as EM_Pri118_260_, invoice0_.EM_Prges_Expediente_ID as EM_Prg119_260_, invoice0_.EM_Priuti_User_Complete_ID as EM_Pri120_260_, invoice0_.EM_Prges_Annotation_ID as EM_Prg121_260_, invoice0_.EM_Prges_Record_Number as EM_Prg122_260_, invoice0_.EM_Priuti_Status_Of_Review as EM_Pri123_260_, invoice0_.EM_Prges_Grantotal as EM_Prg124_260_, invoice0_.EM_Priuti_Validate as EM_Pri125_260_, invoice0_.EM_Priuti_Start_Review as EM_Pri126_260_, invoice0_.EM_Prges_Poreference as EM_Prg127_260_, invoice0_.em_cactl_createfromship as em_cac128_260_ from C_Invoice invoice0_ where invoice0_.IsSOTrx=$43 and invoice0_.DocStatus<>$44 and (invoice0_.Updated>$1 or invoice0_.Processed=$45) and (invoice0_.AD_Org_ID in ($2 , $3 , $4 , $5 , $6 , $7 , $8 , $9 , $10 , $11 , $12 , $13 , $14 , $15 , $16 , $17 , $18 , $19 , $20 , $21 , $22 , $23 , $24 , $25 , $26 , $27 , $28 , $29 , $30 , $31 , $32 , $33 , $34 , $35 , $36 , $37 , $38 , $39)) and (invoice0_.AD_Client_ID in ($40 , $41)) order by invoice0_.DateInvoiced desc, invoice0_.C_Invoice_ID desc limit $42
7247cdc8b5select c_import_e0_.C_IMPORT_ENTRY_ID as C_IMPORT1_257_, c_import_e0_.AD_Client_ID as AD_Clien2_257_, c_import_e0_.AD_Org_ID as AD_Org_I3_257_, c_import_e0_.Isactive as Isactive4_257_, c_import_e0_.Created as Created5_257_, c_import_e0_.Createdby as Createdb6_257_, c_import_e0_.Updated as Updated7_257_, c_import_e0_.Updatedby as Updatedb8_257_, c_import_e0_.Imported as Imported9_257_, c_import_e0_.Jsoninfo as Jsoninf10_257_, c_import_e0_.ImportStatus as ImportS11_257_, c_import_e0_.Typeofdata as Typeofd12_257_, c_import_e0_.Errorinfo as Errorin13_257_, c_import_e0_.AD_Role_ID as AD_Role14_257_, c_import_e0_.Createdtimestamp as Created15_257_, c_import_e0_.EM_Obpos_Applications_ID as EM_Obpo16_257_, c_import_e0_.Responseinfo as Respons17_257_ from C_IMPORT_ENTRY c_import_e0_ where c_import_e0_.Typeofdata=$1 and c_import_e0_.ImportStatus=$3 order by c_import_e0_.Created, c_import_e0_.Createdtimestamp limit $2
214f622e78select prpass_pas0_.Prpass_Pass_Inst_ID as Prpass_P1_878_, prpass_pas0_.AD_Client_ID as AD_Clien2_878_, prpass_pas0_.AD_Org_ID as AD_Org_I3_878_, prpass_pas0_.Isactive as Isactive4_878_, prpass_pas0_.Created as Created5_878_, prpass_pas0_.Createdby as Createdb6_878_, prpass_pas0_.Updated as Updated7_878_, prpass_pas0_.Updatedby as Updatedb8_878_, prpass_pas0_.Value as Value9_878_, prpass_pas0_.Status as Status10_878_, prpass_pas0_.C_Orderline_ID as C_Order11_878_, prpass_pas0_.C_Order_ID as C_Order12_878_, prpass_pas0_.Dateordered as Dateord13_878_, prpass_pas0_.C_Bpartner_ID as C_Bpart14_878_, prpass_pas0_.M_Product_ID as M_Produ15_878_, prpass_pas0_.Obpos_Applications_ID as Obpos_A16_878_, prpass_pas0_.Cancel as Cancel17_878_, prpass_pas0_.AD_Creation_Org_ID as AD_Crea18_878_, prpass_pas0_.Expirationdate as Expirat19_878_, prpass_pas0_.EM_Cactl_Gl_Journal_ID as EM_Cact20_878_, prpass_pas0_.Prpass_Timeslots_Detail_ID as Prpass_21_878_, prpass_pas0_.Prpass_Timeslots_Res_ID as Prpass_22_878_, prpass_pas0_.Time_First_Pick as Time_Fi23_878_, prpass_pas0_.Validate_Manual as Validat24_878_, prpass_pas0_.Unlimited as Unlimit25_878_ from prpass_pass_inst prpass_pas0_ where (upper(prpass_pas0_.Value) like upper($1) escape $43) and (prpass_pas0_.AD_Org_ID in ($2 , $3 , $4 , $5 , $6 , $7 , $8 , $9 , $10 , $11 , $12 , $13 , $14 , $15 , $16 , $17 , $18 , $19 , $20 , $21 , $22 , $23 , $24 , $25 , $26 , $27 , $28 , $29 , $30 , $31 , $32 , $33 , $34 , $35 , $36 , $37 , $38 , $39)) and (prpass_pas0_.AD_Client_ID in ($40 , $41)) order by prpass_pas0_.Value, prpass_pas0_.Prpass_Pass_Inst_ID limit $42
30f874364ainsert into ad_context_info (ad_user_id, ad_session_id, processType, processId) values ($1, $2, $3, $4)
6759033aa8select materialmg0_.M_InOut_ID as M_InOut_1_463_, materialmg0_.AD_Client_ID as AD_Clien2_463_, materialmg0_.AD_Org_ID as AD_Org_I3_463_, materialmg0_.IsActive as IsActive4_463_, materialmg0_.Created as Created5_463_, materialmg0_.CreatedBy as CreatedB6_463_, materialmg0_.Updated as Updated7_463_, materialmg0_.UpdatedBy as UpdatedB8_463_, materialmg0_.IsSOTrx as IsSOTrx9_463_, materialmg0_.DocumentNo as Documen10_463_, materialmg0_.DocAction as DocActi11_463_, materialmg0_.DocStatus as DocStat12_463_, materialmg0_.Posted as Posted13_463_, materialmg0_.Processing as Process14_463_, materialmg0_.Processed as Process15_463_, materialmg0_.C_DocType_ID as C_DocTy16_463_, materialmg0_.Description as Descrip17_463_, materialmg0_.C_Order_ID as C_Order18_463_, materialmg0_.DateOrdered as DateOrd19_463_, materialmg0_.IsPrinted as IsPrint20_463_, materialmg0_.MovementType as Movemen21_463_, materialmg0_.MovementDate as Movemen22_463_, materialmg0_.DateAcct as DateAcc23_463_, materialmg0_.C_BPartner_ID as C_BPart24_463_, materialmg0_.C_BPartner_Location_ID as C_BPart25_463_, materialmg0_.M_Warehouse_ID as M_Wareh26_463_, materialmg0_.POReference as PORefer27_463_, materialmg0_.DeliveryRule as Deliver28_463_, materialmg0_.FreightCostRule as Freight29_463_, materialmg0_.FreightAmt as Freight30_463_, materialmg0_.DeliveryViaRule as Deliver31_463_, materialmg0_.M_Shipper_ID as M_Shipp32_463_, materialmg0_.C_Charge_ID as C_Charg33_463_, materialmg0_.ChargeAmt as ChargeA34_463_, materialmg0_.PriorityRule as Priorit35_463_, materialmg0_.DatePrinted as DatePri36_463_, materialmg0_.C_Invoice_ID as C_Invoi37_463_, materialmg0_.CreateFrom as CreateF38_463_, materialmg0_.GenerateTo as Generat39_463_, materialmg0_.AD_User_ID as AD_User40_463_, materialmg0_.SalesRep_ID as SalesRe41_463_, materialmg0_.NoPackages as NoPacka42_463_, materialmg0_.PickDate as PickDat43_463_, materialmg0_.ShipDate as ShipDat44_463_, materialmg0_.TrackingNo as Trackin45_463_, materialmg0_.AD_OrgTrx_ID as AD_OrgT46_463_, materialmg0_.C_Project_ID as C_Proje47_463_, materialmg0_.C_Campaign_ID as C_Campa48_463_, materialmg0_.C_Activity_ID as C_Activ49_463_, materialmg0_.User1_ID as User50_463_, materialmg0_.User2_ID as User51_463_, materialmg0_.UpdateLines as UpdateL52_463_, materialmg0_.Islogistic as Islogis53_463_, materialmg0_.Calculate_Freight as Calcula54_463_, materialmg0_.Delivery_Location_ID as Deliver55_463_, materialmg0_.M_FreightCategory_ID as M_Freig56_463_, materialmg0_.Freight_Currency_ID as Freight57_463_, materialmg0_.RM_Receipt_PickEdit as RM_Rece58_463_, materialmg0_.RM_Shipment_Pickedit as RM_Ship59_463_, materialmg0_.EM_Obcma_C_Poc_Email_ID as EM_Obcm60_463_, materialmg0_.M_Condition_Goods_ID as M_Condi61_463_, materialmg0_.A_Asset_ID as A_Asset62_463_, materialmg0_.C_Costcenter_ID as C_Costc63_463_, materialmg0_.Process_Goods_Java as Process64_463_, materialmg0_.Isnettingshipment as Isnetti65_463_, materialmg0_.Iscompletelyinvoiced as Iscompl66_463_, materialmg0_.EM_OBMFM_Freight_ID as EM_OBMF67_463_, materialmg0_.EM_Sgpcrm_Securitygroups_ID as EM_Sgpc68_463_, materialmg0_.EM_OBMFM_Delivery_Charges as EM_OBMF69_463_, materialmg0_.Invoicefromshipment as Invoice70_463_, materialmg0_.Bpartner_Extref as Bpartne71_463_, materialmg0_.EM_Prouti_Changebpartner as EM_Prou72_463_, materialmg0_.EM_Prouti_Totalqtyreceived as EM_Prou73_463_, materialmg0_.EM_OBMFM_Deliverynotes as EM_OBMF74_463_, materialmg0_.EM_Prres_Description as EM_Prre75_463_, materialmg0_.EM_Prres_Jsoninfo as EM_Prre76_463_, materialmg0_.EM_Prrgr_Description as EM_Prrg77_463_, materialmg0_.EM_Prrgr_Jsoninfo as EM_Prrg78_463_, materialmg0_.EM_Prouti_Initial_Bp_ID as EM_Prou79_463_, materialmg0_.EM_Prouti_Move_Stock as EM_Prou80_463_, materialmg0_.EM_Prouti_Stock_Moved as EM_Prou81_463_, materialmg0_.EM_Prqr_Execute as EM_Prqr82_463_, materialmg0_.em_prlab_desc as em_prla83_463_ from M_InOut materialmg0_ cross join C_DocType documentty1_ where materialmg0_.C_DocType_ID=documentty1_.C_DocType_ID and (materialmg0_.MovementType in ($43 , $44)) and materialmg0_.Islogistic=$45 and documentty1_.IsReturn=$46 and (materialmg0_.Updated>$1 or materialmg0_.Processed=$47) and (materialmg0_.AD_Org_ID in ($2 , $3 , $4 , $5 , $6 , $7 , $8 , $9 , $10 , $11 , $12 , $13 , $14 , $15 , $16 , $17 , $18 , $19 , $20 , $21 , $22 , $23 , $24 , $25 , $26 , $27 , $28 , $29 , $30 , $31 , $32 , $33 , $34 , $35 , $36 , $37 , $38 , $39)) and (materialmg0_.AD_Client_ID in ($40 , $41)) order by materialmg0_.DocumentNo, materialmg0_.M_InOut_ID limit $42
30d8811b23select fin_paymen0_.Fin_Payment_ID as Fin_Paym1_396_, fin_paymen0_.AD_Client_ID as AD_Clien2_396_, fin_paymen0_.AD_Org_ID as AD_Org_I3_396_, fin_paymen0_.Created as Created4_396_, fin_paymen0_.Createdby as Createdb5_396_, fin_paymen0_.Updated as Updated6_396_, fin_paymen0_.Updatedby as Updatedb7_396_, fin_paymen0_.Isactive as Isactive8_396_, fin_paymen0_.Isreceipt as Isreceip9_396_, fin_paymen0_.C_Bpartner_ID as C_Bpart10_396_, fin_paymen0_.Paymentdate as Payment11_396_, fin_paymen0_.C_Currency_ID as C_Curre12_396_, fin_paymen0_.Amount as Amount13_396_, fin_paymen0_.Writeoffamt as Writeof14_396_, fin_paymen0_.Fin_Paymentmethod_ID as Fin_Pay15_396_, fin_paymen0_.DocumentNo as Documen16_396_, fin_paymen0_.Referenceno as Referen17_396_, fin_paymen0_.Status as Status18_396_, fin_paymen0_.Processed as Process19_396_, fin_paymen0_.Processing as Process20_396_, fin_paymen0_.Posted as Posted21_396_, fin_paymen0_.Description as Descrip22_396_, fin_paymen0_.Fin_Financial_Account_ID as Fin_Fin23_396_, fin_paymen0_.C_DocType_ID as C_DocTy24_396_, fin_paymen0_.C_Project_ID as C_Proje25_396_, fin_paymen0_.C_Campaign_ID as C_Campa26_396_, fin_paymen0_.C_Activity_ID as C_Activ27_396_, fin_paymen0_.User1_ID as User28_396_, fin_paymen0_.User2_ID as User29_396_, fin_paymen0_.Generated_Credit as Generat30_396_, fin_paymen0_.Used_Credit as Used_Cr31_396_, fin_paymen0_.CreatedByAlgorithm as Created32_396_, fin_paymen0_.Finacc_Txn_Convert_Rate as Finacc_33_396_, fin_paymen0_.Finacc_Txn_Amount as Finacc_34_396_, fin_paymen0_.EM_APRM_Process_Payment as EM_APRM35_396_, fin_paymen0_.FIN_Rev_Payment_ID as FIN_Rev36_396_, fin_paymen0_.EM_APRM_Reconcile_Payment as EM_APRM37_396_, fin_paymen0_.EM_Aprm_Add_Scheduledpayments as EM_Aprm38_396_, fin_paymen0_.EM_Aprm_Executepayment as EM_Aprm39_396_, fin_paymen0_.EM_APRM_ReversePayment as EM_APRM40_396_, fin_paymen0_.C_Costcenter_ID as C_Costc41_396_, fin_paymen0_.EM_Aeatsii_Send as EM_Aeat42_396_, fin_paymen0_.EM_Obpos_Paymentdata as EM_Obpo43_396_, fin_paymen0_.EM_Aeatsii_Issent as EM_Aeat44_396_, fin_paymen0_.EM_OBPOS_App_Cashup_ID as EM_OBPO45_396_, fin_paymen0_.EM_Aeatsii_Estado as EM_Aeat46_396_, fin_paymen0_.EM_OBPOS_Applications_ID as EM_OBPO47_396_, fin_paymen0_.EM_Obpos_Rounded_Payment_ID as EM_Obpo48_396_, fin_paymen0_.EM_Obcma_C_Poc_Email_ID as EM_Obcm49_396_ from FIN_Payment fin_paymen0_ where fin_paymen0_.Isreceipt=$43 and (fin_paymen0_.Updated>$1 or fin_paymen0_.Processed=$44) and (fin_paymen0_.AD_Org_ID in ($2 , $3 , $4 , $5 , $6 , $7 , $8 , $9 , $10 , $11 , $12 , $13 , $14 , $15 , $16 , $17 , $18 , $19 , $20 , $21 , $22 , $23 , $24 , $25 , $26 , $27 , $28 , $29 , $30 , $31 , $32 , $33 , $34 , $35 , $36 , $37 , $38 , $39)) and (fin_paymen0_.AD_Client_ID in ($40 , $41)) order by fin_paymen0_.Paymentdate desc, fin_paymen0_.Fin_Payment_ID desc limit $42
75890e23a4SELECT * FROM M_GET_STOCK_PARAM($1, $2, TO_NUMBER($3), $4, $5, $6, $7, $8, $9, $10, $11, $12, $13, $14, $15, $16, TO_NUMBER($17), $18, $19, $20, $21, $22, $23)
8be0d7c1e7UPDATE C_BPARTNER SET SO_CREDITUSED = COALESCE(SO_CREDITUSED,$24) + v_ConvertedAmount, UPDATED = TO_DATE(NOW()) WHERE C_BPARTNER_ID = v_BPartner_ID
43a80059e4SELECT * FROM C_Invoice_Create($8, v_Record_ID)
22615c404bselect invoice0_.C_Invoice_ID as C_Invoic1_260_, invoice0_.AD_Client_ID as AD_Clien2_260_, invoice0_.AD_Org_ID as AD_Org_I3_260_, invoice0_.IsActive as IsActive4_260_, invoice0_.Created as Created5_260_, invoice0_.CreatedBy as CreatedB6_260_, invoice0_.Updated as Updated7_260_, invoice0_.UpdatedBy as UpdatedB8_260_, invoice0_.IsSOTrx as IsSOTrx9_260_, invoice0_.DocumentNo as Documen10_260_, invoice0_.DocStatus as DocStat11_260_, invoice0_.DocAction as DocActi12_260_, invoice0_.Processing as Process13_260_, invoice0_.Processed as Process14_260_, invoice0_.Posted as Posted15_260_, invoice0_.C_DocType_ID as C_DocTy16_260_, invoice0_.C_DocTypeTarget_ID as C_DocTy17_260_, invoice0_.C_Order_ID as C_Order18_260_, invoice0_.Description as Descrip19_260_, invoice0_.IsPrinted as IsPrint20_260_, invoice0_.SalesRep_ID as SalesRe21_260_, invoice0_.DateInvoiced as DateInv22_260_, invoice0_.DatePrinted as DatePri23_260_, invoice0_.DateAcct as DateAcc24_260_, invoice0_.C_BPartner_ID as C_BPart25_260_, invoice0_.C_BPartner_Location_ID as C_BPart26_260_, invoice0_.POReference as PORefer27_260_, invoice0_.IsDiscountPrinted as IsDisco28_260_, invoice0_.DateOrdered as DateOrd29_260_, invoice0_.C_Currency_ID as C_Curre30_260_, invoice0_.C_PaymentTerm_ID as C_Payme31_260_, invoice0_.C_Charge_ID as C_Charg32_260_, invoice0_.ChargeAmt as ChargeA33_260_, invoice0_.TotalLines as TotalLi34_260_, invoice0_.GrandTotal as GrandTo35_260_, invoice0_.M_PriceList_ID as M_Price36_260_, invoice0_.IsTaxIncluded as IsTaxIn37_260_, invoice0_.C_Campaign_ID as C_Campa38_260_, invoice0_.C_Project_ID as C_Proje39_260_, invoice0_.C_Activity_ID as C_Activ40_260_, invoice0_.CreateFrom as CreateF41_260_, invoice0_.GenerateTo as Generat42_260_, invoice0_.AD_User_ID as AD_User43_260_, invoice0_.CopyFrom as CopyFro44_260_, invoice0_.IsSelfService as IsSelfS45_260_, invoice0_.AD_OrgTrx_ID as AD_OrgT46_260_, invoice0_.User1_ID as User47_260_, invoice0_.User2_ID as User48_260_, invoice0_.Withholdingamount as Withhol49_260_, invoice0_.Taxdate as Taxdate50_260_, invoice0_.C_Withholding_ID as C_Withh51_260_, invoice0_.Ispaid as Ispaid52_260_, invoice0_.EM_Einv_Generated as EM_Einv53_260_, invoice0_.Totalpaid as Totalpa54_260_, invoice0_.EM_Einv_Sent as EM_Einv55_260_, invoice0_.OutstandingAmt as Outstan56_260_, invoice0_.DaysTillDue as DaysTil57_260_, invoice0_.DueAmt as DueAmt58_260_, invoice0_.LastCalculatedOnDate as LastCal59_260_, invoice0_.FIN_Paymentmethod_ID as FIN_Pay60_260_, invoice0_.FIN_Payment_Priority_ID as FIN_Pay61_260_, invoice0_.Finalsettlement as Finalse62_260_, invoice0_.Daysoutstanding as Daysout63_260_, invoice0_.Percentageoverdue as Percent64_260_, invoice0_.C_Costcenter_ID as C_Costc65_260_, invoice0_.Calculate_Promotions as Calcula66_260_, invoice0_.A_Asset_ID as A_Asset67_260_, invoice0_.EM_APRM_Addpayment as EM_APRM68_260_, invoice0_.Iscashvat as Iscashv69_260_, invoice0_.EM_APRM_Processinvoice as EM_APRM70_260_, invoice0_.EM_Obcma_C_Poc_Email_ID as EM_Obcm71_260_, invoice0_.Prepaymentamt as Prepaym72_260_, invoice0_.Createfromorders as Createf73_260_, invoice0_.Createfrominouts as Createf74_260_, invoice0_.EM_Advcrm_Newactivity as EM_Advc75_260_, invoice0_.Paidamtatinvoicing as Paidamt76_260_, invoice0_.EM_Obpos_Rounding_Amount as EM_Obpo77_260_, invoice0_.EM_Sgpcrm_Securitygroups_ID as EM_Sgpc78_260_, invoice0_.BPartner_ExtRef as BPartne79_260_, invoice0_.EM_Aeatsii_Send as EM_Aeat80_260_, invoice0_.EM_Obpos_Sequencename as EM_Obpo81_260_, invoice0_.EM_Aeatsii_Issent as EM_Aeat82_260_, invoice0_.EM_Obpos_Sequencenumber as EM_Obpo83_260_, invoice0_.EM_Aeatsii_Fecha_Operacion as EM_Aeat84_260_, invoice0_.EM_Aeatsii_Clave_Tipo as EM_Aeat85_260_, invoice0_.EM_Aeatsii_Motivo_Rectif as EM_Aeat86_260_, invoice0_.EM_Prouti_Recalculate_Price as EM_Prou87_260_, invoice0_.EM_Aeatsii_Clave_Tipo_Fc as EM_Aeat88_260_, invoice0_.EM_Ml_Select_Product as EM_Ml_S89_260_, invoice0_.EM_Prouti_Pricecalculatetdate as EM_Prou90_260_, invoice0_.EM_Aeatsii_Tipo_Rectif as EM_Aeat91_260_, invoice0_.EM_Prouti_Totalizations as EM_Prou92_260_, invoice0_.EM_Aeatsii_Dua as EM_Aeat93_260_, invoice0_.EM_Aeatsii_Fecha_Dua as EM_Aeat94_260_, invoice0_.EM_Aeatsii_Estado as EM_Aeat95_260_, invoice0_.EM_Aeatsii_Error_Registral as EM_Aeat96_260_, invoice0_.EM_Aeatsii_Modif as EM_Aeat97_260_, invoice0_.EM_Aeatsii_Modified as EM_Aeat98_260_, invoice0_.EM_Aeatsii_Description_ID as EM_Aeat99_260_, invoice0_.EM_Aeatsii_Descripcion_Sii as EM_Aea100_260_, invoice0_.EM_Aeatsii_Fecha_Reg_Cont as EM_Aea101_260_, invoice0_.EM_Aeatsii_Dup as EM_Aea102_260_, invoice0_.EM_Aeatsii_Error_Code as EM_Aea103_260_, invoice0_.EM_Aeatsii_Error_Msg as EM_Aea104_260_, invoice0_.EM_Aeatsii_Unsubscribe as EM_Aea105_260_, invoice0_.EM_Aeatsii_Pur_Description_ID as EM_Aea106_260_, invoice0_.EM_Aeatsii_Multi_Dua as EM_Aea107_260_, invoice0_.EM_Aeatsii_Ejercicio as EM_Aea108_260_, invoice0_.EM_Aeatsii_Periodo as EM_Aea109_260_, invoice0_.EM_Aeatsii_Autofactura as EM_Aea110_260_, invoice0_.EM_Aeatsii_Invoice_ID as EM_Aea111_260_, invoice0_.EM_Aeatsii_Insiidate as EM_Aea112_260_, invoice0_.EM_Aeatsii_Cause_Exemption_ID as EM_Aea113_260_, invoice0_.EM_Aeatsii_Isauthorization as EM_Aea114_260_, invoice0_.EM_Aeatsii_Authorizationno as EM_Aea115_260_, invoice0_.EM_Priuti_Createpurchinv as EM_Pri116_260_, invoice0_.EM_Priuti_Generated as EM_Pri117_260_, invoice0_.EM_Priuti_Date_Complete as EM_Pri118_260_, invoice0_.EM_Prges_Expediente_ID as EM_Prg119_260_, invoice0_.EM_Priuti_User_Complete_ID as EM_Pri120_260_, invoice0_.EM_Prges_Annotation_ID as EM_Prg121_260_, invoice0_.EM_Prges_Record_Number as EM_Prg122_260_, invoice0_.EM_Priuti_Status_Of_Review as EM_Pri123_260_, invoice0_.EM_Prges_Grantotal as EM_Prg124_260_, invoice0_.EM_Priuti_Validate as EM_Pri125_260_, invoice0_.EM_Priuti_Start_Review as EM_Pri126_260_, invoice0_.EM_Prges_Poreference as EM_Prg127_260_, invoice0_.em_cactl_createfromship as em_cac128_260_ from C_Invoice invoice0_ left outer join FIN_Payment_Schedule finpayment1_ on invoice0_.C_Invoice_ID=finpayment1_.C_Invoice_ID where invoice0_.Processed='Y' and (invoice0_.Ispaid='N' or finpayment1_.Updated>=invoice0_.LastCalculatedOnDate or invoice0_.OutstandingAmt<>0 or invoice0_.Finalsettlement is null) and invoice0_.IsActive='Y'
d817a62e25select order0_.C_Order_ID as C_Order_1_276_, order0_.AD_Client_ID as AD_Clien2_276_, order0_.AD_Org_ID as AD_Org_I3_276_, order0_.IsActive as IsActive4_276_, order0_.Created as Created5_276_, order0_.CreatedBy as CreatedB6_276_, order0_.Updated as Updated7_276_, order0_.UpdatedBy as UpdatedB8_276_, order0_.IsSOTrx as IsSOTrx9_276_, order0_.DocumentNo as Documen10_276_, order0_.DocStatus as DocStat11_276_, order0_.DocAction as DocActi12_276_, order0_.Processing as Process13_276_, order0_.Processed as Process14_276_, order0_.C_DocType_ID as C_DocTy15_276_, order0_.C_DocTypeTarget_ID as C_DocTy16_276_, order0_.Description as Descrip17_276_, order0_.IsDelivered as IsDeliv18_276_, order0_.IsInvoiced as IsInvoi19_276_, order0_.IsPrinted as IsPrint20_276_, order0_.IsSelected as IsSelec21_276_, order0_.SalesRep_ID as SalesRe22_276_, order0_.DateOrdered as DateOrd23_276_, order0_.DatePromised as DatePro24_276_, order0_.DatePrinted as DatePri25_276_, order0_.DateAcct as DateAcc26_276_, order0_.C_BPartner_ID as C_BPart27_276_, order0_.BillTo_ID as BillTo_28_276_, order0_.C_BPartner_Location_ID as C_BPart29_276_, order0_.POReference as PORefer30_276_, order0_.IsDiscountPrinted as IsDisco31_276_, order0_.C_Currency_ID as C_Curre32_276_, order0_.PaymentRule as Payment33_276_, order0_.C_PaymentTerm_ID as C_Payme34_276_, order0_.InvoiceRule as Invoice35_276_, order0_.DeliveryRule as Deliver36_276_, order0_.FreightCostRule as Freight37_276_, order0_.FreightAmt as Freight38_276_, order0_.DeliveryViaRule as Deliver39_276_, order0_.M_Shipper_ID as M_Shipp40_276_, order0_.C_Charge_ID as C_Charg41_276_, order0_.ChargeAmt as ChargeA42_276_, order0_.PriorityRule as Priorit43_276_, order0_.TotalLines as TotalLi44_276_, order0_.GrandTotal as GrandTo45_276_, order0_.M_Warehouse_ID as M_Wareh46_276_, order0_.M_PriceList_ID as M_Price47_276_, order0_.IsTaxIncluded as IsTaxIn48_276_, order0_.C_Campaign_ID as C_Campa49_276_, order0_.C_Project_ID as C_Proje50_276_, order0_.C_Activity_ID as C_Activ51_276_, order0_.Posted as Posted52_276_, order0_.AD_User_ID as AD_User53_276_, order0_.CopyFrom as CopyFro54_276_, order0_.DropShip_BPartner_ID as DropShi55_276_, order0_.DropShip_Location_ID as DropShi56_276_, order0_.DropShip_User_ID as DropShi57_276_, order0_.IsSelfService as IsSelfS58_276_, order0_.AD_OrgTrx_ID as AD_OrgT59_276_, order0_.User1_ID as User60_276_, order0_.User2_ID as User61_276_, order0_.Deliverynotes as Deliver62_276_, order0_.C_Incoterms_ID as C_Incot63_276_, order0_.Incotermsdescription as Incoter64_276_, order0_.Generatetemplate as Generat65_276_, order0_.Delivery_Location_ID as Deliver66_276_, order0_.CopyFromPO as CopyFro67_276_, order0_.FIN_Paymentmethod_ID as FIN_Pay68_276_, order0_.FIN_Payment_Priority_ID as FIN_Pay69_276_, order0_.RM_PickFromShipment as RM_Pick70_276_, order0_.RM_ReceiveMaterials as RM_Rece71_276_, order0_.EM_Obcma_C_Poc_Email_ID as EM_Obcm72_276_, order0_.RM_CreateInvoice as RM_Crea73_276_, order0_.C_Return_Reason_ID as C_Retur74_276_, order0_.RM_AddOrphanLine as RM_AddO75_276_, order0_.A_Asset_ID as A_Asset76_276_, order0_.Calculate_Promotions as Calcula77_276_, order0_.C_Costcenter_ID as C_Costc78_276_, order0_.Convertquotation as Convert79_276_, order0_.C_Reject_Reason_ID as C_Rejec80_276_, order0_.validuntil as validun81_276_, order0_.Quotation_ID as Quotati82_276_, order0_.SO_Res_Status as SO_Res_83_276_, order0_.Create_POLines as Create_84_276_, order0_.EM_Obdisc_Addpack as EM_Obdi85_276_, order0_.Iscashvat as Iscashv86_276_, order0_.EM_OBMFM_Selectfreight as EM_OBMF87_276_, order0_.EM_OBMFM_Delivery_Period_ID as EM_OBMF88_276_, order0_.RM_Pickfromreceipt as RM_Pick89_276_, order0_.Cancelandreplace as Cancela90_276_, order0_.EM_Advcrm_Newactivity as EM_Advc91_276_, order0_.EM_APRM_AddPayment as EM_APRM92_276_, order0_.EM_OBMFM_Delivery_Charges as EM_OBMF93_276_, order0_.EM_OBMFM_Freight_ID as EM_OBMF94_276_, order0_.EM_Obwpl_Generatepicking as EM_Obwp95_276_, order0_.EM_Advcrm_Opportunity_ID as EM_Advc96_276_, order0_.EM_OBMFM_Weight as EM_OBMF97_276_, order0_.EM_Obwpl_Isinpickinglist as EM_Obwp98_276_, order0_.EM_Rcinv_Contractdate as EM_Rcin99_276_, order0_.EM_Obwpl_Readypl as EM_Obw100_276_, order0_.EM_Rcinv_Initialdate as EM_Rci101_276_, order0_.EM_Rcinv_Enddate as EM_Rci102_276_, order0_.EM_Sgpcrm_Securitygroups_ID as EM_Sgp103_276_, order0_.EM_OBMFM_Weight_Uom_ID as EM_OBM104_276_, order0_.EM_Rcinv_Frequency as EM_Rci105_276_, order0_.EM_OBMFM_Set_Weight as EM_OBM106_276_, order0_.EM_Rcinv_Renewautomatically as EM_Rci107_276_, order0_.EM_Aeatsii_Fecha_Operacion as EM_Aea108_276_, order0_.EM_Ml_Select_Product as EM_Ml_109_276_, order0_.EM_Rcinv_Renovationtimes as EM_Rci110_276_, order0_.Confirmcancelandreplace as Confir111_276_, order0_.EM_Aeatsii_Descripcion_Sii as EM_Aea112_276_, order0_.EM_Obpos_Applications_ID as EM_Obp113_276_, order0_.EM_Rcinv_Freqrenovationtime as EM_Rci114_276_, order0_.EM_Obpos_Sendemail as EM_Obp115_276_, order0_.EM_Rcinv_Ordercontract_ID as EM_Rci116_276_, order0_.EM_Obpos_Email_Status as EM_Obp117_276_, order0_.EM_Rcinv_Freqtime as EM_Rci118_276_, order0_.Cancelledorder_id as Cancel119_276_, order0_.EM_Obpos_App_Cashup_ID as EM_Obp120_276_, order0_.EM_Obpos_Createdabsolute as EM_Obp121_276_, order0_.Replacedorder_id as Replac122_276_, order0_.EM_OBPOS_NotInvoiceOnCashUp as EM_OBP123_276_, order0_.EM_Obpos_Rejected_Quotat_ID as EM_Obp124_276_, order0_.EM_Obpos_Isdeleted as EM_Obp125_276_, order0_.Iscancelled as Iscanc126_276_, order0_.EM_Obpos_Islayaway as EM_Obp127_276_, order0_.EM_Obpos_Prepaymentamt as EM_Obp128_276_, order0_.Replacementorder_ID as Replac129_276_, order0_.EM_Obpos_Prepaymentlimitamt as EM_Obp130_276_, order0_.EM_Obpos_Prepaymentlaylimitamt as EM_Obp131_276_, order0_.EM_Obpos_Rounding_Amount as EM_Obp132_276_, order0_.BPartner_ExtRef as BPartn133_276_, order0_.EM_Obpos_Sequencename as EM_Obp134_276_, order0_.EM_Prqc_Clauses_Selector as EM_Prq135_276_, order0_.EM_Obpos_Sequencenumber as EM_Obp136_276_, order0_.EM_Rcinv_Cancelcontract as EM_Rci137_276_, order0_.EM_Rcinv_Cancelleddate as EM_Rci138_276_, order0_.EM_Rcinv_Iscancelled as EM_Rci139_276_, order0_.EM_Psat_Activity_ID as EM_Psa140_276_, order0_.EM_OBSMAIL_EmailAddress as EM_OBS141_276_, order0_.EM_Prouti_Order_Stock as EM_Pro142_276_, order0_.EM_Prouti_Pregenerate_Minout as EM_Pro143_276_, order0_.EM_Prouti_Sotopo as EM_Pro144_276_, order0_.EM_Prouti_Generate_Pick_Inv as EM_Pro145_276_, order0_.EM_Pricm_Order_ID as EM_Pri146_276_, order0_.EM_Prouti_Order_ID as EM_Pro147_276_, order0_.EM_Prouti_Grandtotalinitial as EM_Pro148_276_, order0_.EM_Prouti_Dateclosed as EM_Pro149_276_, order0_.EM_Prouti_Totallinesinitial as EM_Pro150_276_, order0_.EM_Prouti_Changebpartner as EM_Pro151_276_, order0_.EM_Prouti_Recalculate_Price as EM_Pro152_276_, order0_.em_prqr_execute as em_prq153_276_, order0_.EM_Prouti_Pricecalculatetdate as EM_Pro154_276_, order0_.EM_Prqr_Execute_Purchase as EM_Prq155_276_, order0_.EM_Prouti_Reactiveorder as EM_Pro156_276_, order0_.EM_Prqr_Return_Select_Prod as EM_Prq157_276_, order0_.EM_Prouti_Totalizations as EM_Pro158_276_, order0_.em_prouti_Invoiced as em_pro159_276_, order0_.em_prouti_Received as em_pro160_276_, order0_.em_prouti_initial_received as em_pro161_276_, order0_.EM_Prouti_Status_Of_Review as EM_Pro162_276_, order0_.EM_Prouti_Validate_Order as EM_Pro163_276_, order0_.EM_Prouti_Start_Review as EM_Pro164_276_, order0_.EM_Ml_Select_Product_Byattrib as EM_Ml_165_276_, order0_.EM_Prres_Reservation_ID as EM_Prr166_276_, order0_.EM_Prres_Responsible_ID as EM_Prr167_276_, order0_.EM_Prres_Diners as EM_Prr168_276_, order0_.EM_Prres_Sended as EM_Prr169_276_, order0_.EM_Prres_Printed as EM_Prr170_276_, order0_.EM_Prouti_Initial_Bp_ID as EM_Pro171_276_, order0_.EM_Prouti_Addlines_Btn as EM_Pro172_276_, order0_.EM_Prtoma_Tomaticket_ID as EM_Prt173_276_, order0_.EM_Cactl_IsCopy as EM_Cac174_276_, order0_.EM_Prtoma_Jsonorder as EM_Prt175_276_, order0_.EM_Prres_Paid_On_Credit as EM_Prr176_276_, order0_.EM_Prtoma_Grossamount as EM_Prt177_276_, order0_.EM_Cactl_Internal_Notes_Group as EM_Cac178_276_, order0_.EM_Prouti_Changebpartner_Bgt as EM_Pro179_276_, order0_.EM_Prrgr_Locator_ID as EM_Prr180_276_, order0_.EM_Paytef_Transactionreference as EM_Pay181_276_, order0_.EM_Cactl_Indirect_Cost_ID as EM_Cac182_276_, order0_.EM_Cactl_Calculate_Cost as EM_Cac183_276_, order0_.EM_Cactl_Totalcost as EM_Cac184_276_, order0_.EM_Cactl_Forceselectedproject as EM_Cac185_276_, order0_.EM_Cactl_Verified_Return as EM_Cac186_276_, order0_.EM_Cactl_Duplicate_Budget as EM_Cac187_276_, order0_.EM_Prres_Orig_Order_ID as EM_Prr188_276_, order0_.EM_Prcpr_Is_Cloned as EM_Prc189_276_, order0_.EM_Prouti_Select_Soline as EM_Pro190_276_, order0_.EM_Prouti_Return_Quantity as EM_Pro191_276_, order0_.EM_Prqr_Executecredit as EM_Prq192_276_, order0_.Em_Prqr_Credit_Purchase_ID as Em_Prq193_276_ from C_Order order0_ cross join C_DocType documentty1_ where order0_.C_DocTypeTarget_ID=documentty1_.C_DocType_ID and order0_.IsSOTrx=$43 and documentty1_.IsReturn=$44 and (order0_.Updated>$1 or order0_.Processed=$45) and (order0_.AD_Org_ID in ($2 , $3 , $4 , $5 , $6 , $7 , $8 , $9 , $10 , $11 , $12 , $13 , $14 , $15 , $16 , $17 , $18 , $19 , $20 , $21 , $22 , $23 , $24 , $25 , $26 , $27 , $28 , $29 , $30 , $31 , $32 , $33 , $34 , $35 , $36 , $37 , $38 , $39)) and (order0_.AD_Client_ID in ($40 , $41)) order by order0_.DocumentNo, order0_.C_Order_ID limit $42
6e47e0b2e7select passinst.value as pass, m_product.name as name, m_product.em_prpass_doc_required as requiresDocumentation , coalesce(co.documentno,$1) as ticket, case when pt.slot_type = $2 then ptr.date::date else (ptr.date::date || $3 || ptd.hour::time)::timestamp end as hour, pt.slot_type as slot_type, passinst.unlimited as unlimited from prpass_pass_inst passinst join m_product on m_product.m_product_id=passinst.m_product_id left join c_order co on co.c_order_id = passinst.c_order_id left join prpass_timeslots_res ptr on ptr.prpass_timeslots_res_id = passinst.prpass_timeslots_res_id left join prpass_timeslots_detail ptd on ptd.prpass_timeslots_detail_id = ptr.prpass_timeslots_detail_id left join prpass_timeslots pt on pt.prpass_timeslots_id = ptd.prpass_timeslots_id where (passinst.status NOT IN ($4,$5,$6,$7) AND case when m_product.em_prpass_org_selection=$8 then (exists (select $9 from prpass_organization passorg where passorg.m_product_id=m_product.m_product_id and passorg.ad_orgtrx_id=$10)) else (not exists (select $11 from prpass_organization passorg where passorg.m_product_id=m_product.m_product_id and passorg.ad_orgtrx_id=$12)) end AND case when passinst.unlimited != $13 then not exists (select $14 from prpass_pass_trans passtrans where passtrans.prpass_pass_inst_id=passinst.prpass_pass_inst_id and passtrans.ad_validation_org_id=$15) else $16=$17 end) and (m_product.em_prpass_ispass is not null and m_product.em_prpass_ispass = $18 and m_product.isactive = $19) and (m_product.em_prpass_datefrom is null or m_product.em_prpass_datefrom <= CURRENT_DATE) and (m_product.em_prpass_dateto is null or m_product.em_prpass_dateto >= CURRENT_DATE)
8fe405377bSELECT * FROM M_Inout_Create($8, v_Record_ID, $9, $10)
784dd58a53SELECT $2 FROM ONLY "public"."c_uom" x WHERE "c_uom_id"::pg_catalog.text OPERATOR(pg_catalog.=) $1::pg_catalog.text FOR KEY SHARE OF x
1266b03316COPY public.prpass_pass_trans_hist (prpass_pass_trans_hist_id, ad_client_id, ad_org_id, isactive, created, createdby, updated, updatedby, prpass_pass_inst_hist_id, ad_validation_org_id, ad_validation_user_id, obpos_applications_id) TO stdout
0a99da7198SELECT AD_EXTENSION_POINT_HANDLER(v_ep_instance, v_extension_point_id)
096068c9bdSELECT COUNT(*) AS ID FROM C_OrderLine WHERE Replacedorderline_id = $1 AND EXISTS (SELECT $2 FROM C_Order WHERE C_Order.C_Order_ID = C_OrderLine.C_Order_ID AND C_Order.IsSOTrx=$3 and exists ( select $4 from C_DocType where C_DocType_ID = C_Order.C_DocTypeTarget_ID and isreturn=$5)) AND AD_ORG_ID IN ($6,$7,$8,$9,$10,$11,$12,$13,$14,$15,$16,$17,$18,$19,$20,$21,$22,$23,$24,$25,$26,$27,$28,$29,$30,$31,$32,$33,$34,$35,$36,$37,$38,$39,$40,$41,$42,$43) AND AD_CLIENT_ID IN ($44)
4dea79c24dselect invoice0_.C_Invoice_ID as C_Invoic1_260_, invoice0_.AD_Client_ID as AD_Clien2_260_, invoice0_.AD_Org_ID as AD_Org_I3_260_, invoice0_.IsActive as IsActive4_260_, invoice0_.Created as Created5_260_, invoice0_.CreatedBy as CreatedB6_260_, invoice0_.Updated as Updated7_260_, invoice0_.UpdatedBy as UpdatedB8_260_, invoice0_.IsSOTrx as IsSOTrx9_260_, invoice0_.DocumentNo as Documen10_260_, invoice0_.DocStatus as DocStat11_260_, invoice0_.DocAction as DocActi12_260_, invoice0_.Processing as Process13_260_, invoice0_.Processed as Process14_260_, invoice0_.Posted as Posted15_260_, invoice0_.C_DocType_ID as C_DocTy16_260_, invoice0_.C_DocTypeTarget_ID as C_DocTy17_260_, invoice0_.C_Order_ID as C_Order18_260_, invoice0_.Description as Descrip19_260_, invoice0_.IsPrinted as IsPrint20_260_, invoice0_.SalesRep_ID as SalesRe21_260_, invoice0_.DateInvoiced as DateInv22_260_, invoice0_.DatePrinted as DatePri23_260_, invoice0_.DateAcct as DateAcc24_260_, invoice0_.C_BPartner_ID as C_BPart25_260_, invoice0_.C_BPartner_Location_ID as C_BPart26_260_, invoice0_.POReference as PORefer27_260_, invoice0_.IsDiscountPrinted as IsDisco28_260_, invoice0_.DateOrdered as DateOrd29_260_, invoice0_.C_Currency_ID as C_Curre30_260_, invoice0_.C_PaymentTerm_ID as C_Payme31_260_, invoice0_.C_Charge_ID as C_Charg32_260_, invoice0_.ChargeAmt as ChargeA33_260_, invoice0_.TotalLines as TotalLi34_260_, invoice0_.GrandTotal as GrandTo35_260_, invoice0_.M_PriceList_ID as M_Price36_260_, invoice0_.IsTaxIncluded as IsTaxIn37_260_, invoice0_.C_Campaign_ID as C_Campa38_260_, invoice0_.C_Project_ID as C_Proje39_260_, invoice0_.C_Activity_ID as C_Activ40_260_, invoice0_.CreateFrom as CreateF41_260_, invoice0_.GenerateTo as Generat42_260_, invoice0_.AD_User_ID as AD_User43_260_, invoice0_.CopyFrom as CopyFro44_260_, invoice0_.IsSelfService as IsSelfS45_260_, invoice0_.AD_OrgTrx_ID as AD_OrgT46_260_, invoice0_.User1_ID as User47_260_, invoice0_.User2_ID as User48_260_, invoice0_.Withholdingamount as Withhol49_260_, invoice0_.Taxdate as Taxdate50_260_, invoice0_.C_Withholding_ID as C_Withh51_260_, invoice0_.Ispaid as Ispaid52_260_, invoice0_.EM_Einv_Generated as EM_Einv53_260_, invoice0_.Totalpaid as Totalpa54_260_, invoice0_.EM_Einv_Sent as EM_Einv55_260_, invoice0_.OutstandingAmt as Outstan56_260_, invoice0_.DaysTillDue as DaysTil57_260_, invoice0_.DueAmt as DueAmt58_260_, invoice0_.LastCalculatedOnDate as LastCal59_260_, invoice0_.FIN_Paymentmethod_ID as FIN_Pay60_260_, invoice0_.FIN_Payment_Priority_ID as FIN_Pay61_260_, invoice0_.Finalsettlement as Finalse62_260_, invoice0_.Daysoutstanding as Daysout63_260_, invoice0_.Percentageoverdue as Percent64_260_, invoice0_.C_Costcenter_ID as C_Costc65_260_, invoice0_.Calculate_Promotions as Calcula66_260_, invoice0_.A_Asset_ID as A_Asset67_260_, invoice0_.EM_APRM_Addpayment as EM_APRM68_260_, invoice0_.Iscashvat as Iscashv69_260_, invoice0_.EM_APRM_Processinvoice as EM_APRM70_260_, invoice0_.EM_Obcma_C_Poc_Email_ID as EM_Obcm71_260_, invoice0_.Prepaymentamt as Prepaym72_260_, invoice0_.Createfromorders as Createf73_260_, invoice0_.Createfrominouts as Createf74_260_, invoice0_.EM_Advcrm_Newactivity as EM_Advc75_260_, invoice0_.Paidamtatinvoicing as Paidamt76_260_, invoice0_.EM_Obpos_Rounding_Amount as EM_Obpo77_260_, invoice0_.EM_Sgpcrm_Securitygroups_ID as EM_Sgpc78_260_, invoice0_.BPartner_ExtRef as BPartne79_260_, invoice0_.EM_Aeatsii_Send as EM_Aeat80_260_, invoice0_.EM_Obpos_Sequencename as EM_Obpo81_260_, invoice0_.EM_Aeatsii_Issent as EM_Aeat82_260_, invoice0_.EM_Obpos_Sequencenumber as EM_Obpo83_260_, invoice0_.EM_Aeatsii_Fecha_Operacion as EM_Aeat84_260_, invoice0_.EM_Aeatsii_Clave_Tipo as EM_Aeat85_260_, invoice0_.EM_Aeatsii_Motivo_Rectif as EM_Aeat86_260_, invoice0_.EM_Prouti_Recalculate_Price as EM_Prou87_260_, invoice0_.EM_Aeatsii_Clave_Tipo_Fc as EM_Aeat88_260_, invoice0_.EM_Ml_Select_Product as EM_Ml_S89_260_, invoice0_.EM_Prouti_Pricecalculatetdate as EM_Prou90_260_, invoice0_.EM_Aeatsii_Tipo_Rectif as EM_Aeat91_260_, invoice0_.EM_Prouti_Totalizations as EM_Prou92_260_, invoice0_.EM_Aeatsii_Dua as EM_Aeat93_260_, invoice0_.EM_Aeatsii_Fecha_Dua as EM_Aeat94_260_, invoice0_.EM_Aeatsii_Estado as EM_Aeat95_260_, invoice0_.EM_Aeatsii_Error_Registral as EM_Aeat96_260_, invoice0_.EM_Aeatsii_Modif as EM_Aeat97_260_, invoice0_.EM_Aeatsii_Modified as EM_Aeat98_260_, invoice0_.EM_Aeatsii_Description_ID as EM_Aeat99_260_, invoice0_.EM_Aeatsii_Descripcion_Sii as EM_Aea100_260_, invoice0_.EM_Aeatsii_Fecha_Reg_Cont as EM_Aea101_260_, invoice0_.EM_Aeatsii_Dup as EM_Aea102_260_, invoice0_.EM_Aeatsii_Error_Code as EM_Aea103_260_, invoice0_.EM_Aeatsii_Error_Msg as EM_Aea104_260_, invoice0_.EM_Aeatsii_Unsubscribe as EM_Aea105_260_, invoice0_.EM_Aeatsii_Pur_Description_ID as EM_Aea106_260_, invoice0_.EM_Aeatsii_Multi_Dua as EM_Aea107_260_, invoice0_.EM_Aeatsii_Ejercicio as EM_Aea108_260_, invoice0_.EM_Aeatsii_Periodo as EM_Aea109_260_, invoice0_.EM_Aeatsii_Autofactura as EM_Aea110_260_, invoice0_.EM_Aeatsii_Invoice_ID as EM_Aea111_260_, invoice0_.EM_Aeatsii_Insiidate as EM_Aea112_260_, invoice0_.EM_Aeatsii_Cause_Exemption_ID as EM_Aea113_260_, invoice0_.EM_Aeatsii_Isauthorization as EM_Aea114_260_, invoice0_.EM_Aeatsii_Authorizationno as EM_Aea115_260_, invoice0_.EM_Priuti_Createpurchinv as EM_Pri116_260_, invoice0_.EM_Priuti_Generated as EM_Pri117_260_, invoice0_.EM_Priuti_Date_Complete as EM_Pri118_260_, invoice0_.EM_Prges_Expediente_ID as EM_Prg119_260_, invoice0_.EM_Priuti_User_Complete_ID as EM_Pri120_260_, invoice0_.EM_Prges_Annotation_ID as EM_Prg121_260_, invoice0_.EM_Prges_Record_Number as EM_Prg122_260_, invoice0_.EM_Priuti_Status_Of_Review as EM_Pri123_260_, invoice0_.EM_Prges_Grantotal as EM_Prg124_260_, invoice0_.EM_Priuti_Validate as EM_Pri125_260_, invoice0_.EM_Priuti_Start_Review as EM_Pri126_260_, invoice0_.EM_Prges_Poreference as EM_Prg127_260_, invoice0_.em_cactl_createfromship as em_cac128_260_ from C_Invoice invoice0_ where invoice0_.IsSOTrx=$43 and invoice0_.DocStatus<>$44 and (invoice0_.Updated>$1 or invoice0_.Processed=$45) and (invoice0_.AD_Org_ID in ($2 , $3 , $4 , $5 , $6 , $7 , $8 , $9 , $10 , $11 , $12 , $13 , $14 , $15 , $16 , $17 , $18 , $19 , $20 , $21 , $22 , $23 , $24 , $25 , $26 , $27 , $28 , $29 , $30 , $31 , $32 , $33 , $34 , $35 , $36 , $37 , $38 , $39)) and (invoice0_.AD_Client_ID in ($40 , $41)) order by invoice0_.OutstandingAmt, invoice0_.C_Invoice_ID limit $42
2bbd1014edSELECT $2 FROM ONLY "public"."c_doctype" x WHERE "c_doctype_id"::pg_catalog.text OPERATOR(pg_catalog.=) $1::pg_catalog.text FOR KEY SHARE OF x
b91bad558ainsert into ad_context_info (ad_user_id, ad_session_id, processType, processId) values ($1, $2, $3, $4)
6aeca8addcSELECT * FROM (select fa.fin_financial_account_id AS referencekey_id, ad_column_identifier_std($2, fa.fin_financial_account_id) AS record_id, $3 AS ad_role_id, $4 AS ad_user_id, $5 || fa.name || $6 || fa.currentbalance || $7 || (fa.initialbalance + (select sum(depositamt) - sum(paymentamt) from fin_finacc_transaction where fa.fin_financial_account_id=fin_finacc_transaction.fin_financial_account_id and fin_finacc_transaction.processed=$8)) || $9|| fa.currentbalance- (fa.initialbalance + (select sum(depositamt) - sum(paymentamt) from fin_finacc_transaction where fa.fin_financial_account_id=fin_finacc_transaction.fin_financial_account_id and fin_finacc_transaction.processed=$10)) AS description, $11 AS isActive, $12 AS ad_org_id, fa.ad_client_id AS ad_client_id, now() AS created, $13 AS createdBy, now() AS updated, $14 AS updatedBy from fin_financial_account fa where fa.currentbalance <> fa.initialbalance + (select sum(depositamt) - sum(paymentamt) from fin_finacc_transaction where fa.fin_financial_account_id=fin_finacc_transaction.fin_financial_account_id and fin_finacc_transaction.processed=$15)) AAA where not exists (select $16 from ad_alert a where a.ad_alertrule_id = $1 and a.referencekey_id = aaa.referencekey_id and coalesce(a.status, $17) != $18)
12af87b05ainsert into ad_context_info (ad_user_id, ad_session_id, processType, processId) values ($1, $2, $3, $4)
e2c0748a35SELECT * FROM Ad_Sequence_Doc($96, Cur_Order.AD_Client_ID, $97)
4cb9cc1cbfSELECT C_ORDER_POST1($1, $2, $3)
6758866a26insert into obmobc_logclient ( obmobc_logclient_id, ad_client_id, ad_org_id, isactive, created, createdby, updated, updatedby, tstamp, deviceid, context, msg, loglevel, cache_session_id, isonline ) values ( get_uuid(), $1, $2, $14, to_timestamp(to_char($3), to_char($15)), $4, to_timestamp(to_char($5), to_char($16)), $6, to_number($7), $8, $9, $10, $11, $12, $13 )
dca3f71473SELECT NIVEL1, NIVEL2, NIVEL3, NIVEL4, NIVEL5, NIVEL6, NIVEL7, NIVEL8, NIVEL9, SUM(AMOUNT) AS AMOUNT, SUM(QTY) AS QTY, SUM(WEIGHT) AS WEIGHT, SUM(AMOUNTREF) AS AMOUNTREF, SUM(QTYREF) AS QTYREF, SUM(WEIGHTREF) AS WEIGHTREF, SUM(CONVAMOUNT) AS CONVAMOUNT, C_CURRENCY_SYMBOL($1, $7, $8) AS CONVSYM, SUM(CONVAMOUNTREF) AS CONVAMOUNTREF, C_CURRENCY_ISOSYM($2) AS CONVISOSYM FROM (SELECT NIVEL1, NIVEL2, NIVEL3, NIVEL4, NIVEL5, NIVEL6, NIVEL7, NIVEL8, NIVEL9, SUM(LINENETAMT) AS AMOUNT, SUM(MOVEMENTQTY) AS QTY, SUM(WEIGHT) AS WEIGHT, SUM(LINENETREF) AS AMOUNTREF, SUM(MOVEMENTQTYREF) AS QTYREF, SUM(WEIGHTREF) AS WEIGHTREF, C_CURRENCY_CONVERT(SUM(LINENETAMT), TRCURRENCYID, $3, TO_DATE(TRDATE), $9, TRCLIENTID, TRORGID) AS CONVAMOUNT, $10 AS CONVAMOUNTREF, TRCURRENCYID, TRDATE, TRCLIENTID, TRORGID FROM (SELECT to_char(AD_COLUMN_IDENTIFIER(to_char($11), to_char( M_PRODUCT.M_PRODUCT_ID), to_char($12))|| CASE WHEN uomsymbol IS NULL THEN $13 ELSE to_char($14||uomsymbol||$15) END) AS NIVEL1, to_char(AD_ORG.NAME) AS NIVEL2, to_char(M_INOUT.DOCUMENTNO) AS NIVEL3, to_char($16) AS NIVEL4, to_char($17) AS NIVEL5, to_char($18) AS NIVEL6, to_char($19) AS NIVEL7, to_char($20) AS NIVEL8, to_char($21) AS NIVEL9, COALESCE(M_INOUTLINE.MOVEMENTQTY*C_ORDERLINE.PRICEACTUAL,$22) AS LINENETAMT, M_INOUTLINE.MOVEMENTQTY, M_INOUTLINE.MOVEMENTQTY*M_PRODUCT.WEIGHT AS WEIGHT, $23 AS LINENETREF, $24 AS MOVEMENTQTYREF, $25 AS WEIGHTREF, C_UOM.UOMSYMBOL, C_ORDERLINE.C_CURRENCY_ID AS TRCURRENCYID, TO_DATE(COALESCE(C_ORDER.DATEORDERED, NOW())) AS TRDATE, C_ORDERLINE.AD_CLIENT_ID AS TRCLIENTID, C_ORDERLINE.AD_ORG_ID AS TRORGID FROM M_INOUTLINE left join C_ORDERLINE on M_INOUTLINE.C_ORDERLINE_ID = C_ORDERLINE.C_ORDERLINE_ID left join C_ORDER on C_ORDERLINE.C_ORDER_ID = C_ORDER.C_ORDER_ID, M_INOUT left join AD_USER on M_INOUT.SALESREP_ID = AD_USER.AD_USER_ID, C_BPARTNER left join C_BPARTNER CB on C_BPARTNER.SALESREP_ID = CB.C_BPARTNER_ID, C_BP_GROUP, M_PRODUCT, M_PRODUCT_CATEGORY, M_WAREHOUSE, C_UOM, AD_ORG WHERE M_INOUT.C_BPARTNER_ID = C_BPARTNER.C_BPARTNER_ID AND C_BPARTNER.C_BP_GROUP_ID = C_BP_GROUP.C_BP_GROUP_ID AND M_INOUT.M_INOUT_ID = M_INOUTLINE.M_INOUT_ID AND M_INOUTLINE.M_PRODUCT_ID = M_PRODUCT.M_PRODUCT_ID AND M_PRODUCT.M_PRODUCT_CATEGORY_ID = M_PRODUCT_CATEGORY.M_PRODUCT_CATEGORY_ID AND M_INOUT.M_WAREHOUSE_ID = M_WAREHOUSE.M_WAREHOUSE_ID AND M_INOUTLINE.C_UOM_ID = C_UOM.C_UOM_ID AND M_INOUT.AD_ORG_ID = AD_ORG.AD_ORG_ID AND M_INOUT.ISSOTRX = $26 AND M_INOUT.PROCESSED = $27 AND $28=$29 AND M_INOUT.AD_ORG_ID IN ($30) AND M_INOUT.AD_CLIENT_ID IN ($31,$32) AND $33=$34 AND M_INOUT.MOVEMENTDATE >= TO_DATE($4) AND M_INOUT.MOVEMENTDATE < TO_DATE($5) AND M_PRODUCT_CATEGORY.M_PRODUCT_CATEGORY_ID = $6 ) AA GROUP BY NIVEL1, NIVEL2, NIVEL3, NIVEL4, NIVEL5, NIVEL6, NIVEL7, NIVEL8, NIVEL9, TRCURRENCYID, TRDATE, TRCLIENTID, TRORGID) ZZ GROUP BY NIVEL1, NIVEL2, NIVEL3, NIVEL4, NIVEL5, NIVEL6, NIVEL7, NIVEL8, NIVEL9 ORDER BY NIVEL1,NIVEL2,NIVEL3
59ed037ff5UPDATE m_requisitionline rl SET em_cactl_consumption = cactl_calculate_consumption(rl.m_product_id, rl.ad_org_id, rl.ad_client_id) FROM m_requisition r WHERE rl.reqstatus = $1 AND rl.m_requisition_id = r.m_requisition_id AND r.docstatus = $2
8d2c8e833fSELECT NIVEL1, NIVEL2, NIVEL3, NIVEL4, NIVEL5, NIVEL6, NIVEL7, NIVEL8, NIVEL9, SUM(AMOUNT) AS AMOUNT, SUM(QTY) AS QTY, SUM(WEIGHT) AS WEIGHT, SUM(AMOUNTREF) AS AMOUNTREF, SUM(QTYREF) AS QTYREF, SUM(WEIGHTREF) AS WEIGHTREF, SUM(CONVAMOUNT) AS CONVAMOUNT, C_CURRENCY_SYMBOL($1, $7, $8) AS CONVSYM, SUM(CONVAMOUNTREF) AS CONVAMOUNTREF, C_CURRENCY_ISOSYM($2) AS CONVISOSYM FROM (SELECT NIVEL1, NIVEL2, NIVEL3, NIVEL4, NIVEL5, NIVEL6, NIVEL7, NIVEL8, NIVEL9, SUM(LINENETAMT) AS AMOUNT, SUM(MOVEMENTQTY) AS QTY, SUM(WEIGHT) AS WEIGHT, SUM(LINENETREF) AS AMOUNTREF, SUM(MOVEMENTQTYREF) AS QTYREF, SUM(WEIGHTREF) AS WEIGHTREF, C_CURRENCY_CONVERT(SUM(LINENETAMT), TRCURRENCYID, $3, TO_DATE(TRDATE), $9, TRCLIENTID, TRORGID) AS CONVAMOUNT, $10 AS CONVAMOUNTREF, TRCURRENCYID, TRDATE, TRCLIENTID, TRORGID FROM (SELECT to_char(AD_COLUMN_IDENTIFIER(to_char($11), to_char( M_PRODUCT.M_PRODUCT_ID), to_char($12))|| CASE WHEN uomsymbol IS NULL THEN $13 ELSE to_char($14||uomsymbol||$15) END) AS NIVEL1, to_char(AD_ORG.NAME) AS NIVEL2, to_char($16) AS NIVEL3, to_char($17) AS NIVEL4, to_char($18) AS NIVEL5, to_char($19) AS NIVEL6, to_char($20) AS NIVEL7, to_char($21) AS NIVEL8, to_char($22) AS NIVEL9, COALESCE(M_INOUTLINE.MOVEMENTQTY*C_ORDERLINE.PRICEACTUAL,$23) AS LINENETAMT, M_INOUTLINE.MOVEMENTQTY, M_INOUTLINE.MOVEMENTQTY*M_PRODUCT.WEIGHT AS WEIGHT, $24 AS LINENETREF, $25 AS MOVEMENTQTYREF, $26 AS WEIGHTREF, C_UOM.UOMSYMBOL, C_ORDERLINE.C_CURRENCY_ID AS TRCURRENCYID, TO_DATE(COALESCE(C_ORDER.DATEORDERED, NOW())) AS TRDATE, C_ORDERLINE.AD_CLIENT_ID AS TRCLIENTID, C_ORDERLINE.AD_ORG_ID AS TRORGID FROM M_INOUTLINE left join C_ORDERLINE on M_INOUTLINE.C_ORDERLINE_ID = C_ORDERLINE.C_ORDERLINE_ID left join C_ORDER on C_ORDERLINE.C_ORDER_ID = C_ORDER.C_ORDER_ID, M_INOUT left join AD_USER on M_INOUT.SALESREP_ID = AD_USER.AD_USER_ID, C_BPARTNER left join C_BPARTNER CB on C_BPARTNER.SALESREP_ID = CB.C_BPARTNER_ID, C_BP_GROUP, M_PRODUCT, M_PRODUCT_CATEGORY, M_WAREHOUSE, C_UOM, AD_ORG WHERE M_INOUT.C_BPARTNER_ID = C_BPARTNER.C_BPARTNER_ID AND C_BPARTNER.C_BP_GROUP_ID = C_BP_GROUP.C_BP_GROUP_ID AND M_INOUT.M_INOUT_ID = M_INOUTLINE.M_INOUT_ID AND M_INOUTLINE.M_PRODUCT_ID = M_PRODUCT.M_PRODUCT_ID AND M_PRODUCT.M_PRODUCT_CATEGORY_ID = M_PRODUCT_CATEGORY.M_PRODUCT_CATEGORY_ID AND M_INOUT.M_WAREHOUSE_ID = M_WAREHOUSE.M_WAREHOUSE_ID AND M_INOUTLINE.C_UOM_ID = C_UOM.C_UOM_ID AND M_INOUT.AD_ORG_ID = AD_ORG.AD_ORG_ID AND M_INOUT.ISSOTRX = $27 AND M_INOUT.PROCESSED = $28 AND $29=$30 AND M_INOUT.AD_ORG_ID IN ($31) AND M_INOUT.AD_CLIENT_ID IN ($32,$33) AND $34=$35 AND M_INOUT.MOVEMENTDATE >= TO_DATE($4) AND M_INOUT.MOVEMENTDATE < TO_DATE($5) AND M_PRODUCT_CATEGORY.M_PRODUCT_CATEGORY_ID = $6 ) AA GROUP BY NIVEL1, NIVEL2, NIVEL3, NIVEL4, NIVEL5, NIVEL6, NIVEL7, NIVEL8, NIVEL9, TRCURRENCYID, TRDATE, TRCLIENTID, TRORGID) ZZ GROUP BY NIVEL1, NIVEL2, NIVEL3, NIVEL4, NIVEL5, NIVEL6, NIVEL7, NIVEL8, NIVEL9 ORDER BY NIVEL1,NIVEL2
0d30ac7710SELECT C_INVOICE_POST($3, p_Invoice_ID)
416d959161SELECT * FROM (SELECT c_order_id AS referencekey_id, ad_column_identifier_std($2, c_order_id) AS record_id, $3 AS ad_role_id, $4 AS ad_user_id, em_prouti_totalizations AS description, $5 AS isActive, ad_org_id, ad_client_id, now() AS created, $6 AS createdBy, now() AS updated, $7 AS updatedBy FROM c_order WHERE em_prouti_totalizations IS NOT NULL) AAA where not exists (select $8 from ad_alert a where a.ad_alertrule_id = $1 and a.referencekey_id = aaa.referencekey_id and coalesce(a.status, $9) != $10)
b280347c9bselect prges_reco0_.Prges_Records_ID as Prges_Re1_831_0_, prges_reco0_.AD_Client_ID as AD_Clien2_831_0_, prges_reco0_.AD_Org_ID as AD_Org_I3_831_0_, prges_reco0_.Created as Created4_831_0_, prges_reco0_.Createdby as Createdb5_831_0_, prges_reco0_.Updated as Updated6_831_0_, prges_reco0_.Updatedby as Updatedb7_831_0_, prges_reco0_.Isactive as Isactive8_831_0_, prges_reco0_.Action as Action9_831_0_, prges_reco0_.Url as Url10_831_0_, prges_reco0_.Jsoninfo as Jsoninf11_831_0_, prges_reco0_.Error as Error12_831_0_, prges_reco0_.Process as Process13_831_0_, prges_reco0_.Status as Status14_831_0_, prges_reco0_.C_Invoice_ID as C_Invoi15_831_0_, prges_reco0_.Prges_Config_ID as Prges_C16_831_0_ from prges_records prges_reco0_ where prges_reco0_.Prges_Records_ID=$1
a29af35ccaUPDATE AD_Sequence SET CurrentNext=CurrentNext + IncrementNo, Updated=TO_DATE(NOW()) WHERE Name=p_SequenceName AND ad_client_id=p_ad_client_id

Schema object statistics

Top tables by estimated sequentially scanned volume

DBTablespaceSchemaTable~SeqBytesSeqScanIxScanIxFetInsUpdDelUpd(HOT)
openbravopg_defaultpublicc_orderline12 TB144465631131158406767510788295591312226
c_orderline(TOAST)
openbravopg_defaultpublicc_order5622 GB741533137593952463957467917392510010
c_order(TOAST)
openbravopg_defaultpublicm_inout497 GB122576668571100099264568108325930
m_inout(TOAST)30741691310380
openbravopg_defaultpg_temp_11ad_context_info363 GB754037539375392
openbravopg_defaultpublicprpass_timeslots_res233 GB915609578890148080221341211915
prpass_timeslots_res(TOAST)
openbravopg_defaultpublicfin_payment_scheduledetail223 GB82273712283367434226051584992
fin_payment_scheduledetail(TOAST)
openbravopg_defaultpublicprpass_pass_inst_hist164 GB29847184468496
prpass_pass_inst_hist(TOAST)
openbravopg_defaultpublicprges_records122 GB12103538933538934147
prges_records(TOAST)256285355489
openbravopg_defaultpublicprpass_pass_inst104 GB171318031935588832098921774984963950
prpass_pass_inst(TOAST)
openbravopg_defaultpublicm_product61 GB619686635081511631647359
m_product(TOAST)
openbravopg_defaultpublicm_storage_detail59 GB210321204762142554471170583866935
m_storage_detail(TOAST)
openbravopg_defaultpublicad_audit_trail50 GB961624373775614
ad_audit_trail(TOAST)
openbravopg_defaultpublicprpass_pass_trans50 GB101390729910797398098446
openbravopg_defaultpublicc_invoice49 GB7568577346265318734405125871119037
c_invoice(TOAST)
openbravopg_defaultpublicc_bpartner34 GB32461102115210139021227611538
c_bpartner(TOAST)
openbravopg_defaultpublicfact_acct31 GB18772310390129331765260353015
fact_acct(TOAST)
openbravopg_defaultpublicfin_payment26 GB74426469391728031402187518597
fin_payment(TOAST)
openbravopg_defaultpublicm_transaction25 GB2250855504055022482477561275
m_transaction(TOAST)
openbravopg_defaultpublicc_invoiceline22 GB35651829152454039100362715482161
c_invoiceline(TOAST)
openbravopg_defaultpublicm_inoutline18 GB357053550149549695610413211391891
m_inoutline(TOAST)

Top tables by blocks fetched

DBTablespaceSchemaTableHeapIxTOASTTOAST-Ix
Blks%TotalBlks%TotalBlks%TotalBlks%Total
openbravopg_defaultpublicc_order373177910833.922779438202.53
openbravopg_defaultpublicc_orderline187018206217.003339326283.04
openbravopg_defaultpublicm_inoutline149684930813.612390034522.17
openbravopg_defaultpublicc_invoice6056716555.512636795162.40
openbravopg_defaultpublicfin_finacc_transaction6556945285.9678519860.07
openbravopg_defaultpublicprpass_timeslots_res6226915595.66171830130.16
openbravopg_defaultpublicfin_payment_schedule1117057521.024197711443.82
openbravopg_defaultpublicm_inout1723442391.572323910872.1166760.00778440.00
openbravopg_defaultpublicc_invoiceline553455650.502270344552.06
openbravopg_defaultpublicm_costing1058268860.9658791410.05
openbravopg_defaultpublicfact_acct888134170.8154333300.05
openbravopg_defaultpublicm_storage_detail584024640.5388455940.08
openbravopg_defaultpublicprpass_pass_trans67420450.06580201160.53
openbravopg_defaultpublicprpass_timeslots_exceptions308783440.28113652320.10
openbravopg_defaultpublicm_product229148550.21179877820.16
openbravopg_defaultpublicfin_payment_scheduledetail298688420.2719427200.02
openbravopg_defaultpublicad_treenode10872420.01264846110.24
openbravopg_defaultpublicm_transaction66540740.06177730030.16
openbravopg_defaultpg_temp_11ad_context_info238797620.22
openbravopg_defaultpublicfin_payment77743410.07157033920.14

Top tables by blocks read

DBTablespaceSchemaTableHeapIxTOASTTOAST-IxHit(%)
Blks%TotalBlks%TotalBlks%TotalBlks%Total
openbravopg_defaultpublicc_orderline25616111949.8228420240.5588.25
openbravopg_defaultpublicc_order13091986325.4651867141.0196.61
openbravopg_defaultpublicc_invoice170751693.3260186571.1797.34
openbravopg_defaultpublicprpass_pass_inst76915651.5032470780.63100.79
openbravopg_defaultpublicfact_acct93318371.8111391500.2288.89
openbravopg_defaultpublicm_inout72680381.4113863750.2742380.0036480.0097.86
openbravopg_defaultpublicm_inoutline64089071.2520994250.4199.51
openbravopg_defaultpublicfin_finacc_transaction55648201.0824879410.4898.79
openbravopg_defaultpublicc_invoiceline48574500.9422448760.4497.48
openbravopg_defaultpublicm_transaction35792140.706444010.1382.71
openbravopg_defaultpublicfin_payment_schedule32791610.645953410.1299.27
openbravopg_defaultpublicfin_payment_scheduledetail26117140.511295640.0391.38
openbravopg_defaultpublicad_audit_trail22628070.44138010.0066.11
openbravopg_defaultpublicprpass_pass_trans6720130.139746290.1997.46
openbravopg_defaultpublicfin_payment15264320.30235040.0093.40
openbravopg_defaultpublicm_productionline12720340.251163540.0290.18
openbravopg_defaultpublicm_costing9708130.191420640.0399.00
openbravopg_defaultpublicprpass_pass_inst_hist7404200.14236720.0096.51
openbravopg_defaultpublicad_image3040.001460.006537500.13132190.0013.83
openbravopg_defaultpublicprpass_pass_trans_hist6164210.12188960.0068.93

Top DML tables

DBTablespaceSchemaTableInsUpdDelUpd(HOT)SeqScanSeqFetIxScanIxFet
openbravopg_defaultpublicobmobc_logclient88842767882147875
obmobc_logclient(TOAST)4262
openbravopg_defaultpg_temp_11ad_context_info75393753927540375402
openbravopg_defaultprofilelast_stat_indexes71003160970992184113596043409427615
openbravopg_defaultpublicc_invoice440512587111903774919470456857734626531873
c_invoice(TOAST)
openbravopg_defaultpublicm_storage_detail471170583866935210310787726721204762142554
m_storage_detail(TOAST)
openbravopg_defaultpublicm_stock_aux25450628982545047143474060274791
m_stock_aux(TOAST)
openbravopg_defaultprofilelast_stat_tables414553672414514718466324885044140448
openbravopg_defaultpublicc_import_entry1296612966129176095106357424901483443
c_import_entry(TOAST)213292132944277183619
openbravopg_defaultpublicm_transaction224824775612752612221912508555040550
m_transaction(TOAST)
openbravopg_defaultpublicad_ep_instance_para348053480558117269042
ad_ep_instance_para(TOAST)
openbravopg_defaultpublicfact_acct3176526035301513805811487723103901293
fact_acct(TOAST)
openbravopg_defaultpg_catalogpg_statistic328893130618471061646485
pg_statistic(TOAST)64956503202948402452
openbravopg_defaultpublicm_productionline149862918892775512007508835147694535926
m_productionline(TOAST)
openbravopg_defaultpublicc_orderline1078829559131222614444202458664656311311584067675
c_orderline(TOAST)
openbravopg_defaultpublicc_import_entry_archive40172925193700151452925
c_import_entry_archive(TOAST)174901538997145506621
openbravopg_defaultpublicprpass_pass_inst98921774984963950171106632813180319355888320
prpass_pass_inst(TOAST)
openbravopg_defaultpublicfin_payment_schedule892226173724263104586655111387640
fin_payment_schedule(TOAST)
openbravopg_defaultpublicfin_payment_scheduledetail43422605158499282595746573273712283367
fin_payment_scheduledetail(TOAST)
openbravopg_defaultprofilelast_stat_user_functions1244315781244375388370044
last_stat_user_functions(TOAST)
openbravopg_defaultpublicfin_payment3140218751859774420752544264693917280
fin_payment(TOAST)

Top tables by updated/deleted tuples

DBTablespaceSchemaTableUpdUpd(HOT)DelVacuumAutoVacuumAnalyzeAutoAnalyze
openbravopg_defaultpublicc_invoice125871190371
c_invoice(TOAST)
openbravopg_defaultpublicm_storage_detail1170586693538419
m_storage_detail(TOAST)
openbravopg_defaultpublicm_stock_aux628984714325450197264
m_stock_aux(TOAST)
openbravopg_defaultpublicobmobc_logclient7678811
obmobc_logclient(TOAST)21
openbravopg_defaultpg_temp_11ad_context_info75392
openbravopg_defaultprofilelast_stat_indexes1609709921604623
openbravopg_defaultpublicm_transaction477561275
m_transaction(TOAST)
openbravopg_defaultpublicc_import_entry1296612917139234
c_import_entry(TOAST)2132946
openbravopg_defaultprofilelast_stat_tables367247414511604623
openbravopg_defaultpg_catalogpg_statistic32889313063
pg_statistic(TOAST)650311
openbravopg_defaultpublicad_ep_instance_para34805523699
ad_ep_instance_para(TOAST)
openbravopg_defaultpublicc_orderline295591222613
c_orderline(TOAST)
openbravopg_defaultpublicm_productionline29188277559
m_productionline(TOAST)
openbravopg_defaultpublicfact_acct260353015
fact_acct(TOAST)
openbravopg_defaultpublicfin_payment_schedule26173426372
fin_payment_schedule(TOAST)
openbravopg_defaultpublicprpass_pass_inst1774939508496
prpass_pass_inst(TOAST)
openbravopg_defaultpublicfin_payment_scheduledetail26051499258
fin_payment_scheduledetail(TOAST)
openbravopg_defaultpg_catalogpg_class2290222887426922
openbravopg_defaultpublicfin_payment2187585971
fin_payment(TOAST)
openbravopg_defaultpublicm_transaction_last19797915

Top growing tables

DBTablespaceSchemaTableSizeGrowthInsUpdDelUpd(HOT)
openbravopg_defaultpublicfact_acct31 GB40 MB31765260353015
fact_acct(TOAST)
openbravopg_defaultpublicc_orderline8683 MB17 MB10788295591312226
c_orderline(TOAST)
openbravopg_defaultpublicm_productionline7867 MB16 MB1498629188927755
m_productionline(TOAST)
openbravopg_defaultpublicc_order7778 MB14 MB467917392510010
c_order(TOAST)
openbravopg_defaultpublicobmobc_logclient1412 MB11 MB8884276788
obmobc_logclient(TOAST)280 kB42
openbravopg_defaultpublicfin_payment_schedule5109 MB7744 kB892226173724263
fin_payment_schedule(TOAST)
openbravopg_defaultpublicc_invoiceline7428 MB6552 kB100362715482161
c_invoiceline(TOAST)
openbravopg_defaultpublicfin_payment_scheduledetail2784 MB6416 kB434226051584992
fin_payment_scheduledetail(TOAST)
openbravopg_defaultpublicm_inout4172 MB5384 kB4568108325930
m_inout(TOAST)30 MB200 kB10380
openbravopg_defaultpublicm_inoutline5979 MB5456 kB10413211391891
m_inoutline(TOAST)
openbravopg_defaultpublicprpass_pass_inst_hist5786 MB4192 kB8496
prpass_pass_inst_hist(TOAST)
openbravopg_defaultpublicfin_finacc_transaction3425 MB3408 kB34911670112980
fin_finacc_transaction(TOAST)
openbravopg_defaultpublicprpass_pass_trans_hist4817 MB2952 kB8446
openbravopg_defaultpublicc_invoicetax2777 MB2424 kB49482859202801
c_invoicetax(TOAST)
openbravopg_defaultpublicad_audit_trail538 MB2048 kB5614
ad_audit_trail(TOAST)
openbravopg_defaultpublicprpass_timeslots_res262 MB944 kB21341211915
prpass_timeslots_res(TOAST)
openbravopg_defaultpublicm_productionplan1241 MB552 kB1158
m_productionplan(TOAST)
openbravopg_defaultpublicc_import_entry576 kB192 kB129661296612917
c_import_entry(TOAST)24 kB8192 bytes2132921329
openbravopg_defaultpg_temp_5ad_context_info40 kB40 kB530529
openbravopg_defaultpublicm_product10 MB8192 bytes47359
m_product(TOAST)

Top indexes by blocks fetched

DBTablespaceSchemaTableIndexScansBlks%Total
openbravopg_defaultpublicfin_payment_schedulefin_payment_schedule_key1042646374181465163.80
openbravopg_defaultpublicm_inoutlinem_inoutline_orderline568230342380518682.16
openbravopg_defaultpublicc_invoicec_invoice_key568090982282164342.07
openbravopg_defaultpublicc_invoicelinec_invoiceline_orderline562979952259719822.05
openbravopg_defaultpublicm_inoutm_inout_key556075952228904502.03
openbravopg_defaultpublicc_orderc_order_key530597902120182871.93
openbravopg_defaultpublicc_orderlineem_obpos_orderedqty486703991961361561.78
openbravopg_defaultpublicc_orderlinec_orderline_key14440009678700070.62
openbravopg_defaultpublicc_orderlinec_orderline_product2348250673587260.61
openbravopg_defaultpublicprpass_pass_transprpass_pass_trans_inst13907267579040370.53
openbravopg_defaultpublicprpass_pass_instprpass_pass_inst_orderline13243815575604500.52
openbravopg_defaultpublicc_orderc_order_client_org_date_docno104974552591840.50
openbravopg_defaultpublicc_invoicec_invoice_client_org_date_doc35036278391580.25
openbravopg_defaultpublicad_treenodead_treenode_tree_node_un1107820264652890.24
openbravopg_defaultpublicm_productm_product_key8649124174120900.16
openbravopg_defaultpublicfin_payment_detailfin_payment_detail_key4350783151136340.14
openbravopg_defaultpublicfin_paymentfin_payment_key4347315151030910.14
openbravopg_defaultpublicm_product_trlm_product_trl_product_langu_un13295134133321290.12
openbravopg_defaultpublicprpass_timeslots_resprpass_tslots_res_date_idx3348283130635260.12
openbravopg_defaultpublicprpass_timeslots_exceptionsprpass_tslots_exc_timeslt_idx2806224109544170.10

Top indexes by blocks read

DBTablespaceSchemaTableIndexScansBlk Reads%TotalHits(%)
openbravopg_defaultpublicc_invoicec_invoice_client_org_date_doc3503650491520.9881.86
openbravopg_defaultpublicprpass_pass_instprpass_pass_inst_value465426863800.5265.69
openbravopg_defaultpublicc_orderc_order_client_org_date_docno10497426840070.5295.14
openbravopg_defaultpublicfin_finacc_transactionfin_finacc_tr_account_line1981024644410.4863.68
openbravopg_defaultpublicc_orderlineem_obpos_orderedqty4867039921536610.4298.90
openbravopg_defaultpublicc_invoicelinec_invoiceline_orderline5629799521126930.4199.07
openbravopg_defaultpublicm_inoutlinem_inoutline_orderline5682303420478800.4099.14
openbravopg_defaultpublicc_orderc_order_documentno_id395212134950.2479.20
openbravopg_defaultpublicm_inoutm_inout_key556075959644570.1999.57
openbravopg_defaultpublicprpass_pass_transprpass_pass_trans_inst139072679559720.1998.35
openbravopg_defaultpublicc_invoicec_invoice_key568090988204480.1699.64
openbravopg_defaultpublicc_orderc_order_key530597907995510.1699.62
openbravopg_defaultpublicc_orderlinec_orderline_key144400096182540.1299.09
openbravopg_defaultpublicfin_payment_schedulefin_payment_schedule_key1042646374909460.1099.88
openbravopg_defaultpublicfact_acctfact_acct_datebalanced64417540.0924.38
openbravopg_defaultpublicfact_acctfact_acct_account35203672520.0762.32
openbravopg_defaultpublicprpass_pass_instprpass_pass_inst_product2463272580.0687.59
openbravopg_defaultpublicfin_payment_detailfin_payment_detail_key43507833047800.0697.98
openbravopg_defaultpublicprpass_pass_instprpass_pass_inst_orderline132438152715360.0599.53
openbravopg_defaultpublicc_orderc_order_dateordered_id11012568120.0572.91

Top growing indexes

DBTablespaceSchemaTableIndexIndexTable
SizeGrowthInsUpdDel
openbravopg_defaultpublicprpass_pass_trans_histprpass_pass_trans_hist_vlo_ix796 MB796 MB8446
openbravopg_defaultpublicprpass_pass_trans_histprpass_pass_trans_hist_ins_ix795 MB795 MB8446
openbravopg_defaultpublicprpass_pass_inst_histprpass_pass_inst_hist_part_ix701 MB701 MB8496
openbravopg_defaultpublicprpass_pass_inst_histprpass_pass_inst_hist_ord_ix701 MB701 MB8496
openbravopg_defaultpublicprpass_pass_inst_histprpass_pass_inst_hist_ol_ix701 MB701 MB8496
openbravopg_defaultpublicprpass_pass_inst_histprpass_pass_inst_hist_prd_ix701 MB701 MB8496
openbravopg_defaultpublicprpass_pass_inst_histprpass_pass_inst_hist_pos_ix602 MB602 MB8496
openbravopg_defaultpublicprpass_pass_trans_histprpass_pass_trans_hist_pos_ix589 MB589 MB8446
openbravopg_defaultpublicprpass_pass_inst_histprpass_pass_inst_hist_val_ix482 MB482 MB8496
openbravopg_defaultpublicprpass_pass_inst_histprpass_pass_inst_hist_sta_ix267 MB267 MB8496
openbravopg_defaultpublicprpass_pass_inst_histprpass_pass_inst_hist_unl_ix267 MB267 MB8496
openbravopg_defaultpublicprpass_pass_inst_histprpass_pass_inst_hist_trs_ix66 MB66 MB8496
openbravopg_defaultpublicfact_acctfact_acct_key2713 MB34 MB31765260353015
openbravopg_defaultpublicfact_acctfact_acct_record_id21726 MB14 MB21014254932756
openbravopg_defaultpublicfin_payment_scheduledetailfin_pay_scheduledetail_or527 MB9776 kB41632080258
openbravopg_defaultpublicfact_acctfact_acct_account5214 MB7256 kB25769255832889
openbravopg_defaultpublicc_orderlineem_obpos_orderedqty914 MB4128 kB107881733313
openbravopg_defaultpublicc_invoicec_invoice_key408 MB2192 kB44051068341
openbravopg_defaultpublicm_productionlinem_productionline_prodplan1165 MB1968 kB9079892
openbravopg_defaultpublicc_invoicec_invoice_client_org_date_doc946 MB1784 kB44051068341

Unused indexes

This table contains non-scanned indexes (during report period), ordered by number of DML operations on underlying tables. Constraint indexes are excluded.

DBTablespacesSchemaTableIndexIndexTable
SizeGrowthInsUpdDel
openbravopg_defaultpublicc_import_entryem_prres_organization_idx1384 kB129581295812913
openbravopg_defaultpg_catalogpg_classpg_class_tblspc_relfilenode_index320 kB1397130
openbravopg_defaultpublicprpass_pass_inst_histprpass_pass_inst_hist_ord_ix701 MB701 MB8496
openbravopg_defaultpublicprpass_pass_inst_histprpass_pass_inst_hist_ol_ix701 MB701 MB8496
openbravopg_defaultpublicprpass_pass_inst_histprpass_pass_inst_hist_part_ix701 MB701 MB8496
openbravopg_defaultpublicprpass_pass_inst_histprpass_pass_inst_hist_pos_ix602 MB602 MB8496
openbravopg_defaultpublicprpass_pass_inst_histprpass_pass_inst_hist_prd_ix701 MB701 MB8496
openbravopg_defaultpublicprpass_pass_inst_histprpass_pass_inst_hist_sta_ix267 MB267 MB8496
openbravopg_defaultpublicprpass_pass_inst_histprpass_pass_inst_hist_unl_ix267 MB267 MB8496
openbravopg_defaultpublicprpass_pass_inst_histprpass_pass_inst_hist_val_ix482 MB482 MB8496
openbravopg_defaultpublicprpass_pass_trans_histprpass_pass_trans_hist_ins_ix795 MB795 MB8446
openbravopg_defaultpublicprpass_pass_trans_histprpass_pass_trans_hist_pos_ix589 MB589 MB8446
openbravopg_defaultpublicprpass_pass_trans_histprpass_pass_trans_hist_vlo_ix796 MB796 MB8446
openbravopg_defaultpublicprpass_timeslots_resprpass_tslots_res_oline_idx54 MB168 kB22313197

User function statistics

Top functions by total time

DBSchemaFunctionExecutionsTime (s)
TotalSelfMeanMean self
openbravopublicad_sequence_doc715712080.5112080.411.6881.688
openbravopublicc_order_post113657680.0314.685.6260.011
openbravopublicc_order_post13607679.740.055.6470.000
openbravopublicc_order_post113607679.690.035.6470.000
openbravopublicm_inout_create11665208.930.044.4670.000
openbravopublicm_inout_create10815206.517.774.8160.007
openbravopublicad_extension_point_handler77062408.933.410.3130.000
openbravopublicc_invoice_create11662360.288.302.0240.007
openbravopublicc_invoice_post12602347.7315.081.8630.012
openbravopublicaprm_gen_paymentschedule_inv12102310.512309.631.9101.909
openbravopubliccactl_calculate_consumption1633710.50710.480.4350.435
openbravopublicto_char350007833610.68610.680.0000.000
openbravopublicto_char284725184407.17407.170.0000.000
openbravopublicto_char20367846199.7099.700.0000.000
openbravopublicpricm_createproductprice544780.7938.880.0150.007
openbravoprofiletake_sample2370.390.013.0600.001
openbravoprofiletake_sample_subset2370.380.143.0600.006
openbravoprofiletake_sample2370.244.543.0540.197
openbravopubliccactl_ep_before_order_price30362.9262.900.2080.208
openbravoprofiledblink62157.7457.740.0930.093

Top functions by executions

DBSchemaFunctionExecutionsTime (s)
TotalSelfMeanMean self
openbravopublicto_char350007833610.68610.680.0000.000
openbravopublicto_char284725184407.17407.170.0000.000
openbravopublicto_char20367846199.7099.700.0000.000
openbravopublicto_char1931969110.3810.380.0000.000
openbravopublicto_date1681099944.8744.870.0000.000
openbravopublicto_number868009014.2614.260.0000.000
openbravopublicsubstract_days56956974.544.540.0000.000
openbravopublicad_istriggerenabled204614913.6313.630.0000.000
openbravopublicadd_days16494162.152.150.0000.000
openbravopublicto_date11982442.552.540.0000.000
openbravopublicad_isorgincluded115129814.0114.010.0000.000
openbravopublicuuid_generate_v46529412.402.400.0000.000
openbravopublicad_org_isinnaturaltree47182113.212.610.0000.000
openbravopublicget_uuid2176474.652.240.0000.000
openbravopublicm_update_inventory11611542.0838.760.0000.000
openbravopublictrunc1146500.240.240.0000.000
openbravopublictrunc1143890.240.240.0000.000
openbravopublicround894130.180.180.0000.000
openbravopublicm_update_stockaux8721815.2414.190.0000.000
openbravopublicobequals694780.290.290.0000.000

Top trigger functions by total time

DBSchemaFunctionExecutionsTime (s)
TotalSelfMeanMean self
openbravopublicpricm_productprice551581.000.140.0150.000
openbravopublicm_productionline_trg4418335.146.510.0010.000
openbravopubliccactl_m_prodline_losses_trg1498621.454.720.0010.000
openbravopubliccactl_product_org4359015.072.370.0000.000
openbravopublicm_transaction_trg7023814.807.900.0000.000
openbravopublicaeatsii_invoice_trg13312810.818.340.0000.000
openbravopublicau_c_order_trg2209210.7510.420.0000.000
openbravopublicc_orderline_trg24035410.713.350.0000.000
openbravopublicc_invoiceline_trg2127997.702.900.0010.000
openbravopublicc_invoice_trg1331294.934.110.0000.000
openbravopublicc_orderline2_trg403684.854.520.0000.000
openbravopublicc_invoice_trg21302763.111.830.0000.000
openbravopublicm_requisitionorder_trg933.053.040.0330.033
openbravopublicm_storage_detail_trg1155912.621.940.0000.000
openbravopublicc_invoicelinetax_trg123032.441.610.0000.000
openbravopublicc_orderlinetax_trg121642.431.980.0000.000
openbravopublicpricm_skipped_transaction_trg224822.302.210.0000.000
openbravopublicc_orderline_trg403622.302.040.0000.000
openbravopublicpriuti_c_invoice_ref_trg1302762.201.480.0000.000
openbravopublicintr_c_orderline_trg403471.970.770.0000.000

Vacuum-related statistics

Top tables by vacuum operations

DBTablespaceSchemaTableVacuum countAutovacuum countInsUpdDelUpd(HOT)
openbravopg_defaultpublicad_ep_instance_para5233480534805
openbravopg_defaultpublicm_stock_aux19725450628982545047143
openbravopg_defaultprofilelast_stat_tables1604145536724145147
openbravopg_defaultprofilelast_stat_indexes16071003160970992
openbravopg_defaultprofilelast_stat_user_functions1601244315781244375
openbravopg_defaultpublicc_import_entry139129661296612917
openbravopg_defaultpublicobre_reservation109509341550811
openbravopg_defaultpublicad_sequence941384813711
openbravopg_defaultpublicobpos_applications7469036828
openbravopg_defaultpublicfin_financial_account4733793373
openbravopg_defaultpublicobre_resource2138953813
openbravopg_defaultpg_catalogpg_class94332290242622887
openbravopg_defaultpublicm_transaction_last9319797
openbravopg_defaultpublicm_storage_detail4471170583866935
openbravopg_defaultpg_catalogpg_statistic33288931306
openbravopg_defaultpg_catalogpg_type2434430
openbravopg_defaultprofilelast_stat_database28888
postgrespg_globalpg_catalogpg_shdepend1188192
openbravopg_globalpg_catalogpg_shdepend1118118
openbravopg_defaultpg_catalogpg_attribute125822591

Top tables by analyze operations

DBTablespaceSchemaTableAnalyze countAutoanalyze countInsUpdDelUpd(HOT)
openbravopg_defaultpublicad_ep_instance_para6993480534805
openbravopg_defaultpublicm_stock_aux26425450628982545047143
openbravopg_defaultpublicc_import_entry234129661296612917
openbravopg_defaultpublicad_sequence1351384813711
openbravopg_defaultpublicobpos_applications10169036828
openbravopg_defaultpublicobre_reservation75509341550811
openbravopg_defaultprofilelast_stat_tables46234145536724145147
openbravopg_defaultprofilelast_stat_indexes462371003160970992
openbravopg_defaultprofilelast_stat_user_functions46231244315781244375
openbravopg_defaultpublicfin_financial_account5133793373
openbravopg_defaultpublicobre_resource4038953813
openbravopg_defaultpg_catalogpg_class224332290242622887
openbravopg_defaultprofilelast_stat_tablespaces204242
openbravopg_defaultpublicm_storage_detail19471170583866935
openbravopg_defaultpublicm_transaction_last15319797
openbravopg_defaultpublicad_session1315395258730
openbravopg_defaultpublicc_bpartner1221227611538
openbravopg_defaultpublicad_process_request15158597184555
openbravopg_defaultpg_catalogpg_type5434430
postgrespg_globalpg_catalogpg_shdepend3188192

Top indexes by estimated vacuum load

DBTablespaceSchemaTableIndex~Vacuum bytesVacuum cntAutovacuum cntIX sizeRelsize
openbravopg_defaultpublicm_stock_auxm_stock_aux_aux_id494 MB1972569 kB4400 kB
openbravopg_defaultpublicobmobc_logclientobmobc_logclient_timestamp292 MB1292 MB1412 MB
openbravopg_defaultpublicobmobc_logclientobmobc_logclient_pk242 MB1242 MB1412 MB
openbravopg_defaultpublicobmobc_logclientobmobc_logclient_cache210 MB1210 MB1412 MB
openbravopg_defaultpublicobmobc_logclientobmobc_logclient_term_date202 MB1202 MB1412 MB
openbravopg_defaultpublicobmobc_logclientobmobc_logclient_context188 MB1188 MB1412 MB
openbravopg_defaultpublicc_import_entryem_prres_organization_idx188 MB1391384 kB1189 kB
openbravopg_defaultpublicad_ep_instance_paraad_ep_instance_para_key176 MB523344 kB32 kB
openbravopg_defaultpublicm_stock_auxm_stock_aux_storage_detail_id131 MB184728 kB4400 kB
openbravopg_defaultpublicc_import_entryc_import_entry_key129 MB139952 kB1189 kB
openbravopg_defaultpublicc_import_entryem_prres_typeofdata_idx123 MB139904 kB1189 kB
openbravopg_defaultpublicc_import_entryc_import_entry_type_status116 MB139856 kB1189 kB
openbravopg_defaultpublicm_stock_auxm_stock_aux_key111 MB184616 kB4400 kB
openbravopg_defaultpublicc_import_entryem_obpos_application_fk106 MB139784 kB1189 kB
openbravopg_defaultpublicc_import_entryc_import_entry_idx92 MB139680 kB1189 kB
openbravopg_defaultprofilelast_stat_indexespk_last_stat_indexes85 MB157552 kB2040 kB
openbravopg_defaultpublicm_storage_detailm_storage_detail_un80 MB420 MB29 MB
openbravopg_defaultpublicm_storage_detailm_storage_detail_uom59 MB415 MB29 MB
openbravopg_defaultpublicm_storage_detailm_storagedet_qtyorderonhand54 MB413 MB29 MB
openbravopg_defaultpublicm_storage_detailm_storage_detail_locator54 MB413 MB29 MB

Top tables by dead tuples ratio

Data in this section is not differential. This data is valid for last report sample only.

DBSchemaTableLiveDead%DeadLast AVSize
openbravopublicprpass_timeslots_res719877136524152026-04-30 12:07:18.698105+01262 MB
openbravopg_toastpg_toast_26192498382132026-07-17 22:32:20.771164+017288 kB
openbravopublicc_invoice7030574971264122026-07-08 00:23:08.546646+017098 MB
openbravopg_toastpg_toast_232469135171930122026-05-19 02:38:47.391039+0130 MB
openbravopublicm_requisitionline31851035608102026-07-06 12:22:50.3815+01184 MB
openbravopublicm_product156861773102026-02-20 19:44:18.669967+0010 MB
openbravopublicfin_finacc_transaction661018068611592026-04-02 14:41:49.577329+013425 MB
openbravopg_catalogpg_statistic10764106482026-07-17 23:48:22.899922+017040 kB
openbravopublicc_order728748368000187778 MB
openbravopublicfin_payment_scheduledetail727419852523662026-03-09 13:29:49.774124+002784 MB
openbravopublicfact_acct38053680279081262025-07-31 23:28:10.407953+0131 GB
openbravopublicc_orderline1441912877189658683 MB
openbravopublicprpass_pass_inst4431072394352026-07-16 21:52:27.999093+016280 MB
openbravoprofilesample_stat_tables27296131242026-07-17 17:00:47.297023+018672 kB
openbravopg_catalogpg_attribute37235144032026-07-17 16:18:46.858639+016840 kB
openbravopublicfin_payment_schedule1417816646583035109 MB
openbravopublicm_inout726119925483032025-10-20 23:54:32.431835+014172 MB
openbravopublicobmobc_logclient25991318024322025-12-16 23:13:25.786307+001412 MB
openbravopublicm_productionline2008812721770117867 MB
openbravopublicprpass_pass_trans552859844612026-07-16 21:39:42.083421+015152 MB

Top tables by modified tuples ratio

Table shows modified tuples statistics since last analyze.

Data in this section is not differential. This data is valid for last report sample only.

DBSchemaTableLiveDeadMod%ModLast AASize
openbravopg_catalogpg_statistic1076410649800022828547040 kB
openbravopublicad_audit_trail21307709019312092026-06-21 20:32:38.637677+01538 MB
openbravopublicm_productionline20088127217701179724782026-04-18 16:29:40.193815+017867 MB
openbravopublicprpass_pass_inst443107239433838582026-07-16 20:25:05.972264+016280 MB
openbravopg_catalogpg_attribute372351440287072026-07-17 16:19:45.769483+016840 kB
openbravopublicfin_payment_schedule14178166465830112854572026-04-22 11:37:34.369148+015109 MB
openbravopublicprpass_pass_inst_hist12365718096853072026-07-16 19:56:26.433478+015786 MB
openbravopublicm_product156861773120162026-07-13 10:43:57.196489+0110 MB
openbravopublicfin_finacc_transaction661018068611536789952026-06-27 12:53:00.341557+013425 MB
openbravopublicc_invoicetax87366953197247364552026-02-09 12:46:03.970918+002777 MB
openbravopublicc_order728748368000142076152026-06-29 09:41:55.68684+017778 MB
openbravopublicprpass_pass_trans_hist13991265077233052026-07-16 20:00:37.093696+014817 MB
openbravopublicc_invoiceline142560024996460815542026-02-28 09:04:55.209925+007428 MB
openbravopublicm_inoutline142589242916958214742026-03-06 11:59:32.517041+005979 MB
openbravopublicm_productionplan345329410110377432026-02-28 13:31:59.297829+001241 MB
openbravopublicprpass_pass_trans55285984461831232026-07-16 21:03:29.20469+015152 MB
openbravopublicfin_payment_scheduledetail727419852523623116622026-07-05 13:15:29.243565+012784 MB
openbravopublicc_invoice703057497126423286222026-07-16 12:28:46.256497+017098 MB
openbravopublicfact_acct38053680279081299971922026-06-25 13:36:17.490096+0131 GB
openbravopublicc_orderline1441912877189643962522026-07-06 00:03:35.926283+018683 MB

Cluster settings during the report interval

Defined settings
Settingreset_valUnitSourceNotes
archive_command/bin/true/var/lib/postgresql/10/main/postgresql.auto.conf:3
archive_modeon/etc/postgresql/10/main/postgresql.conf:217
checkpoint_completion_target0.9/etc/postgresql/10/main/postgresql.conf:211
client_encodingUTF8
cluster_name10/main/etc/postgresql/10/main/postgresql.conf:477
config_file/etc/postgresql/10/main/postgresql.conf
data_checksumson
data_directory/var/lib/postgresql/10/main
DateStyleISO, DMY/etc/postgresql/10/main/postgresql.conf:566
default_text_search_configpg_catalog.spanish/etc/postgresql/10/main/postgresql.conf:588
effective_cache_size110100488kB/etc/postgresql/10/main/postgresql.conf:315
effective_io_concurrency200/etc/postgresql/10/main/postgresql.conf:164
external_pid_file/var/run/postgresql/10-main.pid/etc/postgresql/10/main/postgresql.conf:49
hba_file/etc/postgresql/10/main/pg_hba.conf
ident_file/etc/postgresql/10/main/pg_ident.conf
lc_collatees_ES.UTF-8
lc_ctypees_ES.UTF-8
lc_messagesen_US.UTF-8/etc/postgresql/10/main/conf.d/09-pgbadger.conf:11
lc_monetaryes_ES.UTF-8/etc/postgresql/10/main/postgresql.conf:583
lc_numericen_US.UTF-8/etc/postgresql/10/main/conf.d/01-openbravo-standard-postgres10.conf:38
lc_timees_ES.UTF-8/etc/postgresql/10/main/postgresql.conf:585
listen_addresses*/etc/postgresql/10/main/postgresql.conf:59
log_autovacuum_min_duration0ms/etc/postgresql/10/main/conf.d/09-pgbadger.conf:10
log_checkpointson/etc/postgresql/10/main/conf.d/09-pgbadger.conf:1
log_connectionson/etc/postgresql/10/main/conf.d/09-pgbadger.conf:2
log_disconnectionson/etc/postgresql/10/main/conf.d/09-pgbadger.conf:3
log_line_prefix%t [%p]:[%l-1] db=%d,user=%u,app=%a,client=%h/etc/postgresql/10/main/conf.d/09-pgbadger.conf:5
log_lock_waitson/etc/postgresql/10/main/conf.d/09-pgbadger.conf:6
log_min_duration_statement5000ms/etc/postgresql/10/main/conf.d/01-openbravo-standard-postgres10.conf:35
log_temp_files0kB/etc/postgresql/10/main/conf.d/09-pgbadger.conf:8
log_timezonelocaltime/etc/postgresql/10/main/conf.d/01-openbravo-standard-postgres10.conf:22
maintenance_work_mem2097152kB/etc/postgresql/10/main/postgresql.conf:123
max_connections500/etc/postgresql/10/main/postgresql.conf:64
max_locks_per_transaction128/etc/postgresql/10/main/conf.d/01-openbravo-standard-postgres10.conf:17
max_parallel_workers16/etc/postgresql/10/main/postgresql.conf:167
max_parallel_workers_per_gather4/etc/postgresql/10/main/postgresql.conf:166
max_stack_depth2048kB
max_standby_streaming_delay10800000ms/etc/postgresql/10/main/postgresql.conf:264
max_wal_size57344MB/etc/postgresql/10/main/postgresql.conf:209
max_worker_processes16/etc/postgresql/10/main/postgresql.conf:165
min_wal_size1024MB/etc/postgresql/10/main/postgresql.conf:210
pg_conf_load_time2026-05-19 04:01:11.408995+01
pg_postmaster_start_time2026-05-19 04:01:11.687059+01
pg_stat_statements.max10000/etc/postgresql/10/main/postgresql.conf:660
pg_stat_statements.trackall/etc/postgresql/10/main/postgresql.conf:661
random_page_cost1.1/etc/postgresql/10/main/postgresql.conf:307
server_encodingUTF8
shared_buffers36700168kB/etc/postgresql/10/main/postgresql.conf:113
shared_preload_libraries$libdir/pg_stat_statements/etc/postgresql/10/main/postgresql.conf:659
sslon/etc/postgresql/10/main/postgresql.conf:79
ssl_cert_file/etc/ssl/certs/ssl-cert-snakeoil.pem/etc/postgresql/10/main/postgresql.conf:84
ssl_key_file/etc/ssl/private/ssl-cert-snakeoil.key/etc/postgresql/10/main/postgresql.conf:85
stats_temp_directory/var/run/postgresql/10-main.pg_stat_tmp/etc/postgresql/10/main/postgresql.conf:493
TimeZonelocaltime/etc/postgresql/10/main/conf.d/01-openbravo-standard-postgres10.conf:23
timezone_abbreviationsDefault
track_functionsall/etc/postgresql/10/main/conf.d/09-pgbadger.conf:9
versionPostgreSQL 10.23 (Ubuntu 10.23-0ubuntu0.18.04.2) on x86_64-pc-linux-gnu, compiled by gcc (Ubuntu 7.5.0-3ubuntu1~18.04) 7.5.0, 64-bit
wal_buffers20488kB/etc/postgresql/10/main/postgresql.conf:198
wal_keep_segments2500/etc/postgresql/10/main/postgresql.conf:237
wal_receiver_timeout601000ms/etc/postgresql/10/main/postgresql.conf:271
wal_sender_timeout0ms/etc/postgresql/10/main/postgresql.conf:238
work_mem36700kB/etc/postgresql/10/main/postgresql.conf:122
Default settings
Settingreset_valUnitSourceNotes
allow_in_place_tablespacesoff
allow_system_table_modsoff
application_name
archive_timeout0s
array_nullson
authentication_timeout60s
autovacuumon
autovacuum_analyze_scale_factor0.1
autovacuum_analyze_threshold50
autovacuum_freeze_max_age200000000
autovacuum_max_workers3
autovacuum_multixact_freeze_max_age400000000
autovacuum_naptime60s
autovacuum_vacuum_cost_delay20ms
autovacuum_vacuum_cost_limit-1
autovacuum_vacuum_scale_factor0.2
autovacuum_vacuum_threshold50
autovacuum_work_mem-1kB
backend_flush_after08kB
backslash_quotesafe_encoding
bgwriter_delay200ms
bgwriter_flush_after648kB
bgwriter_lru_maxpages100
bgwriter_lru_multiplier2
block_size8192
bonjouroff
bonjour_name
bytea_outputhex
check_function_bodieson
checkpoint_flush_after328kB
checkpoint_timeout300s
checkpoint_warning30s
client_min_messagesnotice
commit_delay0
commit_siblings5
constraint_exclusionpartition
cpu_index_tuple_cost0.005
cpu_operator_cost0.0025
cpu_tuple_cost0.01
cursor_tuple_fraction0.1
data_sync_retryoff
db_user_namespaceoff
deadlock_timeout1000ms
debug_assertionsoff
debug_pretty_printon
debug_print_parseoff
debug_print_planoff
debug_print_rewrittenoff
default_statistics_target100/etc/postgresql/10/main/postgresql.conf:329
default_tablespace
default_transaction_deferrableoff
default_transaction_isolationread committed
default_transaction_read_onlyoff
default_with_oidsoff
dynamic_library_path$libdir
dynamic_shared_memory_typeposix/etc/postgresql/10/main/postgresql.conf:127
enable_bitmapscanon
enable_gathermergeon
enable_hashaggon
enable_hashjoinon
enable_indexonlyscanon
enable_indexscanon
enable_materialon
enable_mergejoinon
enable_nestloopon
enable_seqscanon
enable_sorton
enable_tidscanon
escape_string_warningon
event_sourcePostgreSQL
exit_on_erroroff
extra_float_digits0
force_parallel_modeoff
from_collapse_limit8
fsyncon
full_page_writeson
geqoon
geqo_effort5
geqo_generations0
geqo_pool_size0
geqo_seed0
geqo_selection_bias2
geqo_threshold12
gin_fuzzy_search_limit0
gin_pending_list_limit4096kB
hot_standbyon/etc/postgresql/10/main/postgresql.conf:259
hot_standby_feedbackoff
huge_pagestry
idle_in_transaction_session_timeout0ms
ignore_checksum_failureoff
ignore_system_indexesoff
integer_datetimeson
IntervalStylepostgres
join_collapse_limit8
krb_caseins_usersoff
krb_server_keyfileFILE:/etc/postgresql-common/krb5.keytab
local_preload_libraries
lock_timeout0ms
lo_compat_privilegesoff
log_destinationstderr
log_directorylog
log_durationoff/etc/postgresql/10/main/conf.d/09-pgbadger.conf:4
log_error_verbositydefault
log_executor_statsoff
log_file_mode384
log_filenamepostgresql-%Y-%m-%d_%H%M%S.log
logging_collectoroff
log_hostnameoff
log_min_error_statementerror
log_min_messageswarning
log_parser_statsoff
log_planner_statsoff
log_replication_commandsoff
log_rotation_age1440min
log_rotation_size10240kB
log_statementnone/etc/postgresql/10/main/conf.d/09-pgbadger.conf:7
log_statement_statsoff
log_truncate_on_rotationoff
max_files_per_process1000
max_function_args100
max_identifier_length63
max_index_keys32
max_logical_replication_workers4
max_pred_locks_per_page2
max_pred_locks_per_relation-2
max_pred_locks_per_transaction64
max_prepared_transactions0
max_replication_slots10
max_standby_archive_delay30000ms
max_sync_workers_per_subscription2
max_wal_senders10/etc/postgresql/10/main/postgresql.conf:235
min_parallel_index_scan_size648kB
min_parallel_table_scan_size10248kB
old_snapshot_threshold-1min
operator_precedence_warningoff
parallel_setup_cost1000
parallel_tuple_cost0.1
password_encryptionmd5
pg_profile.topn20
pg_stat_statements.saveon
pg_stat_statements.track_utilityon
port5432/etc/postgresql/10/main/postgresql.conf:63
post_auth_delay0s
pre_auth_delay0s
quote_all_identifiersoff
replacement_sort_tuples150000
restart_after_crashon
row_securityon
search_path"$user", public
segment_size1310728kB
seq_page_cost1
server_version10.23 (Ubuntu 10.23-0ubuntu0.18.04.2)
server_version_num100023
session_preload_libraries
session_replication_roleorigin
ssl_ca_file
ssl_ciphersHIGH:MEDIUM:+3DES:!aNULL
ssl_crl_file
ssl_dh_params_file
ssl_ecdh_curveprime256v1
ssl_prefer_server_cipherson
standard_conforming_stringson
statement_timeout0ms
superuser_reserved_connections3
synchronize_seqscanson
synchronous_commiton
synchronous_standby_names
syslog_facilitylocal0
syslog_identpostgres
syslog_sequence_numberson
syslog_split_messageson
system_identifier7195940715332384199
tcp_keepalives_count0
tcp_keepalives_idle0s
tcp_keepalives_interval0s
temp_buffers10248kB
temp_file_limit-1kB
temp_tablespaces
trace_notifyoff
trace_recovery_messageslog
trace_sortoff
track_activitieson
track_activity_query_size1024
track_commit_timestampoff
track_countson
track_io_timingoff
transaction_deferrableoff
transaction_isolationdefault
transaction_read_onlyoff
transform_null_equalsoff
unix_socket_directories/var/run/postgresql/etc/postgresql/10/main/postgresql.conf:66
unix_socket_group
unix_socket_permissions511
update_process_titleon
vacuum_cost_delay0ms
vacuum_cost_limit200
vacuum_cost_page_dirty20
vacuum_cost_page_hit1
vacuum_cost_page_miss10
vacuum_defer_cleanup_age0
vacuum_freeze_min_age50000000
vacuum_freeze_table_age150000000
vacuum_multixact_freeze_min_age5000000
vacuum_multixact_freeze_table_age150000000
wal_block_size8192
wal_compressionoff
wal_consistency_checking
wal_levelreplica/etc/postgresql/10/main/postgresql.conf:180
wal_log_hintsoff
wal_receiver_status_interval10s
wal_retrieve_retry_interval5000ms
wal_segment_size20488kB
wal_sync_methodfdatasync
wal_writer_delay200ms
wal_writer_flush_after1288kB
xmlbinarybase64
xmloptioncontent
zero_damaged_pagesoff