GIDForums  

Go Back   GIDForums > Computer Programming Forums > MySQL / PHP Forum
User Name
Password
Register FAQ Members List Calendar Search Today's Posts Mark Forums Read
 
 
Thread Tools Search this Thread Rate Thread
  #1  
Old 08-Jan-2017, 07:20
euniseprisno euniseprisno is offline
New Member
 
Join Date: Jan 2017
Posts: 2
euniseprisno is on a distinguished road

Insert record into the table with a least number of records


Hi!!!
im creating a online enrollment system where the user(student) can actually enroll themeselves through online. First they where going to fill up a online form and when they hit the submit button it will automatically insert their information into the table with a least number of records...
My question it is possibly in php/mysql when u insert a record it will automatically insert into table with a least number of records


for example
table 1 has a 50 records of student while table 2 has only 20 records of student
then the new records of student will insert into table 2 because table 2 has least number of records than table 1

THANKS
  #2  
Old 08-Jan-2017, 19:27
TurboPT's Avatar
TurboPT TurboPT is offline
Senior Member
 
Join Date: Feb 2006
Location: Atlanta, GA
Posts: 1,511
TurboPT is a jewel in the roughTurboPT is a jewel in the roughTurboPT is a jewel in the roughTurboPT is a jewel in the rough

Re: Insert record into the table with a least number of records


Short answer: no.

The insert SQL is specific to a given table, and will not "automatically insert" (or overflow) into some other table because of record size.

The question is, why are there two student tables ?
If the table information is the same for all students, then there should only be ONE table for that data.

It seems very silly [to me] to try and have multiple student data tables and then limit one of the tables to 50 rows for student data.
Perhaps more detail may be needed ?

One could programmatically handle something to be done that way, but why?
__________________
Use the force...read the source!!
WYCIWYG -- what you code is what you get!
  #3  
Old 09-Jan-2017, 09:22
euniseprisno euniseprisno is offline
New Member
 
Join Date: Jan 2017
Posts: 2
euniseprisno is on a distinguished road

Re: Insert record into the table with a least number of records


ok i understand...
thanks
 


Thread Tools Search this Thread
Search this Thread:

Advanced Search
Rate This Thread
Rate This Thread:

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is Off
HTML code is Off
Forum Jump

Similar Threads
Thread Thread Starter Forum Replies Last Post
Having issues with the erase Function on my Hash table. angel48797 C++ Forum 2 08-Dec-2011 14:24
Binary Tree recursive Functions 90fmm C++ Forum 3 27-Apr-2011 18:37
NetBeans - Inventory Program biglez123 Java Forum 1 23-Jan-2011 20:48
Anyone can write a program code for this??? chriskan76 C Programming Language 1 19-Oct-2004 20:25
Apache2 config issues monev Apache Web Server Forum 2 28-Jun-2004 06:19

Network Sites: GIDNetwork · GIDApp · GIDBlog · Learning Journal by J de Silva, The

All times are GMT -6. The time now is 02:34.


vBulletin, Copyright © 2000 - 2017, Jelsoft Enterprises Ltd.