-
How to split 1 table into several tables?
Hi there,
I'm new with SQL, bat have some experiance with mysql/PHP.
I've succesfully imported a CSV file with SQLoader into a table(TEST) it contains firtsname, lastname, adres, zipcode, city.
Now I want to split the table test into two tables linked with id.
it must be something like this (I hope),
create table split1,slpit2
query :=select * from TEST;
result :=SQL(query)
rows :=SQL_fetch_array(result)
while rows
INSERT INTO SPLIT1,SPLIT2 (split1.firstname,split1.lastname,split2.adres,split2.zipcode,split2.city) VALUES (value[0],value[1],value[2],value[3],value[4])
end;
Please advise how to proceed,
Marcel Planting
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules
|
Click Here to Expand Forum to Full Width
|