Hi, I am new to yii and php and i want to deleveop a database design for school exam time table and maintain the time table for school management. How can I procced the same? Please help me? :(
I am new to yii and php and i want to deleveop a database design for school exam time table and maintain the time table for school management. How can I procced the same?
If you are new to PHP and PHP MVC framework like yii, I don't see any reason for you to be developing any application in this type of framework environment.
Please don't take my statement personally. I am just trying to be honest and trying to save you from gargantuan headaches.
Good shout veedeoo - a framework is a beast at the best of times.
The central aspect of your project is the DB design (schema) itself. Once you have a robust structure in place, you can concentrate on creating your input / output routines, which usually revolve around SELECT, INSERT, UPDATE and DELETE statements/queries.
You'll want to wrap these routines into functions if possible, to make your code more manageable if nothing else. If you're just starting with PHP, I would imagine that producing classes (OOP) is a bit of a stretch, so keeping the code as concise as possible in functions would be advantageous.
A school exam timetable DB could be very simple - or majorly complex, depending on your needs. However, most schools have paid-for software that stores this info, some of it coming directly from examing boards in a format that is easily consumed by said software. In the UK, many schools make use of "SIMS", but there are many variations out there. Make sure that your school does not already have this feature. Many school systems are modular and your admin dept may not be aware of everything that the system can do. It's worth asking. It could save you weeks of work.
If you need help with the DB design let us know.
Thaks for the replay. Now i don't konw what to do and how to do? Can anyone tell me how the database design would be? is there any examples are available. If so please send me a link. Thanks.
Hi, my requirement is i want to generate the exam time table and allocate the staffs for the particular exam and more more is i want to manage the school daily(period) timetables. It may be in pure php or in yii framework with mysql db.
In my opinion, you should create a database design flow similar to what diafol have given above and from the design flow, you create the tentative database table.
The next step is visualization of your design. Once you are satified, create the actual database and add test values. The next step is query testing. The tools that I am currently using in testing proposed database is called "MysQL Workbench" which offfers database visualization, editing, query optimization, data modeling and many other cool stuffs.
A tentative database table can be something like below. A design flow is something like Diafol gave us.
exam id ( this will be an auto-incremented value) class id exam id exam time exam duration exam type ( pre-lim, med-term, finals) instructor assigned (use instructor id)
class id (auto-incremented) class description class section class instructor id class term (winter ? spring ? summer ? fall) class passing grade ( in percent)
instructor id (auto) instructor name instructor last instructor dept instructor total hours instructor total class assigned exams ( the number of assigned exams to monitor)
instructors time table
asignment id (auto) instructor id ( derived from the instructor table) instructory total assignments ( how many exams this instructor must give) time of assignment begin (time when the instructor must be in the class room) time of assignment end ( time when the exam will end) total time needed for this assignment( the sum of the begin and end column)
Now we can simply visualize what is going on with the program, once we create an examination staff assignment.
Say we have a class on exam table
101 -> exam id 124 -> class id 1411615800 -> time (unix time when the exam should start 9/25/2014 @ 3:30 pm). 3600 -> duration is for 1 hour exam type -> pre-liminary 0 assigned instructor // Zero because we don't know who is available
you send query to the instructor' time table and look for the instructor availability . Remember the time and the duration time stamp will be equivalent to 1411619400 which is the same date of the examination date and hour plus one hour which give us 4:30 PM
So, we are looking for someone that is available between 1411615800 and 1411619400 from the instructors table. If the instructor is allowed to urinate between exams then you must consider adding them to the epoch.
Remember our imaginaery table from above? that is the table where the query should be sent.
asignment id (auto) instructor id ( derived from the instructor table) instructor total assignments ( how many exams this instructor must give) time of assignment begin (time when the instructor must be in the class room) time of assignment end ( time when the exam will end) total time needed for this assignment( the sum of the begin and end column + plus the time the intructor is allowed to urinate or take a break)
so if instructor 101, 102, 120 are available their time assignment column should be nowhere close to 1411615800 and 1411619400 . that should give you the available instructor or staffs that can be utilized for one specific exam or you can assign two or three instructors to catch the cheating students ( I am just joking of course :)).
For the YII, I must tell you again. That is not the framework for people who does not write codes in Object Oriented. As already been suggested by Diafol, maybe a function will help you.
Frameworks uses data objects and ORM ( object relational Mapper) which is in my humble opinion requires more time to learn their sysntax.
I am not really criticizing you for aiming to use framework. This is very common for the people in PHP community. The reason is that once we learned how to do this
echo 'Hello World';
We became overly confident ( confindence is a very good thing, but do not underestimate PHP) that we can all write programs anything that we desire. However, that is an underestimation on our part.
Object Oriented PHP is a different world and so as the frmeworks. Frameworks strictly imposes the separation of concern doctrine. Meaning, all user requests are separated in 2 major logic processors e.g controller and model . Under these 2 major logic processors the logics are further broken down into two types is it business or is it presentation? If it is business that would be the model's concern , if it is presentation the cotroller assign the request to the view.
These processes is sometimes difficult to grasp and follow, because you can easily get lost tracking which one of the triad ( MVC) is doing the job or responsible for the particular segement of an output.
I am losing my focus on this, so please forgive me. I must stop here and I hope I did not add any more confusion to the subject matter. The urination example is not intended for literal meaning. :)
Edited by veedeoo: more info added
hi, i want to generate the online exam module just like SBI online exam plz help me
Did you not find anything on this thread to help you?
Hello everyone. I have a string that looks like this
(Mango, fruits, and), (Maize, cereals, and), (Mango juice, beverages, and)
I would like to convert the above string using php ...
As a small business owner, it is difficult to understand where you are on the search engine result pages. SEO is complicated and it is constantly changing. Every company wants ...
I have a function that I need help with. The purpose of the function is to sort an array of objects by field. This function was using the PHP function ...