Jump to content


  • Content Count

  • Joined

  • Last visited

Community Reputation

0 Neutral

About JDevOnline

  • Rank
  1. Dear Barand this perfectly solves my problem. I will consider adopting the suggested alternative model which will allow multiple siblings. Thank you very much!
  2. Hi, I am seeking help with the following scenario: I have a mysql db with a table to store students info with following fields: id, sname, ctclass, shift, siblingof, elderof, ctstudent (sname=Student's name, ctstudent=Y/N, siblingof/elder of=id of sibling or elder in the same table.) Every child who has a brother or sister either has a sibling or elder therefore siblingof or elderof store ids of either sibling or elder in the same table. What I want to do is to run a query to select only current children with elders AND also want to find out the status of elders, whether they are current student of have left. This info is stored in "Y or N" in the column name called "ctstudent". I've created the following code but is not showing any result. SELECT id, sname, ctclass, shift ctstudent FROM nroll WHERE siblingof <> '' and ctstudent IN (SELECT ctstudent as ct FROM nroll where id=siblingof)
  3. Hi Barand, thanks for your reply, I have inserted a column name mont with "date" type and have also inserted date values (like 2019-01-01 for January-2019 in month column) corresponding to the month column. Can you please now update your query and array building code accordingly, thanks.
  4. Hi, I have students fee record saved in a table called feerecord. It has structure like the following: I want to use a mysqli query to extract results as shown in the following table: I am using a query like the following but it is not working as desired: Select * from feerecord group by name, month order by shift asc, class asc, name asc Can anyone please help me devise a right query? thanks.
  5. Hi Barand, I tried used the array declaration, as you mentioned but it is rendering a blank page.
  6. Thanks for the info, I will either upgrade if possible or change my web hosting company, to be able to use the latest version of php, thanks.
  7. Since i can not upgrade the php version to higher than 5.4, please suggest change in code, thanks.
  8. Hi Barand, PHP version on my local server is 5.6 whereas on the online server it is 5.4, this might be the reason that the script has thrown the following error on then taken online: PHP Local: 5.6 PHP Online: 5.4 "Parse error: syntax error, unexpected '[' in /home/content/87/html/nroll-classwise.php on line 37" When I inspected the code on the line number mentioned above it is: $data = []; Please tell me how to handle this situation, thank you.
  9. Barand and taquitosensei thank you very much for you kind assistance. You guys have pointed to the right direction, working on which helped me find the way, thanks.
  10. I've tried the left join but hasn't worked well. I read about outer join but don't have the skill to code it.
  11. Hi, I want to devise a query to join 2 mysql data tables. What i want to achieve is to join both the tables in such a way that the result would display all the rows of TableOne with the single row of TableTwo appended to every single row of the result. TableOne has fields id, a, b, c and multiple rows. Data sample: 1, a, b, c 2, d, e, f TableTow has fields id, d, e, f and single row. Data sample: 1, g, h, i, j, k Desired Output: a, b, c, g, h, i, j, k d, e, f, g, h, i, j, k
  12. Barand, this has perfectly concluded the current project. I am sooooooo very happy for your great help, thanks once again.
  13. Hi Barand, the table structure you've created is lacking one column, which is mimp, which marks important mothers by occupation like in the case of fathers fimp is used. Following is the mockup of the table i am trying to generate.
  14. I want to add student's name and mother's name in occupation tables as rows and not as columns in HTML tables. However, the data is stored in the same table in columns.
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.