Page 1 of 1

Scores system

Posted: Tue Sep 14, 2004 1:34 pm
by ek5932
I need create a scores syetm that insterts the top 100 kingdoms into my database but am not sure how to do it. All i need help with is is how to insert the data, if some one could just tell me what i need to look up that would be great. thanks.

Posted: Tue Sep 14, 2004 2:08 pm
by feyd
mysql: [mysql_man]insert[/mysql_man]
postgre: [pg_man]insert[/pg_man]

Posted: Tue Sep 14, 2004 2:11 pm
by Draco_03
feyd wrote:mysql: [mysql_man]insert[/mysql_man]
postgre: [pg_man]insert[/pg_man]
I know that for a noob (me) reading doc from mysql.com can be a little bit confusing
So just in case try here

EDIT : I took granted that you are able to write php, make a connection to a database and extract some data.

Posted: Tue Sep 14, 2004 2:40 pm
by ek5932
I know how to insert information, im just not sure how to insert 100 lines ordered by size into the db

Posted: Tue Sep 14, 2004 2:41 pm
by feyd
100 inserts, generally... unless your database supports multi-inserts...

Posted: Tue Sep 14, 2004 2:45 pm
by ek5932
so the best thing would be to loop the insert 100 times? how would I order the size of the inserts tho, as individualy they have no order.

Posted: Tue Sep 14, 2004 2:46 pm
by Draco_03
you can make a loop, where it insert all your data
but it'll be inserted 100 times..
don't know if you get what i'm saying

Posted: Tue Sep 14, 2004 2:47 pm
by feyd
using a sort of the data first, or just select with an order by, which is the more conventional way...