本文整理汇总了C#中OracleDataReader类的典型用法代码示例。如果您正苦于以下问题:C# OracleDataReader类的具体用法?C# OracleDataReader怎么用?C# OracleDataReader使用的例子?那么恭喜您, 这里精选的类代码示例或许可以为您提供帮助。
OracleDataReader类属于命名空间,在下文中一共展示了OracleDataReader类的20个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于我们的系统推荐出更棒的C#代码示例。
示例1: PopulateDto
internal override DtoBase PopulateDto(OracleDataReader reader)
{
var turno = new TurnoDto();
//
if (!reader.IsDBNull(_ordTrnId)) { turno.TrnId = reader.GetInt32(_ordTrnId); }
//
if (!reader.IsDBNull(_ordTrnFecha)) { turno.TrnFecha = reader.GetString(_ordTrnFecha); }
//
if (!reader.IsDBNull(_ordTrnHora)) { turno.TrnHora = reader.GetString(_ordTrnHora); }
//
if (!reader.IsDBNull(_ordTrnMontoCobrado)) { turno.TrnMontoCobrado = reader.GetInt32(_ordTrnMontoCobrado); }
//
if (!reader.IsDBNull(_ordTrnEstId)) { turno.TrnEstId = reader.GetInt32(_ordTrnEstId); }
//
if (!reader.IsDBNull(_ordTrnProId)) { turno.TrnProId = reader.GetInt32(_ordTrnProId); }
//
if (!reader.IsDBNull(_ordTrnSesId)) { turno.TrnSesId = reader.GetInt32(_ordTrnSesId); }
//
if (!reader.IsDBNull(_ordTrnPaeId)) { turno.TrnPaeId = reader.GetInt32(_ordTrnPaeId); }
//
if (!reader.IsDBNull(_ordTrnDatId)) { turno.TrnDatId = reader.GetInt32(_ordTrnDatId); }
//
if (!reader.IsDBNull(_ordTrnOspId)) { turno.TrnOspId = reader.GetInt32(_ordTrnOspId); }
// IsNew
turno.IsNew = false;
return turno;
}
开发者ID:TheChapadiex,项目名称:FISIKS,代码行数:28,代码来源:DpTurno.cs
示例2: SafeReadInt
/// <summary>
/// Safely reads int values from the database if they are null
/// </summary>
/// <param name="odr">oracle datareader</param>
/// <param name="colindex">column index</param>
/// <returns>-1 if null otherwise value from DB</returns>
int SafeReadInt(OracleDataReader odr, int colindex)
{
if (!odr.IsDBNull(colindex))
return odr.GetInt32(colindex);
else
return -1;
}
开发者ID:Maurice1996,项目名称:LivePerformance,代码行数:13,代码来源:Databasehandler.cs
示例3: ReadGroups
private IEnumerable<Group> ReadGroups(OracleDataReader reader)
{
var groups = new List<Group>();
Group group;
Group lastGroup = null;
Word word;
while ((group = ReadGroupWord(reader, out word)) != null)
{
if (lastGroup == null)
lastGroup = group;
if (lastGroup.Name != group.Name)
{
groups.Add(lastGroup);
lastGroup = group;
}
lastGroup.Words.Add(word);
}
if (lastGroup != null)
groups.Add(lastGroup);
return groups;
}
开发者ID:elital,项目名称:ConcoRep,代码行数:26,代码来源:GroupQuery.cs
示例4: PopulateOrdinals
internal override void PopulateOrdinals(OracleDataReader reader)
{
_ordTstId = reader.GetOrdinal("tstId");
_ordTstObservacion = reader.GetOrdinal("tstObservacion");
_ordTstZcuId = reader.GetOrdinal("tst_zcuId");
_ordTstTptId = reader.GetOrdinal("tst_tptId");
}
开发者ID:TheChapadiex,项目名称:FISIKS,代码行数:7,代码来源:DpTest.cs
示例5: PopulateOrdinals
internal override void PopulateOrdinals(OracleDataReader reader)
{
_ordVacId = reader.GetOrdinal("vacId");
_ordVacFechaDesde = reader.GetOrdinal("vacFechaDesde");
_ordVacFechaHasta = reader.GetOrdinal("vacFechaHasta");
_ordVacProId = reader.GetOrdinal("vac_proId");
}
开发者ID:TheChapadiex,项目名称:FISIKS,代码行数:7,代码来源:DpVacaciones.cs
示例6: PopulateOrdinals
internal override void PopulateOrdinals(OracleDataReader reader)
{
_ordOspId = reader.GetOrdinal("ospId");
_ordOspPaeId = reader.GetOrdinal("osp_paeId");
_ordOspOsoId = reader.GetOrdinal("osp_osoId");
_ordOspNroSocio = reader.GetOrdinal("OspNroSocio");
}
开发者ID:TheChapadiex,项目名称:FISIKS,代码行数:7,代码来源:DPPacienteOs.cs
示例7: PopulateOrdinals
internal override void PopulateOrdinals(OracleDataReader reader)
{
_ordZcuId = reader.GetOrdinal("zcuId");
_ordZcuDescripcion = reader.GetOrdinal("zcuDescripcion");
_ordZcuNivel = reader.GetOrdinal("zcuNivel");
_ordZcuIdPadre = reader.GetOrdinal("zcuIdPadre");
}
开发者ID:TheChapadiex,项目名称:FISIKS,代码行数:7,代码来源:DpZonaCuerpo.cs
示例8: ReadPhrases
private IEnumerable<Phrase> ReadPhrases(OracleDataReader reader)
{
var phrases = new List<Phrase>();
Phrase phrase;
Phrase lastPhrase = null;
PhraseWord word;
while ((phrase = ReadPhraseWord(reader, out word)) != null)
{
if (lastPhrase == null)
lastPhrase = phrase;
if (lastPhrase.PhraseNumber != phrase.PhraseNumber)
{
phrases.Add(lastPhrase);
lastPhrase = phrase;
}
lastPhrase.Words.Add(word);
}
if (lastPhrase != null)
phrases.Add(lastPhrase);
return phrases;
}
开发者ID:elital,项目名称:ConcoRep,代码行数:26,代码来源:PhraseQuery.cs
示例9: ReadRelations
private IEnumerable<Relation> ReadRelations(OracleDataReader reader)
{
var relations = new List<Relation>();
Relation relation;
Relation lastRelation = null;
Pair pair;
while ((relation = ReadRelationPair(reader, out pair)) != null)
{
if (lastRelation == null)
lastRelation = relation;
if (lastRelation.Name != relation.Name)
{
relations.Add(lastRelation);
lastRelation = relation;
}
lastRelation.Pairs.Add(pair);
}
if (lastRelation != null)
relations.Add(lastRelation);
return relations;
}
开发者ID:elital,项目名称:ConcoRep,代码行数:26,代码来源:RelationQuery.cs
示例10: SafeReadString
/// Safely reads string values from the database if they are null
///<returns>empty string otherwise value from DB</returns>
string SafeReadString(OracleDataReader odr, int colindex)
{
if (!odr.IsDBNull(colindex))
return odr.GetString(colindex);
else
return string.Empty;
}
开发者ID:Maurice1996,项目名称:LivePerformance,代码行数:9,代码来源:Databasehandler.cs
示例11: SafeReadDateTime
/// Safely reads datetime values from the database if they are null
///<returns>datetime minimimvalue if null otherwise value from DB</returns>
DateTime SafeReadDateTime(OracleDataReader odr, int colindex)
{
if (!odr.IsDBNull(colindex))
return odr.GetDateTime(colindex);
else
return DateTime.MinValue;
}
开发者ID:Maurice1996,项目名称:LivePerformance,代码行数:9,代码来源:Databasehandler.cs
示例12: PopulateOrdinals
internal override void PopulateOrdinals(OracleDataReader reader)
{
_ordAfnId = reader.GetOrdinal("afnId");
_ordAfnDescripcion = reader.GetOrdinal("afnDescripcion");
_ordAfnTafId = reader.GetOrdinal("afn_tafId");
_ordAfnZcuId = reader.GetOrdinal("afn_zcuId");
}
开发者ID:TheChapadiex,项目名称:FISIKS,代码行数:7,代码来源:DPAfecciones.cs
示例13: PopulateDto
internal override DtoBase PopulateDto(OracleDataReader reader)
{
var turno = new TurneroDto();
//
if (!reader.IsDBNull(_ordTurId)) { turno.TurId = reader.GetInt32(_ordTurId); }
//
if (!reader.IsDBNull(_ordTurTitulo)) { turno.TurTitulo = reader.GetString(_ordTurTitulo); }
//
if (!reader.IsDBNull(_ordTurDescripcion)) { turno.TurDescripcion = reader.GetString(_ordTurDescripcion); }
//
if (!reader.IsDBNull(_ordTurFechaIni)) { turno.TurFechaIni = reader.GetDateTime(_ordTurFechaIni); }
//
if (!reader.IsDBNull(_ordTurFechaFin)) { turno.TurFechaFin = reader.GetDateTime(_ordTurFechaFin); }
//
if (!reader.IsDBNull(_ordTurTodoDia)) { turno.TurTodoDia = reader.GetString(_ordTurTodoDia); }
//
if (!reader.IsDBNull(_ordTurPae)) { turno.TurPae = reader.GetInt32(_ordTurPae); }
//
if (!reader.IsDBNull(_ordTurPro)) { turno.TurPro= reader.GetInt32(_ordTurPro); }
//
if (!reader.IsDBNull(_ordTurMonto)) { turno.TurMonto = reader.GetDecimal(_ordTurMonto); }
//
if (!reader.IsDBNull(_ordTurOspId)) { turno.TurOspId = reader.GetInt32(_ordTurOspId); }
// IsNew
turno.IsNew = false;
return turno;
}
开发者ID:facujuarez,项目名称:FISIKS,代码行数:28,代码来源:DpTurno.cs
示例14: ReadSequenceValue
private int ReadSequenceValue(OracleDataReader reader)
{
if (!reader.Read())
return 0;
return (int)(decimal)reader[SequenceValueColumn];
}
开发者ID:elital,项目名称:ConcoRep,代码行数:7,代码来源:SequenceQuery.cs
示例15: GetInfo
public static Employee GetInfo(OracleDataReader reader, DPFP.Sample Sample, string Finger)
{
OracleConnection conn = new OracleConnection(ConStr);
Employee _info = null;
DPFP.Template _template = null;
bool IsFound = false;
if (reader[Finger] != DBNull.Value)
{
_template = Util.ProcessDBTemplate((byte[])reader[Finger]);
IsFound = Util.Verify(Sample, _template);
}
if (IsFound == true)
{
string sqlEmp = "select * from employees where Empl_Id_No=" + reader["Empl_Id_No"];
OracleCommand cmd = new OracleCommand(sqlEmp, conn);
cmd.CommandType = CommandType.Text;
conn.Open();
OracleDataReader odr = cmd.ExecuteReader();
if (odr.HasRows)
{
_info = new Employee();
_info.Empl_Id_No = Convert.ToInt32(reader["Empl_Id_No"]);
_info.Empl_Name = (string)odr["Empl_Name"];
_info.Empl_Deptname = (string)odr["Empl_Deptname"];
_info.Shift_Id = Convert.ToInt32(odr["Shift_Id"]);
}
odr.Dispose();
cmd.Dispose();
conn.Close();
conn.Dispose();
}
return _info;
}
开发者ID:BGCX262,项目名称:zsicam-svn-to-git,代码行数:34,代码来源:dcEmployee.cs
示例16: CreateBlogBerichtFromReader
public BlogBericht CreateBlogBerichtFromReader(OracleDataReader reader)
{
int blogBerichtId = Convert.ToInt32(reader["BLOGBERICHTID"]);
int categorieId = Convert.ToInt32(reader.GetOrdinal("CATEGORIEID"));
int actualCategorieId = SafeGetInt(reader, categorieId);
int productId = Convert.ToInt32(reader.GetOrdinal("PRODUCTID"));
int actualProductId = SafeGetInt(reader, productId);
string titel = Convert.ToString(reader["TITEL"]);
DateTime datum = Convert.ToDateTime(reader["DATUM"]);
string tekst = Convert.ToString(reader["TEKST"]);
int afbeeldingPath = Convert.ToInt32(reader.GetOrdinal("AFBEELDINGPATH"));
string actualAfbeeldingPath = SafeGetString(reader, afbeeldingPath);
Categorie c = null;
foreach (Categorie categorie in GetAlleCategorien())
{
if (categorie.CategorieId == categorieId)
{
c = categorie;
}
}
return new BlogBericht(blogBerichtId, titel, datum, tekst, actualAfbeeldingPath, c);
}
开发者ID:laurent-devries,项目名称:DixonsAspOfficieel,代码行数:28,代码来源:CreateScripts.cs
示例17: PopulateOrdinals
internal override void PopulateOrdinals(OracleDataReader reader)
{
_ordProId = reader.GetOrdinal("proId");
_ordProMatricula = reader.GetOrdinal("proMatricula");
_ordProTelefonoInterno = reader.GetOrdinal("proTelefonoInterno");
_ordProPsnId = reader.GetOrdinal("pro_psnId");
}
开发者ID:TheChapadiex,项目名称:FISIKS,代码行数:7,代码来源:DPProfesional.cs
示例18: SafeReadDecimal
/// Safely reads decimal values from the database if they are null
///<returns>0 if null otherwise value from DB</returns>
decimal SafeReadDecimal(OracleDataReader odr, int colindex)
{
if (!odr.IsDBNull(colindex))
return odr.GetDecimal(colindex);
else
return 0;
}
开发者ID:Maurice1996,项目名称:LivePerformance,代码行数:9,代码来源:Databasehandler.cs
示例19: PopulateOrdinals
internal override void PopulateOrdinals(OracleDataReader reader)
{
_ordOsoId = reader.GetOrdinal("osoId");
_ordOsoDescripcion = reader.GetOrdinal("osoDescripcion");
_ordOsoCoseguro = reader.GetOrdinal("osoCoseguro");
_ordOsoContacto = reader.GetOrdinal("osoContacto");
}
开发者ID:TheChapadiex,项目名称:FISIKS,代码行数:7,代码来源:DpObraSocial.cs
示例20: CreateTelgebiedFromReader
private TelGebied CreateTelgebiedFromReader(OracleDataReader reader)
{
return new TelGebied(
Convert.ToInt32(reader["ID"]),
Convert.ToString(reader["Naam"]),
Convert.ToString(reader["PathMap"])
);
}
开发者ID:Masterm0use,项目名称:MarioSchipper_LivePerformance_19-1,代码行数:8,代码来源:DatabaseCreateFromReader.cs
注:本文中的OracleDataReader类示例整理自Github/MSDocs等源码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。 |
请发表评论