/// <summary>
        /// Execute DataTable
        /// </summary>
        /// <param name="command"></param>
        /// <returns></returns>
        internal static DataTable ExecuteFirstDataTable(this SQLiteCommand command)
        {
            command.CheckNull(nameof(command));
            var ds = new DataSet();

            using var dataAdapter = new SQLiteDataAdapter(command);
            dataAdapter.Fill(ds);

            return(ds.Tables[0]);
        }
        /// <summary>
        /// Execute DataTable
        /// </summary>
        /// <param name="command">The @this to act on.</param>
        /// <returns>A DataTable that is equivalent to the first result set.</returns>
        public static async Task <DataTable> ExecuteDataTableAsync(this SQLiteCommand command)
        {
            command.CheckNull(nameof(command));
            var dt = new DataTable();

            using var dataAdapter = new SQLiteDataAdapter(command);
            await Task.Run(() => dataAdapter.Fill(dt));

            return(dt);
        }
        /// <summary>
        /// Execute DataTable
        /// </summary>
        /// <param name="command">The @this to act on.</param>
        /// <returns>A DataTable that is equivalent to the first result set.</returns>
        public static DataTable ExecuteDataTable(this SQLiteCommand command)
        {
            command.CheckNull(nameof(command));
            var dt = new DataTable();

            using var dataAdapter = new SQLiteDataAdapter(command);
            dataAdapter.Fill(dt);

            return(dt);
        }
        /// <summary>
        /// Execute DataSet
        /// </summary>
        /// <param name="command">The @this to act on.</param>
        /// <returns>A DataSet that is equivalent to the result set.</returns>
        public static DataSet ExecuteDataSet(this SQLiteCommand command)
        {
            command.CheckNull(nameof(command));
            var ds = new DataSet();

            using var dataAdapter = new SQLiteDataAdapter(command);
            dataAdapter.Fill(ds);

            return(ds);
        }
        /// <summary>
        /// Execute DataTable async
        /// </summary>
        /// <param name="command"></param>
        /// <returns></returns>
        internal static async Task <DataTable> ExecuteFirstDataTableAsync(this SQLiteCommand command)
        {
            command.CheckNull(nameof(command));
            var ds = new DataSet();

            using var dataAdapter = new SQLiteDataAdapter(command);
            await Task.Run(() => dataAdapter.Fill(ds));

            return(ds.Tables[0]);
        }
 /// <summary>
 /// Execute DataTable
 /// </summary>
 /// <param name="command"></param>
 /// <returns></returns>
 public static Task <SQLiteDataReader> ExecuteReaderAsync(this SQLiteCommand command)
 {
     command.CheckNull(nameof(command));
     return(Task.Run(command.ExecuteReader));
 }