NeonDataReader

NeonDataReader is a result type which will contain information about the result from a SQL query.
The class is defined like this:
    public class NeonDataReader
    {
        public int NumberOfRows => Rows.Count;
        public List<NeonDataRow> Rows { get; set; }
    }

Iterate Rows to access per-field data. 


NeonDataRow

The class is defined like this:
    public class NeonDataRow
    {
        public int FieldCount => Fields.Count;
        public List<object> Fields { get; set; }
    }

Iterate the list of fields or access them via an indexer to field specific data. Please note that the list contains untyped data so depending on which fields you have selected, you need to cast them to a specific type to get the proper result. 


Example

SELECT tblArtists.ArtistName, tblArtists.TotalItems 
FROM tblArtists 
WHERE tblArtists.ArtistName LIKE 'A%'

In this query two items per row will be returned. The first item is a string and the second is an integer.

To work with them via a script you will need to cast them for example like in the snippet below:


var line = string.Format("{0}, items: {1}", (string)row.Fields[0], (int)row.Fields[1]);