Skip to content

Conversation

@HadikaMalik
Copy link

@HadikaMalik HadikaMalik commented May 25, 2024

Learners, PR Template

Self checklist

  • I have committed my files one by one, on purpose, and for a reason
  • I have titled my PR with COHORT_NAME | FIRST_NAME LAST_NAME | REPO_NAME | WEEK
  • I have tested my changes
  • My changes follow the style guide
  • My changes meet the requirements of this task

Changelist

Briefly explain your PR.
I have completed the big-spender ticket.

Questions

Ask any questions you have for your reviewer.

@sonarqubecloud
Copy link

Quality Gate Passed Quality Gate passed

Issues
0 New issues
0 Accepted issues

Measures
0 Security Hotspots
No data about Coverage
No data about Duplication

See analysis details on SonarCloud

Copy link

@sayoiscool sayoiscool left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Great work overall! A little more work needed on the table insertions + attention to the minor details in requirements.


```sql
INSERT YOUR QUERY HERE
select * from spends where description ilike '%fee%';

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Good work taking the capitlisations into consideration with 'ilike'

select s.*
from spends s
join expense_areas ea on s.expense_area_id = ea.id
where ea.expense_area ilike 'Better Hospital Food';

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Good use of joins!


```sql
CREATE YOUR QUERY HERE
select to_char(date,'YYYY-MM') as month from spends group by month;

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Good attempt and nice formatting of the date, however you have partially answered the question. Only one column is returned, but two are expected in your results. Which column is missing?


```sql
INSERT YOUR QUERY HERE
select sp.amount, sup.supplier

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The question is for the total amount spent by each supplier. Which operator missing here is needed to get the desired result?

'3780119655',
'Computer Hardware Dell',
32000
);
Copy link

@sayoiscool sayoiscool Jun 15, 2024

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Good attempt here. The rows ' Dell', 'Hardware' and 'IT' are missing from other tables, what extra step is needed to have the rows populated where necessary? What effect will this change have on the 'id's inserted in spends table?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants