diff options
| -rw-r--r-- | import_account_move.ktr | 4 | ||||
| -rw-r--r-- | import_account_move_line.ktr | 5 |
2 files changed, 7 insertions, 2 deletions
diff --git a/import_account_move.ktr b/import_account_move.ktr index 5c16c43..b7155fb 100644 --- a/import_account_move.ktr +++ b/import_account_move.ktr @@ -1009,7 +1009,9 @@ <schema_name/> </partitioning> <connection>erp indoteknik production (localhost)</connection> - <sql>select * from account_move where write_date >= (now() - '5 days'::interval)</sql> + <sql>select am.* from account_move am +where am.move_type = 'out_invoice' +and am.write_date >= (now() - '5 days'::interval)</sql> <limit>0</limit> <lookup/> <execute_each_row>N</execute_each_row> diff --git a/import_account_move_line.ktr b/import_account_move_line.ktr index 383d05f..71fd501 100644 --- a/import_account_move_line.ktr +++ b/import_account_move_line.ktr @@ -889,7 +889,10 @@ <schema_name/> </partitioning> <connection>erp indoteknik production (localhost)</connection> - <sql>select * from account_move_line where write_date >= (now() - '5 days'::interval)</sql> + <sql>select aml.* from account_move_line aml +join account_move am on am.id = aml.move_id +where am.move_type = 'out_invoice' +and aml.write_date >= (now() - '5 days'::interval)</sql> <limit>0</limit> <lookup/> <execute_each_row>N</execute_each_row> |
