Do I need to know SQL to learn 4D database? - 4d-database

i was offered a task in relation to 4D database, however, I do not have any database skill such as SQL, I can program but not in database aspect, just wondering should I learn some SQL before 4D database? Or are they totally different? Thanks for suggestion.

4D is much more than just a database; it includes a GUI designer, has it's own programming language and includes a compiler for building double-clickable applications. There are many plugins extending the product and a plugin SDK that allows you to write c++ code to extend it yourself. The possibilities of 4D are pretty limitless. The main point here is that you could create an application that does not even use the database engine therefore database background would not be so important.
You don't need to know SQL to program in 4D. There is a sql layer but you can also use the non-SQL commands to achieve most of the same tasks. Granted that SQL may be better suited for some tasks, and the only option for others (see replication and synchronization). In general you should learn SQL as it will help in many different languages but don't let not knowing SQL stop you from using or learning 4D.
The 4D programming language has extensive documentation on doc.4d.com:
The 4D Language Reference contains the core commands
The 4D SQL reference covers the SQL aspect of the language.
The 4D Design Reference covers aspects of the design environment.
There is also a short crash course section on wikipedia that may be helpful to give you a glimpse of the language

Related

SQL vs MySQL vs. SMSS vs. RDBMS

I am starting into studying SQL and am having trouble understanding the relationships between the various components.
To my understanding, SQL is a langauge (akin to PHP, JS, etc.) which is used to interact with databases.
MySQL seems to be a specific software, a specific RDBMS, but how exactly does it relate with SQL and SSMS? Is it the thing that actually stores the data, or does it simply manage them by interpreting SQL commands? I'm mostly confused on what the SSMS does then.
Any help or tips on such subjects would be appreciated, though I understand if this topic is not specific enough and needs to be removed.

Sample datasets for practice - Oracle pl/sql

I am a new user of SQL, I use Oracle pl/sql as a Programming software. I have done an introductory course to SQL that included some datasets. However I'd like to continue practicing, some real life problems that include requests of querying very simple statements to difficult ones that include indexes, etc.
Does anyone have any links/sites where I can further pursue SQL training for free? I've done a Stakexchange and Google search with not much luck.
As you probably know, Oracle ussually comes with some sample schemas like HR, SH... listed here
Also, you can install HammerOra benchmarking tool. It's commonly used to test TPC-C and TPC-H on different RDBMS. It will install some schemas on your DB with variable size.
You can also install some virtual appliances.
There are more there, but I think the coolest is StackOverflow DB, too bad is MSSQL.

Migration of Database

As a Front end developer I have less knowledge on Databases. But recently we started to develop an CRM application.
My question is, how feasible to migrate from one database to other. Lets say our application now supports mysql but later customer comes up with IBM's DB2 or sql lite. What are the things that we need to take care while developing to support easy migration ?
How cloud will help to solve my problem?
Just keep your data model separate from actual database calls and you should be good. Use a database abstraction layer in your model to make calls to the database. You'll only have to change the bottom layer for specific databases.
Some best practices:
Avoid DBMS specific features, data types and SQL/DDL constructs; keep to the SQL[92] standard. Test against e. g. SQLite, which keeps rather close to the standard.
Use an Entity Relationship Modeling tool that supports exporting DDL files for all targeted DBMS, or to standard SQL. Or write and maintain your DDL scripts by hand. Vendor specific tools usually don't do this.
Use the existing SQL abstraction layer that comes with your language/toolkit/environment, or implement one with an eye on portability (which reinvents the wheel another time).
Keep the logic in your application; the DB is for data only. Avoid triggers, stored procedures etc.
Generally apply the KISS principle to your data storage.
You may get more help on specific questions about general/abstract issues (not the implementation details, which belong here) over at Programmers.

MySQL -- What language to use for DBA automation? (Perl, Python...?)

I've inherited an existing MySQL (5.x) instance and there's been little to no maintenance of the system
My question as a MSSQL DBA is -- What tools are most commonly used to automate administrative tasks when scripting/automation MySQL tasks?
For my MSSQL servers I mainly use native T-SQL, PowerShell or C# to create my automation processes. T-SQL and Powershell are the most common as they are 'native' to the system and do not create dependencies by having to maintain additional software; C# brings .NET version dependencies (sortof)....
I see that Python is quite popular as well as Perl, however my Perl knowledge is 'nil and Python looks fairly easy for what my requirements are. Are there any good reasons to use one or another language for writing automation scripts/processes?
Before scripting anything against mysql, you should leverage the mysql client utilities. That way, you do not find yourself reinventing the wheel.
As long as you have a good mastery over the mysql client utilities, whichever langauge you decide to program in for custom utilities is simply a matter of personal choice.
IMHO from a DBA perspective, it is best to perform basic shell scripting to call SQL scripts. Again, just a matter of personal choice.
Generally, whatever you're familiar with. Our shop works in PHP, so our MySQL automation scripts are in PHP as well.

How to use different providers for Linq to entities?

I'm trying to familiarize myself a bit more with database programming, and I'm looking at different ways of creating a data access layer for applications. I've tried out a few ways but there is such a jungle of different database technologies that I don't know what to learn. For instance I've tried using datasets with tableadapters. Using that I am able to switch data provider rather easily (by programming against the interfaces such as IDbConnection). This is one thing I would want to achieve. But I also know everyone's talking about LINQ, and I'm trying to get to know that a bit better too. So I have tried using Linq to Sql classes as the data access layer as well, but apparently this is not provider independent (works only for SQL Server).
So then I read about the Entity Framework (which just as Linq to SQL apparently has gotten its share of bashing already...). It's supposed to be provider independent everybody says, but how? I tried out a tutorial to create an entity data model, but the only providers to choose from were SQL Server/Express. Just for learning purposes, I would like to know how to use the entity framework with MS Access/OleDb.
Also, I would appreciate some input on what is the preferred database technology for data access. Is it LINQ still after all the bashing, or should you just use datasets because they are provider independent? Any pointers for what to learn would be great, because it's just too much to learn it all if I'm not going to use it in the end...!
the only providers to choose from were SQL Server/Express
The .NET Framework only includes EF providers for SQL Server and SQL Server Compact. If you need to access another DBMS, you need to install a third-party provider. For instance, there's a free provider for SQLite, with designer support. There are also a few (commercial) providers made by Devart, for various DBMS. As far as I know, there are no EF providers for OleDB or ODBC...
I really like the metaphor from Scott Hanselman: "I'm not a plumber, but I do know what an S-Bend is."
Personally, I think you should have a working knowledge of all the variety of ways to access data.
ADO.Net, EF, Linq2Sql, txt files, xml etc etc etc.
Have a look at the Nerd Dinner and the Music Store samples. See the way they access data (how do they do Unit Tests, Mocking framework, IOC etc)
Regarding data providers, personally I would avoid Access. It is just as easy to get a Sql Express or Mysql installation running and looks better on your resume.
(For what its worth, this question discusses setting up mysql for EF.)