Connecting to Access database through HTML on PC - html

So I'm trying to figure out how to connect to an access database that is on my desktop through html. Everything I've found so far involves the DB being server side and people mentioning ASP.net or just using SQL or mySQL instead. I just need to know how to get the connection up and running. Any help would be appreciated.

You need some kind of web programming language. That can be PHP or ASP.NET or Java or whatever, but you need something else -- HTML can't connect to a database on its own.
I'd highly advise that you take this opportunity to switch to another database server (like SQL Server or MySQL, like you mentioned). Microsoft Access is not well suited to use in web applications.

You're just going to get the same answers here. If you want to stay with Access, ASP.Net is the way to go. Access isn't webbased, most other databases are, so it's a bad fit.
If you want a professional solution, you could get yourself a Sharepoint server and put an Access WebApp on there. But note that this is intended for larger businesses, and priced accordingly, and your database will be limited in features (no VBA for example).

You cannot read or modify files from your (or anyone else) computer with frontend/html/javascript. Yes, you need some backend to connect to your database on your computer/server.
There are databases that work on client side/frontend, like IndexedDB, but it's not ms access and I don't think it's what you want.

Related

How can I connect my react native app to MySQL server?

I'm creating a mobile app for an existing website and trying to connect to a local instance I have running on a MySQL workbench. I've seen others recommend against the use of MySQL but I'm stuck with it, since that's the current database. I'm using expo to run my React Native code. Do I need to use a server, like "MAMP?"
Let me know if there is any more info that is needed.
You cannot connect your app directly to your database.
You will need a server/API that acts as an intermediate between the app and the DB. You can code it in most programming languages and if you know PHP, having MAMP on your system will allow you to build your API with PHP.
I've seen others recommend against the use of mySQL
You should definitely question their reasoning. I've been using MySQL for many years now in small and big projects and it has never been an issue. If they're comparing it to non-relational DBs like Mongo, I can understand, it's easier to setup and maintain a NoSQL database than a relational one.
I assume you're not that experienced but I still purposefully used some terms that may be new to a beginner. Since I don't know your skills, I will refrain from pointing you to specific tutorials/articles.
I recommend you to Google anything you don't understand from this answer.

How to link Microsoft Access Database file with HTML

I created a table in Microsoft Access Database and I wanted to use this database in the website I built with HTML. The problem is that I don't know how to link the database file to my website (or to the form inside the body of the HTML file, I actually don't even know how it works...). Can you help me?
Honestly i don't know much about Microsoft Access Database . I assume it is like other databases.
But, if you would like information that you made within a database to be shown in html, it will take much more than just html. There are a few paths you can take depending on what you want to accomplish.
The first thing is that your Database (hereby named "DB") needs to be accessible online (where your web page would live). Unless Microsoft Access Database is a "Cloud based" DB.
I use Microsoft Sql Server Management Studio (MSSM) for by DB needs, but MongoDB is a cloud based solution.
With MSSM you can use Amazon Web Services to create a webserver that runs MSSM and is accessible via the cloud.
The second thing to do would be to be able to get information from your DB to your webpage. There may be an easier solution, which I will recommend. I use C# to do this, but I know it can also be done with Ruby, and NodeJS. Within either of those languages, you will need an Object Relational Mapper (ORM), to read the info from your DB and then Create,Read,Update or Delete (CRUD) to and from your DB. An example of an ORM is EntityFrameWork or Nhibernate.
But there is a different way. If you are ok with not using a DB, you can use XML or JSON files much the same way as a DB. Which is what I did.
My github repo
Check out my non-db solution
The short version is that all of your info in your DB can be represented using .JSON files.You can then use Javascript (or Jquery) to view and display (not update) the info.
if you need help with this, leave a way to contact you, it is too much to put here.
How you do this will depend on your web development tools.
And it also depends on your web hosting company.
Remember, a web server is just a computer. It not really much different of a computer then your desktop.
And on your desktop, if you want to use say word, then you need word installed.
And on your web server, if you want to write code say in python, or asp.net, then your web site computer has to support that type of programming language.
So a web site that connects to a database will mean that you have to write some code in the web programming system of your choice. (However, that choice is limited to the tools available on that web site just like if word or say FoxPro, or Access is installed on your desktop computer.
So quite a few web hosting companies do support using an Access database. Note that this is ONLY the data part they support (so just the tables, not VBA code or forms/reports).
So, you have to either:
Pick some web programming languages you like or are familiar with, and then
Choose a web hosting provider that supports the programming language(s) you want or like to use.
Or, check your current web hosting provider and learn the tools and programming language(s) that they currently support.
For example, a really common development stack (set of tools) is called LAMP.
Lamp = Linux, Apache, MySQL, PHP.
So, if they support LAMP, then the server is a Linux server, the web server system is Apache, and the database is MySQL, and the programming language is PHP.
Keep in mind that Access does not work on the LAMP stack. (It is not a windows server, and just like you can’t install Access on an Apple Mac, you can’t install the Access data drivers on a LAMP server.
However, in most cases you don’t really care, because your code going to be the same if you pull table data from SQL server, MySQL server, or a Access database. In all 3 cases, you going to write some SQL queries against that database (to be fair, the SQL flavors do vary a bit. So Access SQL is mostly the same as SQL server, but there are minor differences). Since your code can ONLY use the tables, then you tend to not care much if the tables are in Access or MySQL. Your SQL queries you write will be VERY similar no matter what database you use to hold the tables.
If your web hosting provider supports and uses asp.net, then that web server is a Microsoft server. These are the ones that support using Access databases. And asp.net programming languages can be c# or vb.net. VB.net is nice, since it reads and you can code very much like VBA code (the syntax is very similar). And web pages (web forms) have event models somewhat similar to what you use on the Access desktop.
So, HTML alone is not sufficient for writing code. HTML can lay out some text on a web page, but it does not allow you to write code with SQL and loops and everything you come to expect with a programming language like we have say in Access (VBA).
So what kind of web server is hosting your web pages will determine what programming languages are installed and can be used on the web computer.
Apache is a common web server. That web server can dish out HTML pages, but ALSO allow you to write code for the web page. It is the coding part that allows you to execute SQL against the database to return data, and shove it into the HTML page that you have created.
If you using an IBM server, then the web server is WebSphere.
And if you using ASP.net, then the web server is IIS (internet information services).
So there is “many” different kinds of web servers. While any of these web servers (the server that dishes out web pages to users) allow HTML, they all use different programming languages.
Also, because the database used (Access, MySQL, SQL server etc.) only holds the tables, so at the end of the day, it tends to not be a big deal if you use Access to hold some tables, or say using MySQL database to hold the tables.
However, say if you have experience with SQL server from Microsoft, and are comfortable with that system, then it makes sense to choose a web server (hosting provider) that supports SQL server, since you will be familiar with that database server more than say using MySQL or Oracle databases.
So, how you get your data into the HTML page will depend on what web programming language your web hosting provider supports.
So you either choose the tools your current web hosting provider supports, or you pick the web programming tools and languages you like, and find a web hosting provider that supports those programming languages.
So this is not different then say choosing Access. If you choose and like Access, then you can’t run your software on an Apple Mac.
And of course if you use some Mac programming language, then you can’t run that software on windows.
So, how this works is exactly the same for when you choose a web server. That web server will run windows software, or say often Linux software. So you have use and write code that the given web hosting system you are using supports.
A web server is just a computer with software installed. If you want to write some code to pull the data, then you write that code in some programming language that is installed and supporting on the web server system you are using.
So, web sites that dish out data are NOT just HTML but also will have code written to send SQL to the database, and pull that data into the web page. What programing you choose is quite much like what kind of ice cream you like. (You have lots of choices here).
So web hosting systems support HTML, but EVEN what features of HTML are supported will vary from hosting provider to provider.

Connecting visual c++ to an online database

I am working on an app in visual c++ which requires data to be accessed from a database which can be edited so that every time there is a modification to the data I do not have to resend the app as it will automatically update, it is also required that this is a desktop app.
I am currently using MySql however for this to run constantly I will be needing a server which for a single simple app wont really be worth purchasing, so I started thinking of alternative methods and thought to myself there must be some method of reading directly from a website or online database, am I correct in thinking this? If so could someone please explain how I would achieve this?
Also, I have purchased phpmyadmin in the past so if there is any way I could connect my visual c++ app to a database from this then that would be great.
EDIT: Note, this app relies almost entirely on the database as it is just 3 combo box's and one text field all of that values for which come from the database.
The following response is assuming that by online you mean on the web.
You cannot exactly 'connect' to an online database with C++ (or anything outside of that server hosting the database).
What I would do is create some PHP API's that you can POST to with libcurl via C++. You can both send and receive data this way.

Best Database for Windows Server 2008 R2 with SQL 2005

I'm writing the entire database system for a factory, this includes inventory, payroll, incoming and outgoing shipments, job-data, customers, etc. The database will be stored offsite on a server running Windows 2008 R2 with SQL 2005. The guy who runs the server sent me this too:
"We also have quickbooks installed on the server and we have Exchange 2010 running. The terminal server is also ws 2008 R2.
There is plenty of horsepower on the primary exchange/file server. Let me know if you have any other questions.".
I know my boss uses Quickbooks to look at reports and stuff like that. I'm not sure how relevant exchange 2010 is, nor what the significance of "terminal server is also ws 2008 r2" is. My boss wants me to write the entire system in ms access 2010, but I feel like this will be a lot more work than simply writing it in MySQL. Will my boss still be able to look at his reports in quickbooks if we change the database to MySQL? What would be a good database technology to use? I feel the most comfortable writing it in a scripting language using MySQL, but would still be happy if I could write it in something like C/C++. I've been trying to learn access, and it seems that setting up a front-end and back-end database in access would be a pain in the ass. There are going to be several sectors in the factory that will be using the client-side software to run queries and insertions into the database(I think around 5-6).
If I can write this thing in MySQL, I think I could do the whole thing fairly pain free, but I fear that I can't because it will be incompatible with Quickbooks and the previous database(Although I hear converting is fairly easy). Mostly just Quickbook compatibility is my problem.
How horrible would it be to write this thing in Ruby?
Thank you, any help is greatly appreciated.
I don't mean to be a spoil sport but there is a tremendous amount of naivety expressed in this question. It's hard to imagine that you will be successful in designing and implementing such a large system without a basic knowledge of the technologies involved.
A few thoughts:
Quickbooks already covers most of the features you say you will be responsible for implementing. Are you supplementing the existing Quickbooks system, replacing it, or what?
Quickbooks uses its own (extraordinarily slow) database engine. It isn't "compatible" with SQL Server, MySQL, or Access.
SQL Server 2005 is a database. You don't use a database with it, you use it as your database. A Microsoft-centric organization such as the one you describe is not likely to be interested in installing yet another database server like MySQL.
MS Access encompasses both a database "engine" (called JET) and a desktop development environment. The engine can be used with other development environments and the development environment can attach to other database engines (most often SQL Server, but others work too). When you say the boss wants to write the system in MS Access you need to be clear whether he means the engine, the development environment or both. (My guess is they want to use Access as the front-end development platform and SQL Server as the data store).
You will not write a system of this complexity in a month. You probably won't even design it in that time.
Quickbooks can use MySQL as a datasource (or just about anything else), but you'll need to make your database conform to the Quickbooks way of doing things: i.e., your tables will need to match the QB table structures. It sounds like you just need a front end (data entry forms and reports) and a custom back-end. Access can quickly turn into a nightmare if you don't put in some up-front design thought, but it does give you forms & reports & web pages free in a neat little package. Make sure you use an Access Data Project (adp) that's connected to a SQL Server back end. Access does have its own native database, but everything gets stored in one local file and it's not good for applications that will be accessed by multiple people in multiple locations. It also gets complicated when you need to make a change and roll it out to all of your users.
Another option is to look into a customizable web platform, like SalesForce or MS Dynamics. That will also let you create your own tables, forms, and reports, and updates are immediate for all users, but you'll have ongoing monthly user fees. They look great on a resume, though!

creating a basic database

Right now, in my internship, I'm assigned to create a system that holds employee information such as personal info, education, salary, etc.
All these stuff is kept in a few spreadsheets right now. I need a basic program, but I feel like I should be using MySQL or another database solution to hold the data. I used MySQL before, but it was a PHP/MySQL assignment which I used Wampserver to create the whole system.
Edit: The system will be used by a few computers across the network. When someone makes a change to the system, it will become visible to other computers aswell. (obviously) (Before the edit, I thought that it's gonna be used by a single computer.)
I'm confused right now. Should I create a PHP/MySQL webpage with wampserver (or similar) to hold the information, or not?
Would it be easier or better to combine MySQL with some other programming language (such as Java/C++) and build a GUI? (I doubt it)
Should I come up with a different solution? Without database usage?
Database usage would be the best option. In the end it will come down to what you are more comfortable using, Java/C++ or php, for what you want to do either can work, but remember the database will need to be live at all times and using wamp server wont cut it. You need to learn how to tun a mysql server without wamp, which is easy(Google is awesome). And personally I would have used Java because Java is also easy to link with mysql, just google it a bit, and java doesn't need to run on a server so no wamp needed as you would have needed for php.
EDIT:
Ok if I understand you correctly what you want to do is the following:
1. Identify a pc to be used as a server and assign it a static IP.
2. This must also be the pc that is turned on first every day and turned of last.
3. Create a front end client application that connects to your sql server that you will be running on the server machine.
Now I am assuming this network is rather small, so you wont need a specific computer to just act as server. The server can also be one of the client machines.
The best approach would be to create a mysql server and make sure the firewall is not blocking your sql server. Then create a client application that can access the database over the network using Java, I find this easier than creating a php server for the users because of port forwarding for an apache server is time consuming, I did it once and never again. Java will be easiest to make the application work over the network. Use Netbeans for the development, it's an awesome IDE and it makes life easier when setting up the database connection.
If you have anymore questions please ask in comment, and I will elaborate, since this might be a bit vague lol.
Of course you should use a database for this type of work. That is the best way to organize, search, sort and filter your data without having to reinvent the wheel.
As to the other questions, the choice of language and environment is up to you to decide after evaluating the needs of your application.
Your solution should use a database to store the data and an front-end application to manage the data.
The database and front-end should be seen as two separate layers. In other words create the database using whatever database your are familiar with eg: MySQL and likewise create the front-end using whatever technology youre familiar with eg: PHP.
Personally for this type of requirement i would typically use MySQL / SQLExpress and ASP.Net / MVC3 front-end.
Hope this is helpful.