Working examples for upcoming version

Working examples for upcoming version

lonnienlonnien Posts: 28Questions: 0Answers: 0
edited September 2012 in Editor
Since Allan has asked for suggestions to improve the examples in his upcoming release I thought I would kick it off in a new thread.

First of all, the examples are a lot of "busy" work to get going. You have to create a database for whatever flavour of Server, and if you do not use MySQL then you might have some interpretation to do. My suggestion is to use Sqlite for all examples. You can create a very small and simple downloadable and usable database for the examples and the user can very simply run the code and play. Once they get it going the way they like this then is the template for their own chosen database.

I think it is imperative to have a fully working solution with no chance that a user can miss a required step or introduce an error in the creation process. A ground zero, guaranteed to work on any system would sure help with the learning process.

Replies

  • allanallan Posts: 55,884Questions: 1Answers: 8,836 Site admin
    Thanks very much for the suggestion.

    The problem with using SQLite is that not all server environments are setup for it. It will also likely need paths configured, and if someone has never used SQLite before, it can have a small learning curve to get used to the idea that a single file is a database and needs to be configured as such.

    I think this applies to all server-side environments - its not trivial (sadly) to provide a framework which will work for everyone. In fact the only 'out of the box' example which will run immediately, is a localStorage one, of which there is an example: http://editor.datatables.net/release/DataTables/extras/Editor/examples/localstorage.html .

    The approach I've taken at the moment is to try and keep the installation instructions generic, since there are just so many options available.

    Allan
  • lonnienlonnien Posts: 28Questions: 0Answers: 0
    I understand. Even the so called standards are implemented differently between the various db servers. Not an easy task to be universal.
  • allanallan Posts: 55,884Questions: 1Answers: 8,836 Site admin
    @kp_sandy - I've deleted your comment from this discussion as 1. It was not relevant to this thread. 2, it was a cross post from another thread (which the forum rules specifically forbid).
  • burncharburnchar Posts: 118Questions: 12Answers: 0
    It seems to me that if any example database is provided, a developer should be able to translate that to his DBMS. Tables are tables, joins are joins -- the syntax differs only slightly other than for more complex queries. Same with any reasonable SQL. As for server-side logic, pseudo-code or Python (which is pretty close to pseudo-code) should suffice for the 90%+ situations.
    No one can expect example libraries in every popular platform. Even just within .NET there are many popular ways to talk to databases: EF, DBMS-specific queries, and nHibernate.
This discussion has been closed.