Shamrox Posted April 1, 2008 Share Posted April 1, 2008 I've got a spreadsheet that has a few tabs with data in them. The first tab has suppliers listed with a name column and an ID column. All the other tabs, the person omitted the ID column and just has the name column with other data. I'm trying to put this into a mysql database and would like to have the ID on all the tables so it's easy to index. Any idea of how to do this aside from hand typing all the IDs on the other tabs before i import?!!? Link to comment https://forums.phpfreaks.com/topic/99031-excelmysql-question/ Share on other sites More sharing options...
fallenangel1983 Posted April 2, 2008 Share Posted April 2, 2008 Would it not be possible to create a sequence? then index them with that while they are being inserted? e.g. CREATE SEQUENCE index START WITH 1 INCREMENT BY 1 NOCACHE NOCYCLE; then when your inserting just use INSERT INTO tablename VALUES (index.NEXTVAL, etc etc Link to comment https://forums.phpfreaks.com/topic/99031-excelmysql-question/#findComment-507071 Share on other sites More sharing options...
Recommended Posts
Archived
This topic is now archived and is closed to further replies.