Many hyperlinks are disabled.
Use anonymous login
to enable hyperlinks.
Comment: | {6203} fixed TSynTableStatement parsing |
---|---|
Timelines: | family | ancestors | descendants | both | trunk |
Files: | files | file ages | folders |
SHA1: |
58a925fd5a9fb70960b80b95c2b20f7e |
User & Date: | ab 2021-01-15 08:37:25 |
2021-01-19
| ||
09:28 | {6204} move TZipWrite.AddFromZip to TZipWriteAbstract - from https://github.com/synopse/mORMot/pull/375 check-in: 0362b14fce user: ab tags: trunk | |
2021-01-15
| ||
08:37 | {6203} fixed TSynTableStatement parsing check-in: 58a925fd5a user: ab tags: trunk | |
2021-01-10
| ||
09:31 | {6202} fixed compilation ;) check-in: ef84a069f8 user: ab tags: trunk | |
Changes to SynSelfTests.pas.
822 823 824 825 826 827 828 829 830 831 832 833 834 835 836 837 838 839 840 841 842 843 844 ..... 15496 15497 15498 15499 15500 15501 15502 15503 15504 15505 15506 15507 15508 15509 ..... 15796 15797 15798 15799 15800 15801 15802 15803 15804 15805 15806 15807 15808 15809 |
// - a TSQLRecordHistory table will be used to store record history procedure ExternalViaRESTWithChangeTracking; {$ifndef CPU64} {$ifndef LVCL} {$ifdef MSWINDOWS} /// test external DB using the JET engine procedure JETDatabase; {$endif} {$endif} {$endif} {$ifdef MSWINDOWS} {$ifdef USEZEOS} /// test external Firebird embedded engine via Zeos/ZDBC (if available) procedure FirebirdEmbeddedViaZDBCOverHTTP; {$endif} {$endif} end; /// a test case for multi-threading abilities of the framework // - will test all direct or remote access protocols with a growing number // of concurrent clients (1,2,5,10,30,50 concurent threads), to ensure // stability, scalibility and safety of the framework TTestMultiThreadProcess = class(TSynTestCase) ................................................................................ property PeopleID: TID read fPeopleID write fPeopleID; property People: TSQLRecordPeopleID read fPeople write fPeople; property PeopleCascade: TSQLRecordPeopleToBeDeletedID read fPeopleCascade write fPeopleCascade; {$ifdef PUBLISHRECORD} property GUIDXE6: TGUID read fGUIDXE6 write fGUIDXE6; {$endif} end; class procedure TSQLRecordCustomProps.InternalRegisterCustomProperties(Props: TSQLRecordProperties); begin Props.RegisterCustomPropertyFromTypeName(self,'TGUID','GUID', @TSQLRecordCustomProps(nil).fGUID,[aIsUnique],38); end; ................................................................................ Test(dUnknown,false); Test(dDefault,false); Test(dOracle,true,'select id,firstname from SampleRecord where rownum<=2 order by firstname'); Test(dMSSQL,true,'select top(2) id,firstname from SampleRecord order by firstname'); Test(dJet,true,'select top 2 id,firstname from SampleRecord order by firstname'); Test(dMySQL,true,'select id,firstname from SampleRecord order by firstname limit 2'); Test(dSQLite,true,'select id,firstname from SampleRecord order by firstname limit 2'); finally Ext.Free; end; finally Props.Free; end; finally |
| | | | | > > > > > |
822 823 824 825 826 827 828 829 830 831 832 833 834 835 836 837 838 839 840 841 842 843 844 ..... 15496 15497 15498 15499 15500 15501 15502 15503 15504 15505 15506 15507 15508 15509 15510 15511 ..... 15798 15799 15800 15801 15802 15803 15804 15805 15806 15807 15808 15809 15810 15811 15812 15813 15814 |
// - a TSQLRecordHistory table will be used to store record history procedure ExternalViaRESTWithChangeTracking; {$ifndef CPU64} {$ifndef LVCL} {$ifdef MSWINDOWS} /// test external DB using the JET engine procedure JETDatabase; {$endif MSWINDOWS} {$endif LVCL} {$endif CPU64} {$ifdef MSWINDOWS} {$ifdef USEZEOS} /// test external Firebird embedded engine via Zeos/ZDBC (if available) procedure FirebirdEmbeddedViaZDBCOverHTTP; {$endif USEZEOS} {$endif MSWINDOWS} end; /// a test case for multi-threading abilities of the framework // - will test all direct or remote access protocols with a growing number // of concurrent clients (1,2,5,10,30,50 concurent threads), to ensure // stability, scalibility and safety of the framework TTestMultiThreadProcess = class(TSynTestCase) ................................................................................ property PeopleID: TID read fPeopleID write fPeopleID; property People: TSQLRecordPeopleID read fPeople write fPeople; property PeopleCascade: TSQLRecordPeopleToBeDeletedID read fPeopleCascade write fPeopleCascade; {$ifdef PUBLISHRECORD} property GUIDXE6: TGUID read fGUIDXE6 write fGUIDXE6; {$endif} end; { TSQLRecordCustomProps } class procedure TSQLRecordCustomProps.InternalRegisterCustomProperties(Props: TSQLRecordProperties); begin Props.RegisterCustomPropertyFromTypeName(self,'TGUID','GUID', @TSQLRecordCustomProps(nil).fGUID,[aIsUnique],38); end; ................................................................................ Test(dUnknown,false); Test(dDefault,false); Test(dOracle,true,'select id,firstname from SampleRecord where rownum<=2 order by firstname'); Test(dMSSQL,true,'select top(2) id,firstname from SampleRecord order by firstname'); Test(dJet,true,'select top 2 id,firstname from SampleRecord order by firstname'); Test(dMySQL,true,'select id,firstname from SampleRecord order by firstname limit 2'); Test(dSQLite,true,'select id,firstname from SampleRecord order by firstname limit 2'); SqlOrigin := 'SELECT RowID,firstname FROM PeopleExt WHERE :(3001): '+ 'BETWEEN firstname AND RowID LIMIT 1'; Test(dSQLite,false); finally Ext.Free; end; finally Props.Free; end; finally |
Changes to SynTable.pas.
7704 7705 7706 7707 7708 7709 7710 7711 7712 7713 7714 7715 7716 7717 7718 |
if P^<>',' then
break;
P := GotoNextNotSpace(P+1);
until P^ in [#0,';'];
end else
exit; // incorrect SQL statement
end else
if Prop<>'' then
exit else // incorrect SQL statement
break; // reached the end of the statement
end;
end else
if Prop<>'' then
goto lim2; // handle LIMIT OFFSET ORDER
fSQLStatement := SQL; // make a private copy e.g. for Where[].ValueSQL
|
| |
7704 7705 7706 7707 7708 7709 7710 7711 7712 7713 7714 7715 7716 7717 7718 |
if P^<>',' then
break;
P := GotoNextNotSpace(P+1);
until P^ in [#0,';'];
end else
exit; // incorrect SQL statement
end else
if (Prop<>'') or not(GotoNextNotSpace(P)^ in [#0, ';']) then
exit else // incorrect SQL statement
break; // reached the end of the statement
end;
end else
if Prop<>'' then
goto lim2; // handle LIMIT OFFSET ORDER
fSQLStatement := SQL; // make a private copy e.g. for Where[].ValueSQL
|
Changes to SynopseCommit.inc.
1 |
'1.18.6202'
|
| |
1 |
'1.18.6203'
|