The All method returns all data from a table.
public SimpleQuery All( Object[] filterExpressions )
filterExpressionsobject[]filterExpressions are silently ignored by All().Type: SimpleQuery
A collection of SimpleRecord objects which can be iterated over.
The following example returns all the rows of the Albums table and outputs all the album titles to the Console window.
var albums = Database.Open().Albums.All();
foreach (var album in albums)
{
Console.WriteLine(album.Title);
}
Simple.Data sends the following SQL to the database when albums is evaluated.
select [dbo].[Album].[AlbumId], [dbo].[Album].[GenreId], [dbo].[Album].[ArtistId], [dbo].[Album].[Title], [dbo].[Album].[Price], [dbo].[Album].[AlbumArtUrl] from [dbo].[Album]
(which equates to select * from [dbo].[Album])