Skip to content

Feature Request:指定した列の元の名前や元のテーブル名などの取得 #22

Description

@nira-yusan

指定した列の元の名前や元のテーブル名など、クエリ結果のメタデータの取得をする機能が欲しいです。
具体的には、Microsoft.Data.Sqlite.SqliteDataReader.GetSchemaTable()にあたる機能の要望になります。
(参考:https://learn.microsoft.com/ja-jp/dotnet/standard/data/sqlite/metadata )

機能の実装案については、ネイティブメソッドからなら、データベース名はsqlite3_column_database_name()、元のテーブル名はsqlite3_column_table_name()、元の列名はsqlite3_column_origin_name()で取得ができるようです。
(参考:https://sqlite.org/c3ref/column_database_name.html

また、それらの情報を使ってsqlite3_table_column_metadata()で他のメタデータも取得できるようです。
(参考:https://sqlite.org/c3ref/table_column_metadata.html

Activity

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

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions