<?xml version="1.0" encoding="UTF-8"?>
<rss version="2.0" xmlns:atom="http://www.w3.org/2005/Atom" xmlns:dc="http://purl.org/dc/elements/1.1/">
  <channel>
    <title>DEV Community: Fyp Services</title>
    <description>The latest articles on DEV Community by Fyp Services (@fyp_services).</description>
    <link>https://dev.to/fyp_services</link>
    <image>
      <url>https://media2.dev.to/dynamic/image/width=90,height=90,fit=cover,gravity=auto,format=auto/https:%2F%2Fdev-to-uploads.s3.us-east-2.amazonaws.com%2Fuploads%2Fuser%2Fprofile_image%2F4250151%2F7ce8d709-0ba6-4384-b3ac-d0a79b590343.png</url>
      <title>DEV Community: Fyp Services</title>
      <link>https://dev.to/fyp_services</link>
    </image>
    <atom:link rel="self" type="application/rss+xml" href="https://dev.to/feed/fyp_services"/>
    <language>en</language>
    <item>
      <title>Why MongoDB Gets Rejected in FYP Proposals (And a Clean 3NF MySQL Schema Instead)</title>
      <dc:creator>Fyp Services</dc:creator>
      <pubDate>Thu, 26 Nov 2026 07:33:53 +0000</pubDate>
      <link>https://dev.to/fyp_services/why-mongodb-gets-rejected-in-fyp-proposals-and-a-clean-3nf-mysql-schema-instead-5905</link>
      <guid>https://dev.to/fyp_services/why-mongodb-gets-rejected-in-fyp-proposals-and-a-clean-3nf-mysql-schema-instead-5905</guid>
      <description>&lt;p&gt;If your FYP proposal says "we will use MongoDB because it is modern and flexible", expect the panel to push back. In Pakistani universities, supervisors and external examiners check your database design against one thing first: normalisation. A document store makes that check almost impossible to pass, because there is no fixed schema to normalise.&lt;/p&gt;

&lt;p&gt;This is not about MongoDB being bad. It is about what an FYP viva can grade.&lt;/p&gt;

&lt;h2&gt;
  
  
  Why panels reject the MongoDB pitch
&lt;/h2&gt;

&lt;ol&gt;
&lt;li&gt;No schema to examine. The examiner cannot verify 1NF, 2NF and 3NF if every document can have different fields.&lt;/li&gt;
&lt;li&gt;Duplication by design. Embedding copies of the same student, course or product data in many documents is exactly the redundancy normalisation exists to remove — and viva questions target it.&lt;/li&gt;
&lt;li&gt;"Flexibility" reads as "we have not designed it yet." Panels hear that sentence from every group, every semester.&lt;/li&gt;
&lt;/ol&gt;

&lt;p&gt;Unless your project is genuinely document-shaped (logs, sensor data, chat messages at scale) and you can defend that, a relational database is the safer proposal for an FYP.&lt;/p&gt;

&lt;h2&gt;
  
  
  The same system, as a clean 3NF MySQL schema
&lt;/h2&gt;

&lt;p&gt;Take a simple FYP example: students submit project proposals, supervisors review them.&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight sql"&gt;&lt;code&gt;&lt;span class="k"&gt;CREATE&lt;/span&gt; &lt;span class="k"&gt;TABLE&lt;/span&gt; &lt;span class="n"&gt;students&lt;/span&gt; &lt;span class="p"&gt;(&lt;/span&gt;
  &lt;span class="n"&gt;student_id&lt;/span&gt; &lt;span class="kt"&gt;INT&lt;/span&gt; &lt;span class="k"&gt;PRIMARY&lt;/span&gt; &lt;span class="k"&gt;KEY&lt;/span&gt; &lt;span class="no"&gt;AUTO_INCREMENT&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;
  &lt;span class="n"&gt;reg_no&lt;/span&gt; &lt;span class="kt"&gt;VARCHAR&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="mi"&gt;20&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt; &lt;span class="k"&gt;UNIQUE&lt;/span&gt; &lt;span class="k"&gt;NOT&lt;/span&gt; &lt;span class="kc"&gt;NULL&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;
  &lt;span class="n"&gt;full_name&lt;/span&gt; &lt;span class="kt"&gt;VARCHAR&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="mi"&gt;100&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt; &lt;span class="k"&gt;NOT&lt;/span&gt; &lt;span class="kc"&gt;NULL&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;
  &lt;span class="n"&gt;email&lt;/span&gt; &lt;span class="kt"&gt;VARCHAR&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="mi"&gt;120&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt; &lt;span class="k"&gt;UNIQUE&lt;/span&gt; &lt;span class="k"&gt;NOT&lt;/span&gt; &lt;span class="kc"&gt;NULL&lt;/span&gt;
&lt;span class="p"&gt;)&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt;

&lt;span class="k"&gt;CREATE&lt;/span&gt; &lt;span class="k"&gt;TABLE&lt;/span&gt; &lt;span class="n"&gt;supervisors&lt;/span&gt; &lt;span class="p"&gt;(&lt;/span&gt;
  &lt;span class="n"&gt;supervisor_id&lt;/span&gt; &lt;span class="kt"&gt;INT&lt;/span&gt; &lt;span class="k"&gt;PRIMARY&lt;/span&gt; &lt;span class="k"&gt;KEY&lt;/span&gt; &lt;span class="no"&gt;AUTO_INCREMENT&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;
  &lt;span class="n"&gt;full_name&lt;/span&gt; &lt;span class="kt"&gt;VARCHAR&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="mi"&gt;100&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt; &lt;span class="k"&gt;NOT&lt;/span&gt; &lt;span class="kc"&gt;NULL&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;
  &lt;span class="n"&gt;email&lt;/span&gt; &lt;span class="kt"&gt;VARCHAR&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="mi"&gt;120&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt; &lt;span class="k"&gt;UNIQUE&lt;/span&gt; &lt;span class="k"&gt;NOT&lt;/span&gt; &lt;span class="kc"&gt;NULL&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;
  &lt;span class="n"&gt;department&lt;/span&gt; &lt;span class="kt"&gt;VARCHAR&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="mi"&gt;80&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt; &lt;span class="k"&gt;NOT&lt;/span&gt; &lt;span class="kc"&gt;NULL&lt;/span&gt;
&lt;span class="p"&gt;)&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt;

&lt;span class="k"&gt;CREATE&lt;/span&gt; &lt;span class="k"&gt;TABLE&lt;/span&gt; &lt;span class="n"&gt;proposals&lt;/span&gt; &lt;span class="p"&gt;(&lt;/span&gt;
  &lt;span class="n"&gt;proposal_id&lt;/span&gt; &lt;span class="kt"&gt;INT&lt;/span&gt; &lt;span class="k"&gt;PRIMARY&lt;/span&gt; &lt;span class="k"&gt;KEY&lt;/span&gt; &lt;span class="no"&gt;AUTO_INCREMENT&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;
  &lt;span class="n"&gt;student_id&lt;/span&gt; &lt;span class="kt"&gt;INT&lt;/span&gt; &lt;span class="k"&gt;NOT&lt;/span&gt; &lt;span class="kc"&gt;NULL&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;
  &lt;span class="n"&gt;supervisor_id&lt;/span&gt; &lt;span class="kt"&gt;INT&lt;/span&gt; &lt;span class="kc"&gt;NULL&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;
  &lt;span class="n"&gt;title&lt;/span&gt; &lt;span class="kt"&gt;VARCHAR&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="mi"&gt;200&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt; &lt;span class="k"&gt;NOT&lt;/span&gt; &lt;span class="kc"&gt;NULL&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;
  &lt;span class="n"&gt;status&lt;/span&gt; &lt;span class="no"&gt;ENUM&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="s1"&gt;'pending'&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;&lt;span class="s1"&gt;'approved'&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;&lt;span class="s1"&gt;'rejected'&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt; &lt;span class="k"&gt;DEFAULT&lt;/span&gt; &lt;span class="s1"&gt;'pending'&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;
  &lt;span class="n"&gt;submitted_at&lt;/span&gt; &lt;span class="kt"&gt;TIMESTAMP&lt;/span&gt; &lt;span class="k"&gt;DEFAULT&lt;/span&gt; &lt;span class="kc"&gt;CURRENT_TIMESTAMP&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;
  &lt;span class="k"&gt;FOREIGN&lt;/span&gt; &lt;span class="k"&gt;KEY&lt;/span&gt; &lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="n"&gt;student_id&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt; &lt;span class="k"&gt;REFERENCES&lt;/span&gt; &lt;span class="nf"&gt;students&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="n"&gt;student_id&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;
  &lt;span class="k"&gt;FOREIGN&lt;/span&gt; &lt;span class="k"&gt;KEY&lt;/span&gt; &lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="n"&gt;supervisor_id&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt; &lt;span class="k"&gt;REFERENCES&lt;/span&gt; &lt;span class="nf"&gt;supervisors&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="n"&gt;supervisor_id&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt;
&lt;span class="p"&gt;)&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;Why this passes the 3NF questions:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;1NF: every column holds one value. No comma-separated lists of group members or technologies — those go in their own tables with foreign keys.&lt;/li&gt;
&lt;li&gt;2NF: no column depends on only part of a key. Student name lives only in students, never repeated in proposals.&lt;/li&gt;
&lt;li&gt;3NF: no column depends on another non-key column. Department belongs to the supervisor record, not copied into every proposal row.&lt;/li&gt;
&lt;/ul&gt;

&lt;h2&gt;
  
  
  The viva questions this prepares you for
&lt;/h2&gt;

&lt;ul&gt;
&lt;li&gt;"Where is your data duplicated?" Nowhere — each fact is stored once, everything else is a foreign key.&lt;/li&gt;
&lt;li&gt;"What happens if a supervisor changes department?" One row updates, not hundreds.&lt;/li&gt;
&lt;li&gt;"Show me your ERD." This schema draws directly into an ERD with two clean relationships, which is exactly what Chapter 3 of the report needs.&lt;/li&gt;
&lt;/ul&gt;

&lt;h2&gt;
  
  
  When MongoDB is actually defensible
&lt;/h2&gt;

&lt;p&gt;If your core data is unstructured — IoT sensor readings, scraped listings, chat logs — say that, show the document shape, and explain why joins and normalisation do not apply. That answer passes. "It is modern and flexible" does not.&lt;/p&gt;

&lt;p&gt;For a standard management-system, portal or e-commerce FYP, go relational, normalise to 3NF, and let the examiner's checklist work in your favour.&lt;/p&gt;

</description>
      <category>database</category>
      <category>mysql</category>
      <category>webdev</category>
      <category>tutorial</category>
    </item>
    <item>
      <title>Fixing Flutter-to-Localhost Laravel API Errors on a Physical Android Device</title>
      <dc:creator>Fyp Services</dc:creator>
      <pubDate>Thu, 26 Nov 2026 07:06:04 +0000</pubDate>
      <link>https://dev.to/fyp_services/fixing-flutter-to-localhost-laravel-api-errors-on-a-physical-android-device-409c</link>
      <guid>https://dev.to/fyp_services/fixing-flutter-to-localhost-laravel-api-errors-on-a-physical-android-device-409c</guid>
      <description>&lt;p&gt;Your Flutter app works on the emulator. You install it on your real phone for the FYP demo, hit login, and get Connection refused or a Dio timeout. This fails for almost every student the first time, and the reason is simple: on a physical device, localhost is the phone itself — not your laptop.&lt;/p&gt;

&lt;p&gt;Here is the fix that works, step by step.&lt;/p&gt;

&lt;h2&gt;
  
  
  Why the emulator tricks you
&lt;/h2&gt;

&lt;ul&gt;
&lt;li&gt;Android emulator: 10.0.2.2 points back to your laptop's localhost.&lt;/li&gt;
&lt;li&gt;Physical device: 10.0.2.2 means nothing. 127.0.0.1 / localhost points to the phone.&lt;/li&gt;
&lt;li&gt;So the same base URL that worked in the emulator can never work on a real device.&lt;/li&gt;
&lt;/ul&gt;

&lt;h2&gt;
  
  
  Step 1: Put the phone and laptop on the same Wi-Fi
&lt;/h2&gt;

&lt;p&gt;Both devices must be on the same network. University Wi-Fi often blocks device-to-device traffic (client isolation) — if the steps below fail on campus Wi-Fi, use your phone's hotspot and connect the laptop to it instead. That one change fixes a lot of "nothing works" cases.&lt;/p&gt;

&lt;h2&gt;
  
  
  Step 2: Find your laptop's local IP
&lt;/h2&gt;

&lt;p&gt;Windows: run &lt;code&gt;ipconfig&lt;/code&gt; and look for the IPv4 Address under your Wi-Fi adapter, e.g. 192.168.1.42. Linux/Mac: &lt;code&gt;ip addr&lt;/code&gt; or &lt;code&gt;ifconfig&lt;/code&gt;.&lt;/p&gt;

&lt;h2&gt;
  
  
  Step 3: Serve Laravel on the network, not only localhost
&lt;/h2&gt;



&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt;php artisan serve --host=0.0.0.0 --port=8000
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;--host=0.0.0.0 makes the server listen on all network interfaces. Without it, Laravel only accepts connections from the laptop itself.&lt;/p&gt;

&lt;p&gt;Test it before touching Flutter: open &lt;a href="http://192.168.1.42:8000/api/" rel="noopener noreferrer"&gt;http://192.168.1.42:8000/api/&lt;/a&gt;... (one of your GET routes) in your phone's browser. If the phone browser cannot load it, Flutter will not either — check the firewall step below.&lt;/p&gt;

&lt;h2&gt;
  
  
  Step 4: Point Flutter at the laptop IP
&lt;/h2&gt;

&lt;p&gt;Do not hardcode the IP in ten files. Keep one config:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight dart"&gt;&lt;code&gt;&lt;span class="c1"&gt;// lib/core/api_config.dart&lt;/span&gt;
&lt;span class="k"&gt;class&lt;/span&gt; &lt;span class="nc"&gt;ApiConfig&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt;
  &lt;span class="c1"&gt;// Emulator: http://10.0.2.2:8000/api&lt;/span&gt;
  &lt;span class="c1"&gt;// Physical device: your laptop's LAN IP&lt;/span&gt;
  &lt;span class="k"&gt;static&lt;/span&gt; &lt;span class="kd"&gt;const&lt;/span&gt; &lt;span class="kt"&gt;String&lt;/span&gt; &lt;span class="n"&gt;baseUrl&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="s1"&gt;'http://192.168.1.42:8000/api'&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt;
&lt;span class="p"&gt;}&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;And use it everywhere:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight dart"&gt;&lt;code&gt;&lt;span class="kd"&gt;final&lt;/span&gt; &lt;span class="n"&gt;dio&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="nc"&gt;Dio&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="nc"&gt;BaseOptions&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="n"&gt;baseUrl&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="nc"&gt;ApiConfig&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="n"&gt;baseUrl&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;When you switch between emulator and phone, you change one line.&lt;/p&gt;

&lt;h2&gt;
  
  
  Step 5: Allow cleartext HTTP on Android
&lt;/h2&gt;

&lt;p&gt;Your local server is HTTP, not HTTPS. Modern Android blocks cleartext traffic by default, which shows up as a vague network error in Flutter even when the server is reachable.&lt;/p&gt;

&lt;p&gt;In android/app/src/main/AndroidManifest.xml, inside the application tag, add: android:usesCleartextTraffic="true"&lt;/p&gt;

&lt;p&gt;This is fine for a local FYP demo. A deployed production API should be HTTPS, and then you remove this.&lt;/p&gt;

&lt;h2&gt;
  
  
  Step 6: Let it through the Windows firewall
&lt;/h2&gt;

&lt;p&gt;If the phone browser timed out in Step 3, Windows Firewall is the usual blocker. Allow PHP / the 8000 port for Private networks: Windows Defender Firewall, Allow an app through firewall, allow PHP — or add an inbound rule for TCP port 8000 on the Private profile only. Do not open it on Public networks.&lt;/p&gt;

&lt;h2&gt;
  
  
  Quick checklist when it still fails
&lt;/h2&gt;

&lt;ul&gt;
&lt;li&gt;Connection refused instantly: Laravel not running with --host=0.0.0.0, or wrong IP.&lt;/li&gt;
&lt;li&gt;Timeout: different networks, campus Wi-Fi client isolation, or firewall.&lt;/li&gt;
&lt;li&gt;Works in phone browser, fails in app: cleartext HTTP blocked — check Step 5.&lt;/li&gt;
&lt;li&gt;Worked yesterday, broken today: laptop IP changed (DHCP). Re-check ipconfig.&lt;/li&gt;
&lt;li&gt;401 / 419 errors: connection is fine — now it is an auth issue. For APIs, use token auth (Sanctum) and make sure the route is in api.php, not web.php.&lt;/li&gt;
&lt;/ul&gt;

&lt;h2&gt;
  
  
  For demo day
&lt;/h2&gt;

&lt;p&gt;Your IP will probably be different in the university lab. Reach 30 minutes early, connect to the network, re-check the IP, update ApiConfig.baseUrl, rebuild, and test login on the actual phone you will present with. Most "the app stopped working in the viva" stories are just a changed IP.&lt;/p&gt;

</description>
      <category>flutter</category>
      <category>php</category>
      <category>webdev</category>
      <category>tutorial</category>
    </item>
  </channel>
</rss>
