일부 데이터베이스 (sqlserver)를 동기화하는 응용 프로그램이 있습니다. 기술자 데이터베이스 (SQLExpress 2008 32 비트) 및 서버 측 SqlServer 2008 R2 64 비트.모바일 광대역을 사용하는 adodb의 일반 네트워크 오류
동기화 응용 프로그램에서 일부 스크립트를 동기화 할 수 있습니다. 기술자로부터 서버에 이르는 데이터베이스. 은 지금은 내가 업데이 트를 만들려는 로그인 스크립트에서 오류
--21/10/2013 11:05:12------------Update on t_intervention_mission--------------------------------
Old Values:
ID=0,RowID={06938E13-F068-437D-A454-3E17B4C7CCC6},IntCardID= NULL,IntCardRowID={69D86DD9-55E5-450F-BC72-93FE2DB5BA1E},MissionID= NULL,MissionRowID={7D1F046F-C82A-42AA-9712-00D4F7FEC5BF},Duration=CONVERT(DATETIME,'1899-12-30 00:00:00.000', 102),Number=1,InCalculation=0,KindID= NULL,KindRowID={D2BD32AD-5926-4AF6-9258-F52F453800A8},WorkTime=0,PayerReference='r',WorkOut=0,ImmovableProperty=1,VatPercent=21,DurationChange=0,DefaultMissionPrice=0,ProductCount=0,DeliverProductPrice=0,DeliverWorkPrice=0,DeliverTransportPrice=0,DeliverMissionPrice=0,DeliverTotalPrice=0,ActiveProductPrice=0,ActiveWorkPrice=0,ActiveTransportPrice=0,ActiveMissionPrice=0,ActiveTotalPrice=0,TariffID= NULL,TariffRowID= NULL,WorkCostPercent=0,WorkCostPlus=0,WorkAmountPercent=0,WorkAmountPlus=0,ProductAmountPercent=0,ProductAmountPlus=0,TransportCostPercent=0,TransportCostPlus=0,TransportAmountPercent=0,TransportAmountPlus=0,MissionAmountPercent=0,MissionAmountPlus=0,DateCreate=CONVERT(DATETIME,'2013-10-21 11:02:36.083', 102),DateChange=CONVERT(DATETIME,'2013-10-21 11:05:00.620', 102),WorkStationCreate='SIX001',WorkStationChange='SIX001',ContractPrice=0,IsSafeCondition= NULL
Script:
update t_intervention_mission set PayerReference='r',DateChange=CONVERT(DATETIME,'2013-10-21 11:05:00.620', 102) where RowID = '{06938E13-F068-437D-A454-3E17B4C7CCC6}'
--ERROR--EOleException--------------------------------------------------------------------
[DBNETLIB][ConnectionWrite (send()).]Algemene netwerkfout. Raadpleeg de netwerkdocumentatie
On script: update t_intervention_mission set PayerReference='r',DateChange=CONVERT(DATETIME,'2013-10-21 11:05:00.620', 102) where RowID = '{06938E13-F068-437D-A454-3E17B4C7CCC6}'
Connection:AdoConnectionServer
Number = -2147467259
NativeError = 11
Source = Microsoft OLE DB Provider for SQL Server
Description = [DBNETLIB][ConnectionWrite (send()).]Algemene netwerkfout. Raadpleeg de netwerkdocumentatie.
Helpfile =
SQLState = HY018
ConnectionTimeOut = 60
CommandTimeout = 120
--21/10/2013 11:05:41----------------------------------------------------------------
에 대한 몇 가지 로그를 만들었어요 [(() 전송). ConnectionWrite]를
[DBNETLIB]와 같은 오류를 얻을. 또한 promql에서 sqlserver에 시간을 초월하는 핑을 설정합니다. 스크립트가 업데이트를 실행하면 ping이 시간 초과됩니다.
이 오류는 모바일 광대역 연결이있는 경우에만 발생합니다. 기술자가 회사에 도착하면 랩톱이 회사의 무선 랜을 찾아 스크립트를 수행 할 수 있습니다. 모바일 광대역 연결에서만 오류가 발생합니다.
function TLogFile.SqlExec (StrSql : String; AdoConnection : TADOConnection; ARec: _RecordSet): Integer;
begin
Result := 0;
try
ARec := AdoConnection.Execute(StrSql, cmdText);
except
on E : Exception do
begin
E.Message:= E.Message+ craConstant.CRLF+
'On script: '+StrSql+ craConstant.CRLF+
'Connection:'+ AdoConnection.Name;
if (E.ClassType = EOleException) and (AdoConnection.Errors.Count > 0) then
begin
E.Message:= E.Message+ craConstant.CRLF+
'Number ='+IntToStr(AdoConnection.Errors[0].Number)+CRLF+
'NativeError ='+IntToStr(AdoConnection.Errors[0].NativeError)+CRLF+
'Source ='+AdoConnection.Errors[0].Source+CRLF+
'Description ='+AdoConnection.Errors[0].Description+CRLF+
'Helpfile ='+AdoConnection.Errors[0].HelpFile+CRLF+
'SQLState ='+AdoConnection.Errors[0].SQLState;
end;
self.HndException:= E;
Result := -1;
raise;
end;
end;
end;
내가 그랬어 기능 SQLEXEC에 약간의 변화 :이 변경 3 일 확인했다
function TLogFile.SqlExec (StrSql : String; AdoConnection : TADOConnection): Integer;
var
oQuerySql: TADOQuery;
begin
Result := 0;
oQuerySql:= TADOQuery.Create(Nil);
try
oQuerySql.Connection:= AdoConnection;
oQuerySql.CommandTimeout:= AdoConnection.CommandTimeout;
oQuerySql.SQL.Add(StrSql);
try
oQuerySql.ExecSQL;
except
on E : Exception do
begin
E.Message:= E.Message+ craConstant.CRLF+
'On script: '+StrSql+ craConstant.CRLF+
'Connection:'+ AdoConnection.Name;
if (E.ClassType = EOleException) and (AdoConnection.Errors.Count > 0) then
begin
E.Message:= E.Message+ craConstant.CRLF+
'Number = '+IntToStr(AdoConnection.Errors[0].Number)+CRLF+
'NativeError = '+IntToStr(AdoConnection.Errors[0].NativeError)+CRLF+
'Source = '+AdoConnection.Errors[0].Source+CRLF+
'Description = '+AdoConnection.Errors[0].Description+CRLF+
'Helpfile = '+AdoConnection.Errors[0].HelpFile+CRLF+
'SQLState = '+AdoConnection.Errors[0].SQLState+CRLF+
'ConnectionTimeOut = '+IntToStr(AdoConnection.ConnectionTimeout) +CRLF+
'CommandTimeout = '+IntToStr(AdoConnection.CommandTimeout);
end;
self.HndException:= E;
Result := -1;
raise;
end;
end;
finally
FreeAndNil(oQuerySql);
end;
end;
가, 지금은
--21/10/2013 14:11:05------------Insert on t_intervention_mission----------------------------------------------------
Old Values:
ID=0,RowID={53C5780D-B683-45C9-B942-018091DD0435},IntCardID= NULL,IntCardRowID={0709FB3B-1CDD-4E2B-BAC6-4FB6A952F788},MissionID= NULL,MissionRowID={C24234F2-DD1F-4B3B-B81D-3D13384CC573},Duration=CONVERT(DATETIME,'1899-12-30 00:20:00.000', 102),Number=1,InCalculation=0,KindID= NULL,KindRowID={77387E4C-604A-4653-B490-38A6B9C5A8E5},WorkTime=0,PayerReference= NULL,WorkOut=1,ImmovableProperty=1,VatPercent=0,DurationChange=0,DefaultMissionPrice=0,ProductCount=0,DeliverProductPrice=0,DeliverWorkPrice=0,DeliverTransportPrice=0,DeliverMissionPrice=0,DeliverTotalPrice=0,ActiveProductPrice=0,ActiveWorkPrice=13.54,ActiveTransportPrice=11.01,ActiveMissionPrice=0,ActiveTotalPrice=24.55,TariffID= NULL,TariffRowID={DADB09D9-A760-4213-98AA-47E090EAB1FD},WorkCostPercent=0,WorkCostPlus=0,WorkAmountPercent=30,WorkAmountPlus=0,ProductAmountPercent=0,ProductAmountPlus=0,TransportCostPercent=0,TransportCostPlus=0,TransportAmountPercent=0,TransportAmountPlus=0,MissionAmountPercent=0,MissionAmountPlus=0,DateCreate=CONVERT(DATETIME,'2013-09-02 08:37:54.530', 102),DateChange=CONVERT(DATETIME,'2013-09-02 08:38:06.460', 102),WorkStationCreate='SIX001',WorkStationChange='SIX001',ContractPrice=0,IsSafeCondition= NULL
Script:
insert into t_intervention_mission (RowID,IntCardRowID,MissionRowID,Duration,Number,InCalculation,KindRowID,WorkTime,WorkOut,ImmovableProperty,VatPercent,DurationChange,DefaultMissionPrice,ProductCount,DeliverProductPrice,DeliverWorkPrice,DeliverTransportPrice,DeliverMissionPrice,DeliverTotalPrice,ActiveProductPrice,ActiveWorkPrice,ActiveTransportPrice,ActiveMissionPrice,ActiveTotalPrice,TariffRowID,WorkCostPercent,WorkCostPlus,WorkAmountPercent,WorkAmountPlus,ProductAmountPercent,ProductAmountPlus,TransportCostPercent,TransportCostPlus,TransportAmountPercent,TransportAmountPlus,MissionAmountPercent,MissionAmountPlus,DateCreate,DateChange,WorkStationCreate,WorkStationChange,ContractPrice) values ('{53C5780D-B683-45C9-B942-018091DD0435}','{0709FB3B-1CDD-4E2B-BAC6-4FB6A952F788}','{C24234F2-DD1F-4B3B-B81D-3D13384CC573}',CONVERT(DATETIME,'1899-12-30 00:20:00.000', 102),1,0,'{77387E4C-604A-4653-B490-38A6B9C5A8E5}',0,1,1,0,0,0,0,0,0,0,0,0,0,13.54,11.01,0,24.55,'{DADB09D9-A760-4213-98AA-47E090EAB1FD}',0,0,30,0,0,0,0,0,0,0,0,0,CONVERT(DATETIME,'2013-09-02 08:37:54.530', 102),CONVERT(DATETIME,'2013-09-02 08:38:06.460', 102),'SIX001','SIX001',0)
--ERROR--EOleException--------------------------------------------------------------------
[DBNETLIB][ConnectionWrite (send()).]Algemene netwerkfout. Raadpleeg de netwerkdocumentatie
On script: insert into t_intervention_mission (RowID,IntCardRowID,MissionRowID,Duration,Number,InCalculation,KindRowID,WorkTime,WorkOut,ImmovableProperty,VatPercent,DurationChange,DefaultMissionPrice,ProductCount,DeliverProductPrice,DeliverWorkPrice,DeliverTransportPrice,DeliverMissionPrice,DeliverTotalPrice,ActiveProductPrice,ActiveWorkPrice,ActiveTransportPrice,ActiveMissionPrice,ActiveTotalPrice,TariffRowID,WorkCostPercent,WorkCostPlus,WorkAmountPercent,WorkAmountPlus,ProductAmountPercent,ProductAmountPlus,TransportCostPercent,TransportCostPlus,TransportAmountPercent,TransportAmountPlus,MissionAmountPercent,MissionAmountPlus,DateCreate,DateChange,WorkStationCreate,WorkStationChange,ContractPrice) values ('{53C5780D-B683-45C9-B942-018091DD0435}','{0709FB3B-1CDD-4E2B-BAC6-4FB6A952F788}','{C24234F2-DD1F-4B3B-B81D-3D13384CC573}',CONVERT(DATETIME,'1899-12-30 00:20:00.000', 102),1,0,'{77387E4C-604A-4653-B490-38A6B9C5A8E5}',0,1,1,0,0,0,0,0,0,0,0,0,0,13.54,11.01,0,24.55,'{DADB09D9-A760-4213-98AA-47E090EAB1FD}',0,0,30,0,0,0,0,0,0,0,0,0,CONVERT(DATETIME,'2013-09-02 08:37:54.530', 102),CONVERT(DATETIME,'2013-09-02 08:38:06.460', 102),'SIX001','SIX001',0)
Connection:AdoConnectionServer
Number =-2147467259
NativeError =11
Source =Microsoft OLE DB Provider for SQL Server
Description =[DBNETLIB][ConnectionWrite (send()).]Algemene netwerkfout. Raadpleeg de netwerkdocumentatie.
Helpfile =
SQLState =HY018
--21/10/2013 14:11:37----------------------------------------------------------------
I처럼 다시 삽입 스크립트에 오류가 바닥에있는 기술자에게 연락하십시오. 오래 된 함수 TLogFile.SqlExec (StrSql : String; AdoConnection : TADOConnection; ARec : _RecordSet)을 사용하여 이전 싱크로 응용 프로그램을 실행합니다. 이 스크립트는 오류를주지 않습니다. AdoConnection.Execute (StrSql, cmdText) VS oQuerySql.ExecSQL; 연결 및 스크립트는 스레드에서 수행됩니다.
구형 노트북 (Windows XP)에서는이 문제가 없습니다. Windows7이 설치된 새 랩톱 전용.
누군가가 문제를 검색 할 부분에 대한 설명이나 조언을 제공 할 수 있다면. 나는 그것을 평가할 것이다. 'SQL Server Native Client 10.0'과 'SQL Server 용 Microsoft OLE DB 공급자'간에는 차이점이 있습니까? 나는 내가 노트북 (파나소닉)의 회사에 문제를 물어
박쥐 바로 외치다가 SQL Native Client (SQLNCLI)가 Windows에 사전 설치되어 있지 않습니다. Visual Studio 또는 SQL Server와 같은 일부 기능은이를 설치할 수 있지만 Windows와 함께 제공되지는 않습니다. –
@JerryDodge : 이미 코드를 SQLNCLI로 변경했습니다. 팁 고마워. 코드를 롤백하고 SQLOLEDB.1 만 사용합니다. – Ravaut123
이 도움이 되었습니까? –