You are not logged in.
Can I ? I use Fossil in my job but I never used (I don't know) for external commits.
I'd love to do that.
Last edited by EMartin (2016-08-08 13:44:18)
Esteban
Offline
@Esteban, what if you fork the git repo?
Offline
Because, for me, is better belonging to a normal distribution of mORMot. I'll try make a pull request in the github mORMot repository.
Esteban
Offline
We have been working with your units for a project and we found these very usefull. We have added a few things in it, and decided to share them with you:
https://drive.google.com/open?id=0B0BLh … XM1amVzdlE
SynRestVCL:
- cast String<=>RawUTF8
- Params null handled
- Params string quoted
SynRestMidasVCL:
- cast String<=>RawUTF8
- DoBeforeDelete override instead of DoOnBeforeDelete
- SetCommandText ifdef ISDELPHIXE instead of XE2
If you think these small edits are relevant please update the files.
We'll keep following this thread for later update.
Offline
Thanks ! I'll try generate a pull request in github to @ab.
Esteban
Offline
@EMartin
good job! seem to more *mORMot* than SynDBVCL and SynDBMidasVCL.
Offline
lastest SynRestVCL and SynRestMidasVCL. when use ForceID the database insert only ID field and another fields is empty value. how to fix this problem?
this version https://drive.google.com/open?id=0B0BLh … XM1amVzdlE
when change
SynRestVCL.pas
line 733
fInsertedID := fRestClient.Add(fRec, fRec.RecordProps.FieldBitsFromCSV(fFieldNames), True);
to
fInsertedID := fRestClient.Add(fRec,True,true);
ForceID is work.
Last edited by xchinjo (2016-10-31 08:18:51)
Jongruk Aripoo
Offline
Updated SynRestDataset in https://drive.google.com/open?id=0Bx7LP … 3J6RG9oZVE
Change log:
SynRestVCL.pas
* Update Logeas Informatique 2016/09/12
- cast String<=>RawUTF8
- Params null handled
- Params string quoted
- (2016/12/14) removed QuoteStr in BindParams for avoid double quotation
- (2017/01/10)
* removed DeletedID
* refactoring, no functional changes
- (2017/01/16)
* added sftDateTimeMS, sftUnixTime to SQLFIELDTYPETODBFIELDTYPE and SQLFieldTypeToVCLDB
- (2017/02/07)
* add support to calculated fields (may be lookup fields too, but not tested) overriding CreateFields function
* added TTimeLogField, derived from TSQLTimeStampField and hacking ftTimeStamp
SynRestMidasVCL.pas
* Update Logeas Informatique 2016/09/12
- cast String<=>RawUTF8
- DoBeforeDelete override instead of DoOnBeforeDelete
- SetCommandText ifdef ISDELPHIXE instead of XE2
- added exists field ID verification
- (2017/01/17)
* removed DoBeforeDelete
* refactoring, no functional changes
- (2017/02/07)
* fixed unknown problem with datetime fields: TCustomClientDataset.DataConvert and NativeToDatetime patched
fFactWin.pas
- (2017-08-02)
* added calculated field example
* added field Modified: TModTime in SampleData unit and Project19Server.db3.BIOLIFE tabled
* added example display format in TModTime field
Esteban
Offline
Thank you, Esteban. Very useful changes.
Offline
Updated SynRestDataset in https://drive.google.com/open?id=0Bx7LP … jZFSE9hZ3c
Change log:
SynRestVCL.pas
- (2017/03/06)
* added support to field sftUnixMSTime
SynRestMidasVCL.pas
- (2017/03/01)
* fixed error when update datetime field (the content field updated with wrong value) in data convert patch routine
Readme.md
- (2017/03/06)
* Updated.
Esteban
Offline
Hello.
I want to know if there is a visual component for version SynRestVCL.
It's possible ?
Thanks.
Offline
No, but you can make it visual.
Best regards.
Esteban
Offline
I tried with Delphi 10.1 but when I add component on form as generate error : access violation error at address 00000000
can you help me ?
Thanks.
Offline
Hi Esteban,
SynRestDataset don't works with Mongo at backend?
( I have 404 resource not found....)
Thanks,
Stefano
Offline
Hi Stemon63, SynRestDataset use REST/JSON for ORM in a mORMot way, it should work with any mORMot backend through ORM tables.
Best regards.
Esteban.
Esteban
Offline
Ok Esteban,
where I can find latest release? (Maybe I have an old installation...)
Thanks,
Stefano
Offline
In this thread, the #60, but the TSynRestdataset is not the problem, maybe you not defined the ORM table or not call CreateMissingTables in the REST server.
Best regards.
Esteban
Esteban
Offline
Ok, Esteban.
With latest release works.
But I have a "invalid parameter" error on Applyupdates on some pc clients... (other works well...)
What I do wrong? :-)
Thanks in advance;
(wonderful component, the best is if it can be visual in IDE for assign fields to Db components, especially on forms with a lot of editors...)
Stefano
Offline
Esteban,
Why don't you clone the mORMot github repo and push your changes to it? It would be much more easier to get your patches this way.
Regards,
Leo
Last edited by leus (2017-04-07 15:08:55)
Offline
I prefer that when downloading mORMot all things together but as I cannot update the "ThirdParty\EMartin" folder maybe I should use github. I'll put in this thread when I have created the distribution in github.
Best regards.
Esteban
Offline
I prefer that when downloading mORMot all things together but as I cannot update the "ThirdParty\EMartin" folder maybe I should use github. I'll put in this thread when I have created the distribution in github.
Best regards.
That's the thing - you can clone the mORMot repository, and upload your changes to your repository. Then, by performing a pull request, you make things easier for @ab to merge your changes.
Also, it means that other users of the mORMot repository can pull your changes before they get merged into the main repository.
And you get your own set of goodies: commit history, submit issues, etc.
For example, I made a fix to your code in my own repository and then requested a pull: https://github.com/synopse/mORMot/pull/36
It's way, way better than zip archives in shared folders.
Offline
Yes, but I cannot rename/drop folders inside the my folder, I don't know other constraints.
Esteban
Offline
I tried with RadXE8 but when I add component on form as generate error : access violation error at address 00000000
can you help me ?
Thanks.
Offline
Hi Esteban,
is TSynRestdataset multiplatform? I have no tried on Android or iOS...
(I still am still looking for a solution about a strange "invalid parameter" error on Applyupdates on some pc clients)
Thanks!
Stefano
Offline
Yes, but I cannot rename/drop folders inside the my folder, I don't know other constraints.
Sure you can. Why do you think you can't do that?
Offline
@Stemon63, no it is. I documented that I don't know Linux.
@leus, because I tried.
Esteban
Offline
@leus, because I tried.
What did you tried? You clone a repository, make your local changes (including "git remove" and "git add" operations) then commit to your local branch. Then, pull request and if it is approved, all changes (including added and deleted files) get merged in.
If changing contents inside a folder wasn't allowed, git wouldn't be very useful, don't you think?
Offline
@leus, I'll try that, now I have not time.
Thanks.
Esteban
Offline
Hi Esteban,
I don't understand your answer :-)
I would like to known if TSynRestdataset is multiplatform about Android and Ios (osx), not linux....
Anyway, TsynRestdataset with mormot is almost 2,5 time faster than standard rest client + RestResponseDatasetAdapter + Fdmemtable (with the same mormot server, MongoDb, 100,000 little records fetched in a grid).
Stefano
Offline
I developed TSynRestdataset with Delphi 7 under Windows, for support the any other platform, I do not have the knowledge.
Esteban
Offline
Ok, Esteban... :-)
Offline
@EMartin, lastest your demo when change TSQLRecord (TSQLBiolife ) field
fModified:TModTime; --- to ---> fModified: TDateTime;
after rebuild all and run again your demo is error TDateTime Field.
Delphi Berlin upd1
Last edited by xchinjo (2017-05-27 12:51:33)
Jongruk Aripoo
Offline
Yes, is an general error with mORMot and Delphi Dataset from a few weeks ago, is not only TSynRestDataset problem. In the next two week I will be able to see to solve it.
Esteban
Offline
@EMartin
Any updates on this wondelful TSynRestDataset ?
Offline
when comment SynRestMidasVCL.pas 2 line RedirectCode
constructor TSynRestDataSet.Create(AOwner: TComponent);
begin
inherited Create(AOwner);
//RedirectCode(@TSynRestDataset.DataConvert, @TSynRestDataset.DataConvertPatch, @fDataConvertPatchBackup);
fProvider := TDataSetProvider.Create(Self);
fProvider.Name := 'InternalProvider'; { Do not localize }
fProvider.SetSubComponent(True);
fProvider.Options := fProvider.Options+[poAllowCommandText];
fProvider.OnUpdateError := DoOnUpdateError;
SetProvider(fProvider);
fDataSet := TSynRestSQLDataSet.Create(Self);
fDataSet.Name := 'InternalDataSet'; { Do not localize }
fDataSet.AfterInsert := Self.DoOnAfterInsert;
fDataSet.AfterOpen := Self.DoOnAfterOpen;
fDataSet.SetSubComponent(True);
fProvider.DataSet := fDataSet;
end;
destructor TSynRestDataSet.Destroy;
begin
fDataSet.AfterInsert := nil;
fProvider.DataSet := nil;
FreeAndNil(fDataSet);
FreeAndNil(fProvider);
//RedirectCodeRestore(@TSynRestDataset.DataConvert, fDataConvertPatchBackup);
inherited;
end;
datetime , date , time field is work fine for mORMot Commit number 1.18.3854
Last edited by xchinjo (2018-04-10 01:17:42)
Jongruk Aripoo
Offline
Hi @ab, I updated SynRestDataset to latest mORMot version and created a pull request on github.com, but I omitted directory EMartin in ThirdPartyDemos and I renamed TSynRestDataset directory to SynRestDataset. Can you correct this error ?
@xchinjo, I removed the patch with redirectcode.
Thanks.
Esteban
Offline
Esteban
Offline
@EMartin
The date of files SynRestVCL.pas and SynRestMidasVCl.pas is 10-04-2018. Is this correct?
Offline
Yes, is what i am currently using with Delphi 7.
Esteban
Offline
Are you using a old version of SynCommons too? Some enum type definitions that was in SynCommons.pas are now in SynTable.pas
All this
SQLFIELDTYPETODBFIELDTYPE: array[TSQLFieldType] of TSQLDBFieldType =
(SynCommons.ftUnknown, // sftUnknown
SynCommons.ftUTF8, // sftAnsiText
are now
SQLFIELDTYPETODBFIELDTYPE: array[TSQLFieldType] of TSQLDBFieldType =
(SynTable.ftUnknown, // sftUnknown
SynTable.ftUTF8, // sftAnsiText
Offline
You are right, I zipped wrong version, I have updated in https://drive.google.com/open?id=0Bx7LP … jZFSE9hZ3c.
Thanks.
Esteban
Offline
hi EMartin , made a mormot2 version TSynRestDataset :
Offline
I can't download.
Offline
you can try this url
https://drive.google.com/file/d/14hRTB7 … sp=sharing
Offline