Hello, all. Some of you may remember that I was having some issues inserting records and updating records in tables a few weeks ago, I have since learned how to use INSERT INTO t (x,y,z) VALUES v1,v2,v3 FROM othertable
BUT, with the use of this command, I need to know how to use a set-value, for instance a reference number that is not included in the first table, to be copied to the other.
What I mean by this is, I have a table called NEXT, and in NEXT are all the "Next Numbers" for the program (invoice, order ref., customer ref., etc...), the place this code is being implemented is in an order entry screen, the order ref # is displayed in a text box on the form, but is not in the temporary table that is used by the user (in a grid) to enter the order. TempOrderProc is the name of the table that is used as a temporary holder for an order that is being created (the one in the grid), users enter the amount to order, etc in this grid. After this process is complete, I need to use the INSERT INTO... statement above that I've written, But I need to include the Order Ref # that is NOT in the temporary table into the second. Any ideas?
P.s. Sorry for the long post!
BUT, with the use of this command, I need to know how to use a set-value, for instance a reference number that is not included in the first table, to be copied to the other.
What I mean by this is, I have a table called NEXT, and in NEXT are all the "Next Numbers" for the program (invoice, order ref., customer ref., etc...), the place this code is being implemented is in an order entry screen, the order ref # is displayed in a text box on the form, but is not in the temporary table that is used by the user (in a grid) to enter the order. TempOrderProc is the name of the table that is used as a temporary holder for an order that is being created (the one in the grid), users enter the amount to order, etc in this grid. After this process is complete, I need to use the INSERT INTO... statement above that I've written, But I need to include the Order Ref # that is NOT in the temporary table into the second. Any ideas?
P.s. Sorry for the long post!