Federation Data - First Record Always Blank

Every time I display federation data, the first record is always blank, all other data is correct. My code is below:

Thanks

Item qry0 = this.newItem("MIN_1149");
qry0.setAttribute("select","msf");
qry0.setID(this.getProperty("source_id"));
Item res=qry0.apply("get");
string masterpart = res.getProperty("msf");

System.Data.OleDb.OleDbConnection myConnection = new System.Data.OleDb.OleDbConnection(@"Provider=SQLOLEDB;Data Source=000.00.0.0; Initial Catalog=AA; User ID=cc;Password=pp;");
string sqltext = "select aa,bb,cc,dd from WP where aa = '" + masterpart + "';";
System.Data.OleDb.OleDbCommand com = new System.Data.OleDb.OleDbCommand(sqltext);
com.Connection = myConnection;
myConnection.Open();
System.Data.OleDb.OleDbDataReader myDataReader = com.ExecuteReader();

Item res5 = this.newItem("MIN_1149_MSF");
res5.setID(getNewID());
res5 = res5.apply();

while (myDataReader.Read())
{
Item temp = this.newItem("MIN_1149_MSF1");   
temp.setProperty("aa",myDataReader.GetString(0));
temp.setProperty("bb",myDataReader.GetString(1));
temp.setProperty("cc",myDataReader.GetString(2));
temp.setProperty("dd",myDataReader.GetString(3));
res5.appendItem(temp); // Add a new item for each iteration of the loop
};
myConnection.Close();
return res5;

Parents Reply Children
No Data