Michael Kozub – Week 3

So far ChatGPT has done a great job creating MySQL table tables and general SQL statements. This week I used GPT to create more tables:

  • brokerage_connections
  • orders
  • notifications

I ran into some issues with it creating primary and foreign keys, mostly due to my impatience with how to correctly write this in GPT format, so I took over and manually created those relationships in MySQLWorkbench since it was much faster.

I also used ChatGPT to help me create some dummy data with real Firebase Id’s that were generated by creating users in our Firebase data.

Then I hopped over to the brokerageLinkPage (the page that shows a list of brokerages you can connect to our app). This was my first time trying to update an existing file that I pasted into ChatGPT. I tried to have GPT update our existing code to have an onClick handler and print a simple console log. ChatGPT fell short and threw me for a loop for a few hours due to one line missing: ‘use client’. I had to manually resolve this issue even after Googling what the issue was. Apparently ChatGPT isn’t aware of how to include this statement in React/Next.js code. This wasn’t a big deal at the end of the day but it took some manual debugging to figure out what was going on.

After getting the console.log to work when tapping on a brokerage, I was able to have ChatGPT write some code that opens the Alpaca login/signup page in a new tab. Next week I will look into how to get this window to open in the existing tab (such as an iframe?) but I will have a chat with ChatGPT to see what best practices are.

Print Friendly, PDF & Email

Comments

Leave a Reply

Your email address will not be published. Required fields are marked *