I would not focus so much about migration, but more on learning as much of Servoy as possible in the beginning. Then you will see a lot of ways how to do things like you listed.
BTW, your list could be extended to 100 points.
study also a lot of existing code that you find in those docs and links, and try to use it for your own purpose
engage an experienced developer for skype sessions twice a week to answer all your questions (that’s what I did, and it was the only way for me to get the project done in time)
Servoy might not be easy to learn at the very beginning, but once you got it, you can develop very fast and use a lot of powerful techniques.
One of the best things you can do is to study the source code of an existing framework. In such a framework, all the points you need to develop are already solved.
This one is a framework that comes with a free GNU license: http://community.data-sutra.com/projects/datasutra/wiki
As someone who has a Visual FoxPro background myself I found that useful a few years ago. However I wouldn’t use Servoy against DBF data unless you have to, especially if you use stored procedures, triggers and the like, because the various Java DBF connectors don’t support those.
I would also recommend not trying to replicate VFP in Servoy (or any other development stack). Have a look at the sample solutions and start off doing things ‘the Servoy way’. And learn Angular!
What might also be of interest is how to get data from DBF to postgres:
In VFP, open the DBF and then
COPY TO c:\tmp\filename.txt DELIMITED WITH CHARACTER “,”
First you have to take care that there are no " inside any text fields, e.g. with:
COUNT TO i FOR ‘"’ $ cangname
IF i > 0
REPLACE ALL cangname WITH STRTRAN(cangname, ‘"’) FOR ‘"’ $ cangname
ENDIF
(The ‘"’ is three characters like this: ’ " ')
Now open that file with Windows Editor and save it again but with UTF8 encoding (there is an option for that on the Windows Editor)
Create a similar table structure tmp_file_raw in postgres and then inside Servoy Developer SQL Editor:
COPY tmp_file_raw FROM ‘c:\tmp\filename.txt’ CSV;
Then you can convert the tmp_file_raw to your new table in postgres with an
INSERT INTO newTable () SELECT FROM tmp_file_raw
There are some things you have to look at, e.g. how to convert a date:
CASE WHEN LEFT(p_start,1) = ‘.’ THEN null ELSE to_date(p_start, ‘DD/MM/YY’) END AS p_start
Thanks a lot for your replies. I tried some sources and tried to do small application. I have not problems with databases, SQL is easy for me, but some “view” features still missing (or they are hidden). For example, common for FoxPro, how to force event by press “enter” key grid row?
How to change foreground color of field with “editable=false”? Still stay silver. I need to disable cell selection in a grid to make only rows highlighted when selected (as in FoxPro).
And very important question: how to rollback primary key?
As I said, you will have hundreds of such questions during learning Servoy.
I think I asked thousands of them in my skype sessions.
With help of the forum, I guess that will be not fast enough for you, because as soon as the forum would answer, you would have the next 5 questions.
You can find most of the answers in existing docs, sourcecode samples and here on the forum, though it would take you too long in searching.
Yes, it’s true But now I am trying to find edges of Servoy to make decision about future. To use or not to use? And some questions would make this clear.
Javascript, SQL, that’s not problem. Edges and “best practices” make product interesting. Problem with primary key should be solved by “ALTER TABLE customers AUTO_INCREMENT =1”, but isn’t it “dirty”?
Skype session is good idea, but good English is needed…
heindricke:
ALTER TABLE customers AUTO_INCREMENT =1
Personally, I do not like when tables have a lot of functionality on their own. For example, it may be needed to influence the next ID, which often serves as a running number.
Take a good look at the UUID concept too, it has its advantages. You would need to switch that on in the postgres Server, by the SQL-command
CREATE EXTENSION “uuid-ossp”;
What you could do about a decision regarding Servoy is to look at existing solutions, then you could see what can be done, without loosing much time to figure out every javascript line yourself. I could show you our solution, for example.
For helping learning Servoy by skype, there should be experienced Servoy developers in most main languages, the question would be if they have time, idleness and lust to offer skype consulting. Could be that Servoy offers that too, but I can not speak on behalf of them. I know for sure they offer consulting and training.
Hi Woody,
that wizzard sounds good, if I were new to Servoy I would take it as a help to see what it does.
However, when developing a new system, I would create everything from scratch on my own to really get the optimum.
When I created our new system, I switched for example from german field names to english field names, which turned out to be absolutely necessary when you have a team with english speaking developers.
And while we had only 10 characters for a field name in VFP, we have now 30 characters so that all field names describe themselves perfectly.
Also, when using a migration tool, all fields that should be deprecated or reworked are moved 1:1 into the new system, giving it a birth defect from the beginning.
What I would say with grids, lists and the like in the Servoy webclient - don’t try and make them into the VFP equivalents. Learn what their strengths are in Servoy.