Skip to content

Conversation

pan93412
Copy link
Member

  • feat(sqlrunner): implement GetDatabaseStructure method
  • feat(graph): implement Structure in Database type

@pan93412 pan93412 self-assigned this Sep 24, 2025
Copy link

linear bot commented Sep 24, 2025

@pan93412 pan93412 requested a review from Copilot September 24, 2025 14:58
Copy link
Contributor

@Copilot Copilot AI left a comment

Choose a reason for hiding this comment

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

Pull Request Overview

This PR implements database structure retrieval functionality, adding the ability to get table and column information from database schemas. The implementation includes both backend SQL query capabilities and GraphQL API integration.

Key changes:

  • Added GetDatabaseStructure method to SQLRunner for retrieving table and column metadata
  • Integrated database structure retrieval into the GraphQL API through Database type extension
  • Added comprehensive test coverage for various database structure scenarios

Reviewed Changes

Copilot reviewed 11 out of 11 changed files in this pull request and generated 2 comments.

Show a summary per file
File Description
internal/sqlrunner/sqlrunner.go Implements GetDatabaseStructure method using SQLite system tables
internal/sqlrunner/models.go Defines DatabaseStructure and DatabaseTable data models
internal/sqlrunner/sqlrunner_test.go Comprehensive tests for database structure retrieval functionality
graph/database.resolvers.go GraphQL resolver for database structure field
graph/database.graphqls GraphQL schema extension for database structure types
graph/model/models_gen.go Generated GraphQL model types
graph/ent.resolvers.go Updates resolver registration and formatting
graph/question.resolvers.go Adds lastSubmission resolver and ordering to userSubmissions
graph/question.graphqls GraphQL schema updates for question submissions
graph/user.resolvers.go Generated code version update
graph/event.resolvers.go Generated code version update

Tip: Customize your code reviews with copilot-instructions.md. Create the file or learn how to get started.

@pan93412 pan93412 merged commit a90b31a into main Sep 24, 2025
1 check passed
@pan93412 pan93412 deleted the pan93412/dbp-61-implement-database-structure-retrieval branch September 24, 2025 15:00
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.

1 participant