Re: How to duplicate a record easely
Or
INSERT INTO TABLE A SELECT * FROM TABLE A WHERE ...
but I was just wondering:
- why do you want to duplicate a record? - isn’t there a unique key to prevent this?
Van: main@magicu-l.groups.io [mailto:main@magicu-l.groups.io]
Namens Jakes du Preez
You can use a sql script with this format:
insert into my_source_table select col1, col2, col3,... from my_source_table where some_conditions_true
... just remember not to break any uniqueness rules, i.e. replace the column values for those columns that make up unique indexes. Also remember (in the select statement) to define your columns in the same order that they are defined in for the table.
In Magic you can write a batch program that will range on the table then, in the same task, do a Link Create on the table
On Wed, Jul 26, 2017 at 12:13 PM, <gac@...> wrote:
|
||||
|