F
Filips Benoit
Dear all,
Access adp on SQL-server 2005. The adp run successfully 8 year but the
company (orders, database, specialy some tables) grows very fast and some
code runs to slow.
2 questions about this problem.
1. Copying a template-order with all its dependences became to slow!
After 6 year some tables became very large and simply adding a new record
to these tables became very slow.
I did not find a solution meself so the company asked some help from another
developer.
He changed some code like here below.
So what's the theory behind this change ( WHERE 1=2)?
AND, do you have other tips to speed up the process?
The code runs in a transaction and adds many records to diferent tables in 1
tranaction using SP's and VBA-code.
OLD CODE
objrsOrdersProps.Open "ORDER_PROPERTY", InterfaceConn,
adOpenDynamic, adLockOptimistic, adCmdTableDirect
NEW CODE
objrsOrdersProps.Open "SELECT * FROM ORDER_PROPERTY WHERE 1=2",
InterfaceConn, adOpenDynamic, adLockOptimistic, adCmdText
2. While copying a template-order(s) sometimes the user should give some
extra information for the new order by adding data in an inputbox.
The whole action is in a transaction and locks other users out. If the
user waits to fill in the inputbox, other user can't copy an order !
It's dificult to give all information for each order before the action
( transaction) starts.
How can I solve this problem? Since mostly many orders are copyed in 1
action (transaction) the new data (inputbox) is different for each order.
Thanks,
Filip
Access adp on SQL-server 2005. The adp run successfully 8 year but the
company (orders, database, specialy some tables) grows very fast and some
code runs to slow.
2 questions about this problem.
1. Copying a template-order with all its dependences became to slow!
After 6 year some tables became very large and simply adding a new record
to these tables became very slow.
I did not find a solution meself so the company asked some help from another
developer.
He changed some code like here below.
So what's the theory behind this change ( WHERE 1=2)?
AND, do you have other tips to speed up the process?
The code runs in a transaction and adds many records to diferent tables in 1
tranaction using SP's and VBA-code.
OLD CODE
objrsOrdersProps.Open "ORDER_PROPERTY", InterfaceConn,
adOpenDynamic, adLockOptimistic, adCmdTableDirect
NEW CODE
objrsOrdersProps.Open "SELECT * FROM ORDER_PROPERTY WHERE 1=2",
InterfaceConn, adOpenDynamic, adLockOptimistic, adCmdText
2. While copying a template-order(s) sometimes the user should give some
extra information for the new order by adding data in an inputbox.
The whole action is in a transaction and locks other users out. If the
user waits to fill in the inputbox, other user can't copy an order !
It's dificult to give all information for each order before the action
( transaction) starts.
How can I solve this problem? Since mostly many orders are copyed in 1
action (transaction) the new data (inputbox) is different for each order.
Thanks,
Filip