S
Steve
Single call to ExecuteNonQuery() with "EXECUTE MyAccessQuery" creates 86
new, identical records.
Here is the code from the Access Query
<AccessQueryCode>
INSERT INTO Tbl_ProtocolSegments ( ProtocolID, FreqBStart, FreqBEnd,
DurationSec, [Count], AmplitudeRampID, OpCode )
SELECT [_protocolID] AS Expr1, [_freqBStart] AS Expr2, [_freqBEnd] AS
Expr3, [_durationSec] AS Expr4, [_count] AS Expr5, [_amplitudeRampID] AS
Expr6, [_opCode] AS Expr7
FROM Tbl_ProtocolSegments;
</AccessQueryCode>
Here is the DAL code:
<DalCode>
m_command.CommandText = GetAccessSprocString(m_spInsertSegment);
m_command.Parameters.Clear();
OleDbParameter param = new OleDbParameter("_protocolID",
segment.ProtocolID);
m_command.Parameters.Add(param);
param = new OleDbParameter("_freqBStart", segment.Frequency2Start);
m_command.Parameters.Add(param);
param = new OleDbParameter("_freqBEnd", segment.Frequency2End);
m_command.Parameters.Add(param);
param = new OleDbParameter("_durationSec", segment.Duration);
m_command.Parameters.Add(param);
param = new OleDbParameter("_count", segment.Count);
m_command.Parameters.Add(param);
param = new OleDbParameter("_amplitudeRampID",
segment.AmplitudeRampValue);
m_command.Parameters.Add(param);
param = new OleDbParameter("_opCode", segment.OpCodeValue);
m_command.Parameters.Add(param);
// open the connection and execute the update
m_connection.Open();
m_command.ExecuteNonQuery();
<DalCode>
I have NO idea what is causing this. I have never seen something like this
before. Has anyone here seen this? Any ideas?
Thanks for reading!
Steve
new, identical records.
Here is the code from the Access Query
<AccessQueryCode>
INSERT INTO Tbl_ProtocolSegments ( ProtocolID, FreqBStart, FreqBEnd,
DurationSec, [Count], AmplitudeRampID, OpCode )
SELECT [_protocolID] AS Expr1, [_freqBStart] AS Expr2, [_freqBEnd] AS
Expr3, [_durationSec] AS Expr4, [_count] AS Expr5, [_amplitudeRampID] AS
Expr6, [_opCode] AS Expr7
FROM Tbl_ProtocolSegments;
</AccessQueryCode>
Here is the DAL code:
<DalCode>
m_command.CommandText = GetAccessSprocString(m_spInsertSegment);
m_command.Parameters.Clear();
OleDbParameter param = new OleDbParameter("_protocolID",
segment.ProtocolID);
m_command.Parameters.Add(param);
param = new OleDbParameter("_freqBStart", segment.Frequency2Start);
m_command.Parameters.Add(param);
param = new OleDbParameter("_freqBEnd", segment.Frequency2End);
m_command.Parameters.Add(param);
param = new OleDbParameter("_durationSec", segment.Duration);
m_command.Parameters.Add(param);
param = new OleDbParameter("_count", segment.Count);
m_command.Parameters.Add(param);
param = new OleDbParameter("_amplitudeRampID",
segment.AmplitudeRampValue);
m_command.Parameters.Add(param);
param = new OleDbParameter("_opCode", segment.OpCodeValue);
m_command.Parameters.Add(param);
// open the connection and execute the update
m_connection.Open();
m_command.ExecuteNonQuery();
<DalCode>
I have NO idea what is causing this. I have never seen something like this
before. Has anyone here seen this? Any ideas?
Thanks for reading!
Steve