Hello, I'd very appreciate any examples (links) which can help learning how to create modifiable data bases in MASM. Thanks Iczelion for your wonderful MASM site! Regards, Ol
Read my ODBC tutorial. You can create any database which supports ODBC via SQL.
Thank you Iczelion, your ODBC tutorials are great as always. However lots of questions remain. Are you going to elaborate the example further? I'd like to learn how to change database (make additional column, change format of the column, change data in lines, and so on...) and SAVE database. It seems that implementing this technique it's a must having MS Access installed and the size of "*.mdb" file is very large while containing very little useful info, and in this case all advantages of Assembler look unconvincing. Maybe there are some other ways dealing with databases for Assembler particularly, but anyway any examples are very appreciated. Thanks, Ol
You don't have to use Access database at all. You can use ANY kind of database you have ODBC driver for. For example, I can code a prog that connects to Microsoft SQL Server and does anything that any high-level language can do. To modify the structure of a database, you need to study SQL more. For example, if you want to modify a table, use "ALTER". For table deletion, use "DROP TABLE". The mechanics in issuing those "commands" remain the same: only the "commands" change.
I would highly recommend you look in to OLE DB instead of ODBC if you are developing a database app for many users that way you don't have to physically go to each machine and setup the ODBC string and values. Also I read somewhere that ODBC is a little slower then OLE DB. You may not notice it on small databases but on database with > 50,000 records you will definently see a problem. Maybe this is not true but something you should keep in mind. If you want to make your application connect to a MySQL server (sitting on Linux, xBSD, etc.) I would suggest you check out the LIBMYSQL.DLL since that bypasses ODBC and gives you the raw functions needed to do what you want. The source code to LIBMYSQL.DLL is availible too as well as some nice examples written in Delphi. One thing to remember is that if you use LIBMYSQL.DLL as opposed to ODBC you will have to include winsock in your program. If you want to go the Microsoft path and you have MS SQL Server you might want to check out the FreeTDS http://www.freetds.org project. That library will connect to MS SQL Server or Sybase SQL server by using the TDS (Tabular Data Stream) protocol. I have been trying to port the code over to Windows since it is mostly Linux code but I have been unsuccessful. Also if you have Microsoft Office 2000 Professional or Office 2000 VB Developer then you can use a scaled down version of MS SQL Server called MS Data Engine. Its availible in the SQL\BIN directory of your Office 2000 cd. It is not on Office 2000 SBE or Personal editions. Good Luck! Devin