Video was so simple. This is my first introduction to REMOTE databases. I was able to follow along. You even made sure to sneak in and mention how to connect to the database using code(java), and how to connect to it using a client. You have your motives, to target separate audiences at a time(developers, beginners, hobbyists etc)
How to open database from link ? Beacuse i was created a form and conecting to this data base. But how i open tha form link? Like when I use xampp i use the localhost/foldername/filename. But how i can open my php file ?
How can i connect my java program to this database? What should i write in my maven dependency and what should i write in Class.forName for this ? Please reply , Urgent help needed.
Hi Sarvesh This is a test db with minimal features, space and speed, It may not work very smoothly, but still if you want to try for testing purpose, here is some Java code to connect to a SQL database: ```java import java.sql.*; public class SQLDatabaseConnection { public static void main(String[] args) throws SQLException { // Load the JDBC driver try { Class.forName("com.mysql.jdbc.Driver"); } catch (ClassNotFoundException e) { System.out.println("Error loading JDBC driver: " + e.getMessage()); return; } // Create a connection to the database String url = "jdbc:mysql://localhost:3306/mydatabase"; String username = "root"; String password = "password"; Connection connection = DriverManager.getConnection(url, username, password); // Do something with the connection Statement statement = connection.createStatement(); ResultSet resultSet = statement.executeQuery("SELECT * FROM users"); while (resultSet.next()) { System.out.println(resultSet.getString("username")); } // Close the connection connection.close(); } } ``` This code will connect to a MySQL database on the local machine. The username and password are hardcoded, but you can replace them with your own credentials. The `Class.forName()` method loads the JDBC driver for MySQL. The `DriverManager.getConnection()` method creates a connection to the database. The `Statement.executeQuery()` method executes a SQL query and returns a `ResultSet` object. The `ResultSet.next()` method advances the `ResultSet` object to the next row. The `ResultSet.getString()` method returns the value of a column in the current row. Once you have finished working with the database, you should close the connection using the `Connection.close()` method. I hope this helps
When deploying "Port scan timeout reached, failed to detect open port 3306 from PORT environment variable. Bind your service to port 3306 or update the PORT environment variable to the correct port", this error is shown. How to tackle this ? Help needed.
Pratham The error message indicates that the port scan timeout has been reached, and the system failed to detect an open port 3306 from the PORT environment variable. This is likely because your service is not bound to port 3306, which is the default port for MySQL. To tackle this issue, you have two options: Option 1: Bind your service to port 3306 You need to ensure that your service is listening on port 3306. This might involve updating your application's configuration or code to bind to this port. For example, if you're using a Node.js application with a MySQL connection, you might need to update your server.js file to include the following code: const mysql = require('mysql'); const db = mysql.createConnection({ host: 'your_host', user: 'your_username', password: 'your_password', database: 'your_database', port: 3306 // Make sure to specify the port here }); db.connect((err) => { if (err) { console.error('Error connecting to database:', err); return; } console.log('Connected to database'); }); Option 2: Update the PORT environment variable Alternatively, you can update the PORT environment variable to the correct port that your service is listening on. This might involve updating your environment variables or configuration files. For example, if your service is listening on port 8080, you can update the PORT environment variable to 8080. This will allow the system to detect the open port correctly. To update the PORT environment variable, you can follow these steps: Go to your FreeSQLDatabase.com dashboard and navigate to your database instance. Click on the "Environment Variables" tab. Update the PORT variable to the correct port number (e.g., 8080). Save the changes. After making these changes, try redeploying your application to see if the issue is resolved. -
Thank you for this video! Is this secure for keeping information long-term? For example, if I want to create a database to keep all the information on my personal website.
Hi Sarah, no, this is just for testing and demo purpose, do not use it for any of your primary needs, Also it is not consistent and may not be available all time
Hie Sir..Great video..i have a java project and I want to use the online data so my software can access it when i install on another pc..how do I connect it with this database..im supposed to submit it as my school project..im currently using wampserver so its only running on my pc..thank you
Connecting your Java project to an online MySQL database hosted on freesqldatabase.com involves a few steps. Let's break it down: 1. Database Setup on freesqldatabase.com: - First, create an account on [freesqldatabase.com](www.freesqldatabase.com/). - Log in and create a new database. Note down the database name, username, and password provided by the hosting service. 2. Java Code Configuration: - In your Java project, you'll need to use the MySQL JDBC driver to connect to the remote database. - Make sure you have the MySQL Connector/J library (JDBC driver) added to your project. If not, download it from [here](dev.mysql.com/downloads/connector/j/) and add it to your classpath. 3. Connecting to the Remote Database: - Replace the placeholders in the following code snippet with your actual database details: ```java import java.sql.Connection; import java.sql.DriverManager; import java.sql.SQLException; public class DatabaseConnection { public static void main(String[] args) { String url = "jdbc:mysql://sql5.freesqldatabase.com:3306/your-database-name"; // Replace with your database URL String username = "your-username"; // Replace with your database username String password = "your-password"; // Replace with your database password try { // Load the MySQL driver Class.forName("com.mysql.cj.jdbc.Driver"); // Establish the connection Connection connection = DriverManager.getConnection(url, username, password); // Now you can execute queries or perform other database operations // For example: // connection.createStatement().execute("SELECT * FROM your_table"); // Close the connection when done connection.close(); System.out.println("Connected successfully!"); } catch (ClassNotFoundException | SQLException e) { e.printStackTrace(); System.err.println("Error connecting to the database."); } } } ``` 4. Testing the Connection: - Compile and run the above Java class. If everything is set up correctly, it should connect to your remote database. - Make sure your hosting provider allows remote connections. Some providers restrict external access for security reasons. If you encounter issues, check with your hosting support. 5. Security Considerations: - Ensure that your database credentials (username and password) are kept secure. Avoid hardcoding them directly in your code; consider using environment variables or configuration files. - Use prepared statements to prevent SQL injection attacks. Remember to replace the placeholders (`your-database-name`, `your-username`, and `your-password`) with your actual database information. Good luck with your school project
Thank you for such a helping Video. Sir i have a query, basically I made a access based software and I wanna sync access database even when it's in use by exe file linked to database is it possible?
Yes, you can run PHP scripts on your local machine by setting up a web server environment like XAMPP or WAMP. Here's how you can do it: Install XAMPP (or WAMP): Download and install XAMPP (or WAMP) from the official website. These packages provide a complete web server environment that includes PHP, Apache, MySQL, and other necessary components. Start the server: Once installed, start the Apache server from the XAMPP control panel (or WAMP control panel). Create a PHP script: In the XAMPP installation directory, you will find a folder named "htdocs" (for XAMPP) or "www" (for WAMP). Place your PHP script in this folder or create a subfolder to organize your scripts. Access the PHP script: Open your web browser and type "localhost" in the address bar. If everything is set up correctly, it will display the XAMPP (or WAMP) default page. To run your PHP script, you can access it by navigating to localhost//.php in the browser. For example, if you have a script named "my_script.php" located in a folder named "scripts" inside the "htdocs" (or "www") folder, you can access it using localhost/scripts/my_script.php. By following these steps, you can run PHP scripts locally on your machine using XAMPP (or WAMP). Remember to start the server each time you want to run PHP scripts in your local web server environment.
Now I logged in correctly in Phpmyadmin but after creating tables I have to login in the admin page but I’m unable to do that may be the values of tables are not taken by the website.
Prasanth 1. Database Type: - The database provided by FreeSQLDatabase.com is MySQL-based. Therefore, you'll need the MySQL ODBC driver to connect to it. 2. Driver and Connection String: - To connect to your FreeSQLDatabase.com database using Classic ASP, you can use the following connection string: ```asp set conn=Server.CreateObject("ADODB.Connection") conn.Open "Driver={MySQL ODBC 5.2 UNICODE Driver};Server=sql3.freesqldatabase.com;Database=dbname;User=username;Password=password;Option=3;" ``` Replace `dbname`, `username`, and `password` with your actual database name, username, and password provided by FreeSQLDatabase.com. - Note that the version number in the driver name (`MySQL ODBC 5.2 UNICODE Driver`) should match the version you have installed on your server 3. Port Number: - Make sure to include the correct port number in your connection string if you intend to connect remotely via TCP/IP. If FreeSQLDatabase.com specifies a port number, add it to the connection string: ```asp conn.Open "Driver={MySQL ODBC 5.2 UNICODE Driver};Server=sql3.freesqldatabase.com;Database=dbname;Port=1234;User=username;Password=password;Option=3;" ``` Replace `1234` with the actual port number provided by FreeSQLDatabase.com. Remember to replace placeholders with your actual database details, and you should be able to connect successfully.
I have not tried. You should be able to. But this is just for small demo and testing purpose. Try these steps: Step 1: Install the mysql2 package Run the following command in your terminal: npm install mysql2 Step 2: Get your database credentials Log in to your freesqldatabase.com account and go to the "Databases" tab. Click on the three dots next to your database name and select "Edit". Scroll down to the "Connection Details" section and note down the following: Host Database name Username Password Step 3: Create a Node.js script to connect to your database Create a new JavaScript file (e.g., db.js) and add the following code: const mysql = require('mysql2/promise'); const dbConfig = { host: 'your_host', user: 'your_username', password: 'your_password', database: 'your_database_name', }; async function connectToDatabase() { try { const connection = await mysql.createConnection(dbConfig); console.log('Connected to database!'); return connection; } catch (error) { console.error('Error connecting to database:', error); return null; } } // Example usage: async function main() { const connection = await connectToDatabase(); if (connection) { // You can now use the connection to query your database const [rows] = await connection.execute('SELECT * FROM your_table_name'); console.log(rows); } } main(); Replace the placeholders (your_host, your_username, your_password, your_database_name, and your_table_name) with your actual database credentials and table name. Step 4: Run the script Run the script using Node.js: node db.js If everything is set up correctly, you should see a "Connected to database!" message, followed by the results of the example query -
you will need to add the MySQL JDBC driver to your project. The MySQL JDBC driver is a library that allows Java applications to connect to MySQL databases will need to check for this online
Once you setup the DB, you can use it, I did not get exactly what access do you need, can send more details. In General: Connecting your project to a MySQL database involves establishing a connection from your application code to the database server. I'll provide instructions for different programming languages and environments: 1. PHP: - If you're using PHP, you can connect to a MySQL database using either the MySQLi extension (object-oriented or procedural) or PDO (PHP Data Objects). - Here are examples for both approaches: - MySQLi (Object-Oriented): ```php ``` - MySQLi (Procedural): ```php ``` - PDO: ```php ``` 2. Node.js: - For connecting a Node.js application to a MySQL database, you'll need the mysql module. - Initialize your Node.js project, download the mysql module, and create a connection using the `createConnection()` method. - Example: ```javascript const mysql = require("mysql"); const connection = mysql.createConnection({ host: "localhost", user: "your_username", password: "your_password", database: "your_database" }); connection.connect((err) => { if (err) { console.error("Error connecting to MySQL:", err); return; } console.log("Connected to MySQL!"); }); ``` 3. Java: - In Java, you can use JDBC (Java Database Connectivity) to connect to a MySQL database. - Make sure you have the MySQL JDBC driver (Connector/J) in your project. - Example: ```java import java.sql.Connection; import java.sql.DriverManager; import java.sql.SQLException; public class Main { public static void main(String[] args) { String url = "jdbc:mysql://localhost:3306/your_database"; String username = "your_username"; String password = "your_password"; try { Connection conn = DriverManager.getConnection(url, username, password); System.out.println("Connected to MySQL!"); } catch (SQLException e) { System.err.println("Connection failed: " + e.getMessage()); } } } ``` Remember to replace `"your_username"`, `"your_password"`, and `"your_database"` with your actual database credentials. Once connected, you can execute queries and interact with your MySQL database. --
Brother is this a lifetime database? because 1 week later it shows Credential does not match. If it get changed after sometime, then how can i use it in a software like windows forms or JAVA for productions?
Thanks a lot !!! very good video. 1000 thanks ! But sir Raghav, excume me, I would like to know, how many simulteneanous connections, is posible to have ??
Hi Maria, i have not tried, you can try and check, in any case, it is a public, temp db, so it will be slow, can use it for temporary testing or demo purpose only
Im aws,for free tier we need to turn off the database after use else it might attract hidden charges,is there any such thing on this website?Can we keep our database live all the time with this website?
Nitin Yes, In AWS, If you exceed the free tier limits, you will be charged for the additional usage This Free MySQL DB can be used for demo and simple testing, I am afraid if you will be able to use for hosting websites
@@RaghavPalI made a account in freesqldatabase but after sometime it showed that my account expired and it deleted my DB. No where it was mentioned that it was only free for a fixed amount of time.
Joeshin I believe the free account remains active as long as you continue to use it. If you wish to continue using the service after your free period has expired, you can upgrade to the MySQL Full plan. Can find more info on the website www.freesqldatabase.com/
Hi Heleno There are several alternatives for free SQL databases that you can use for practice and learning purposes. Here are a few options: MySQL Community Edition - this is a free and open-source version of the popular MySQL database that you can download and use for free. PostgreSQL - this is another popular open-source database that you can download and use for free. SQLite - this is a lightweight and easy-to-use SQL database engine that you can use for small projects and learning purposes. Microsoft SQL Server Express - this is a free version of Microsoft's SQL Server database that you can use for small-scale applications. MariaDB - this is a fork of MySQL that is also free and open-source. All of these options have their own strengths and weaknesses, so it's worth doing some research to see which one is best for your particular needs.
Yes, you can use MySQL Workbench with FreeSQLDatabase Here are the steps on how to use MySQL Workbench with FreeSQLDatabase: Go to the FreeSQLDatabase website and create an account. Once you have created an account, you will be able to create a new database. When creating a new database, you will need to specify the following: Database name Username Password Once you have created a new database, you will be able to obtain the connection information for the database. Open MySQL Workbench and click on the "New Connection" button. In the "Connection Name" field, enter a name for the connection. In the "Host" field, enter the hostname of the FreeSQLDatabase server. In the "Port" field, enter the port number for the FreeSQLDatabase server. In the "Database" field, enter the name of the database that you created in step 3. In the "Username" field, enter the username that you created in step 3. In the "Password" field, enter the password that you created in step 3. Click on the "Test Connection" button to test the connection. If the connection is successful, you will see a message that says "Connection successful." Click on the "OK" button to create the connection. Once you have created the connection, you will be able to work with the database in MySQL Workbench. You can create tables, insert data, and execute queries. Here are some additional tips for using MySQL Workbench with FreeSQLDatabase: You can create multiple connections to different FreeSQLDatabase databases. You can save the connection information for each database so that you can easily connect to it in the future. You can use MySQL Workbench to manage your FreeSQLDatabase databases, such as creating and deleting databases, and managing users
What if I want my php file to work remotely too....I hosted my website but when I redirect from html page to a php one it jst downloads it to my pc. What shall I do?
hello can you help me with this erro when trying to sign in for php php_network_getaddresses: getaddrinfo failed: Name or service not known — The server is not responding (or the local server's socket is not correctly configured).
To change the name of your database on FreeSqlDatabase, follow these steps: 1. Log In to FreeSqlDatabase: - Visit the [FreeSqlDatabase website](www.freesqldatabase.com/). - Log in using your credentials. 2. Access Your Database: - Once logged in, navigate to your existing database that you want to rename. 3. Database Renaming: - Look for an option related to database management or settings. - There should be an option to rename the database. - Provide the new name you want for your database and confirm the change. 4. Save Changes: - Save your changes, and the database will now have the new name. Remember to adjust the steps based on the specific interface provided by FreeSqlDatabase. If you encounter any issues, refer to their documentation
dear Mr Raghav , when i tried to login into the phpmyadmindatabase, the following message has appears: phpMyAdmin - Error Failed to store CSRF token in session! Probably sessions are not working properly. , any help please ..thanks
Ahsan, it may be down or some backend issue. You can try other options. Here are some options for creating free MySQL databases online that you can use for testing and demo purposes: 1. DB Fiddle: An online SQL database playground where you can test, debug, and share SQL snippets. It's great for experimenting with queries 2. OneCompiler's MySQL Online Editor: Write, compile, debug, run, and test MySQL queries online using OneCompiler 3. db4free.net: Create an account for free and test your applications. It's useful for ensuring your apps work after a MySQL version update and for learning new features --
Connecting your project to a MySQL database involves establishing a connection from your application code to the database server. I'll provide instructions for different programming languages and environments: 1. PHP: - If you're using PHP, you can connect to a MySQL database using either the MySQLi extension (object-oriented or procedural) or PDO (PHP Data Objects). - Here are examples for both approaches: - MySQLi (Object-Oriented): ```php ``` - MySQLi (Procedural): ```php ``` - PDO: ```php ``` 2. Node.js: - For connecting a Node.js application to a MySQL database, you'll need the mysql module. - Initialize your Node.js project, download the mysql module, and create a connection using the `createConnection()` method. - Example: ```javascript const mysql = require("mysql"); const connection = mysql.createConnection({ host: "localhost", user: "your_username", password: "your_password", database: "your_database" }); connection.connect((err) => { if (err) { console.error("Error connecting to MySQL:", err); return; } console.log("Connected to MySQL!"); }); ``` 3. Java: - In Java, you can use JDBC (Java Database Connectivity) to connect to a MySQL database. - Make sure you have the MySQL JDBC driver (Connector/J) in your project. - Example: ```java import java.sql.Connection; import java.sql.DriverManager; import java.sql.SQLException; public class Main { public static void main(String[] args) { String url = "jdbc:mysql://localhost:3306/your_database"; String username = "your_username"; String password = "your_password"; try { Connection conn = DriverManager.getConnection(url, username, password); System.out.println("Connected to MySQL!"); } catch (SQLException e) { System.err.println("Connection failed: " + e.getMessage()); } } } ``` Remember to replace `"your_username"`, `"your_password"`, and `"your_database"` with your actual database credentials. Once connected, you can execute queries and interact with your MySQL database. --
Step 1: Understand the error message The error message `#1040 - Too many connections` indicates that the maximum number of allowed connections to the MySQL database has been reached. This is a common issue when using a free database service, as they often have limitations on the number of concurrent connections. Step 2: Check the connection limit Visit the www.freesqldatabase.com/freemysqldatabase/ website and check the documentation or FAQs to see what the maximum allowed connections are for their free plan. This will give you an idea of how many connections you're allowed to have. Step 3: Check your application's connection usage Review your PHP application's code to see how many connections it's making to the database. Are you using persistent connections or are you closing connections properly after each query? Make sure your application is not leaving connections open, which can contribute to reaching the maximum allowed connections. Step 4: Check for idle connections It's possible that there are idle connections to the database that are not being used. You can try to identify and close these idle connections. You can do this by running a query in phpMyAdmin: ```sql SHOW PROCESSLIST; ``` This will show you a list of all current connections to the database. Look for connections that have been idle for a long time and consider closing them. Step 5: Consider upgrading your plan If you're consistently reaching the maximum allowed connections, it might be time to consider upgrading to a paid plan that offers more connections or looking into alternative database services that offer more generous connection limits. -
Hi Thành The "Specified key was too long; max key length is 767 bytes" error usually occurs when you are trying to create an index or key on a column that exceeds the maximum length allowed by your database's configuration. This issue is common in MySQL when using the InnoDB storage engine. To solve this issue, you can try one of the following approaches: 1. Adjust the column length: If the column causing the issue is not required to be that long, you can reduce its length to fit within the maximum key length limit. Alter the table and modify the column length accordingly. 2. Change the database configuration: By default, MySQL uses the UTF-8 encoding for character sets, which requires more space. You can switch to a different character set like UTF8MB4, which allows longer key lengths. However, note that changing the character set might impact other aspects of your application, so it's important to test and ensure compatibility. 3. Use a different database engine: If changing the character set or column length doesn't solve the issue, you can consider using a different database engine that supports longer key lengths. For example, you can switch to MyISAM instead of InnoDB, as MyISAM has a higher limit for key length. 4. Use prefix indexes: If you need to index a long column and reducing its length is not feasible, you can create a prefix index. This index only uses the first few characters of the column for indexing, effectively reducing the key length. However, note that prefix indexes have limitations and might impact performance, so use them judiciously. Remember to backup your database before making any changes, especially if you are modifying table structures or switching database engines.
@@RaghavPal when i use this url jdbc I have "AxiosError: Unsupported protocol jdbc: at dispatchXhrRequest (localhost:3000/static/js/bundle.js:46310:14)
Hi, Yes, it is possible to link Microsoft Access to a MySQL database hosted online. To do this, you will need to set up an ODBC (Open Database Connectivity) data source for MySQL on your Windows computer, and then use Microsoft Access to connect to the data source. Here are the general steps to follow: Install the MySQL ODBC driver on your Windows computer. You can download the driver from the MySQL website. Set up a new ODBC data source for MySQL using the Windows ODBC Data Source Administrator tool. To do this, open the tool from the Control Panel, navigate to the System DSN tab, and click the "Add" button. Select the MySQL ODBC driver from the list and follow the prompts to configure the data source, providing the necessary details such as the MySQL server address, port, username, and password. In Microsoft Access, open the database that you want to link to the MySQL database. From the "External Data" tab, select "ODBC Database" to open the "Get External Data - ODBC Database" wizard. In the wizard, select the option to link to the data source by creating a linked table. In the next step of the wizard, select the ODBC data source that you created in step 2. Follow the prompts to specify the tables or views that you want to link to in the MySQL database. Once you have completed these steps, you should be able to access the MySQL data through the linked tables in your Microsoft Access database. Note that the performance of the linked tables may depend on the speed and reliability of your internet connection to the MySQL server, as well as the complexity and size of the data being accessed.
@@RaghavPalthanks so much for your kind response. Again with the above video, can I link Phpmyadmin with MS access as front end. With ODBC connector. Or are there other approach.
Hello Sir, I need your help to crack the interview.. The question is for Rest API autonation.. How to pass one variable API to another API and explain the connection between them...please help if possible i am stuck in the automation and I took Get and Put request using reqres public apis help
To connect to a database using the JDBC API, you can follow these steps: Load the JDBC driver for the database you want to connect to using the Class.forName() method. For example, if you want to connect to a MySQL database, you would load the MySQL JDBC driver using the following code: Class.forName("com.mysql.jdbc.Driver"); Establish a connection to the database using the DriverManager.getConnection() method. You need to provide the connection URL, username, and password as arguments to this method. The connection URL varies depending on the type of database you are connecting to. For example, to connect to a MySQL database, you would use a connection URL like this: java String url = "jdbc:mysql://localhost:3306/mydatabase"; String user = "myuser"; String password = "mypassword"; Connection connection = DriverManager.getConnection(url, user, password); Once you have established a connection, you can create a Statement object using the Connection.createStatement() method. This object allows you to execute SQL queries and retrieve results from the database. For example, to retrieve all records from a table called "customers", you can use the following code: Statement statement = connection.createStatement(); ResultSet resultSet = statement.executeQuery("SELECT * FROM customers"); You can then use the ResultSet object to retrieve data from the database. For example, to retrieve the value of a column called "name" from the first row of the result set, you can use the following code: resultSet.next(); String name = resultSet.getString("name"); After you have finished working with the database, you should close the ResultSet, Statement, and Connection objects in reverse order of creation using their close() methods. For example: resultSet.close(); statement.close(); connection.close(); These are the basic steps for connecting to a database using the JDBC API. There are also more advanced features available, such as prepared statements and transactions, which can help improve performance and ensure data consistency.
Hi Raghav Sir, Do we have more video on this.. Like after this If we create table in Mysql, It will be saved on AWS, can we import excel file into Mysql..??
You can try other options. Here are some options for creating free MySQL databases online that you can use for testing and demo purposes: 1. DB Fiddle: An online SQL database playground where you can test, debug, and share SQL snippets. It's great for experimenting with queries 2. OneCompiler's MySQL Online Editor: Write, compile, debug, run, and test MySQL queries online using OneCompiler 3. db4free.net: Create an account for free and test your applications. It's useful for ensuring your apps work after a MySQL version update and for learning new features --
You can try other options. Here are some options for creating free MySQL databases online that you can use for testing and demo purposes: 1. DB Fiddle: An online SQL database playground where you can test, debug, and share SQL snippets. It's great for experimenting with queries 2. OneCompiler's MySQL Online Editor: Write, compile, debug, run, and test MySQL queries online using OneCompiler 3. db4free.net: Create an account for free and test your applications. It's useful for ensuring your apps work after a MySQL version update and for learning new features --
What a coincidence. I was learning mySql tutorials today morning. It's a good luck sign. 🤘
All the best Yousuf
@@RaghavPal Thank you so much.
Nah it yt algorithm
Brother it not a coincidence but it's a Google who always watch us wither online or offline
WE GETTING A FREE DATABASE WITH THIS ONE 🔥🔥
Its just for testing or demo purposes
Video was so simple. This is my first introduction to REMOTE databases. I was able to follow along. You even made sure to sneak in and mention how to connect to the database using code(java), and how to connect to it using a client. You have your motives, to target separate audiences at a time(developers, beginners, hobbyists etc)
Glad it helped..
How to open database from link ? Beacuse i was created a form and conecting to this data base. But how i open tha form link? Like when I use xampp i use the localhost/foldername/filename. But how i can open my php file ?
Hi
Not sure on this. Will need to check online
Hello sir, can I retrieve this data from database in my python script
I have not tried this Prasad .. can check online
So after creating the server. How can I connect the server to the visual studio? Is there a video on it?
Not on that, will need to check online
Stay blessed Raghav, this knowledge is really helpful for us. A lot of thanks for your sincere efforts.
So nice of you Saba
How can i connect my java program to this database? What should i write in my maven dependency and what should i write in Class.forName for this ? Please reply , Urgent help needed.
Hi Sarvesh
This is a test db with minimal features, space and speed, It may not work very smoothly, but still if you want to try for testing purpose, here is some Java code to connect to a SQL database:
```java
import java.sql.*;
public class SQLDatabaseConnection {
public static void main(String[] args) throws SQLException {
// Load the JDBC driver
try {
Class.forName("com.mysql.jdbc.Driver");
} catch (ClassNotFoundException e) {
System.out.println("Error loading JDBC driver: " + e.getMessage());
return;
}
// Create a connection to the database
String url = "jdbc:mysql://localhost:3306/mydatabase";
String username = "root";
String password = "password";
Connection connection = DriverManager.getConnection(url, username, password);
// Do something with the connection
Statement statement = connection.createStatement();
ResultSet resultSet = statement.executeQuery("SELECT * FROM users");
while (resultSet.next()) {
System.out.println(resultSet.getString("username"));
}
// Close the connection
connection.close();
}
}
```
This code will connect to a MySQL database on the local machine. The username and password are hardcoded, but you can replace them with your own credentials.
The `Class.forName()` method loads the JDBC driver for MySQL. The `DriverManager.getConnection()` method creates a connection to the database. The `Statement.executeQuery()` method executes a SQL query and returns a `ResultSet` object. The `ResultSet.next()` method advances the `ResultSet` object to the next row. The `ResultSet.getString()` method returns the value of a column in the current row.
Once you have finished working with the database, you should close the connection using the `Connection.close()` method.
I hope this helps
Hello Raghav
Just wondering whether Playwright with Java Tutorial is already in your Pipeline.
Thanks
Yes Prashant
When deploying "Port scan timeout reached, failed to detect open port 3306 from PORT environment variable. Bind your service to port 3306 or update the PORT environment variable to the correct port", this error is shown. How to tackle this ? Help needed.
Pratham
The error message indicates that the port scan timeout has been reached, and the system failed to detect an open port 3306 from the PORT environment variable. This is likely because your service is not bound to port 3306, which is the default port for MySQL.
To tackle this issue, you have two options:
Option 1: Bind your service to port 3306
You need to ensure that your service is listening on port 3306. This might involve updating your application's configuration or code to bind to this port. For example, if you're using a Node.js application with a MySQL connection, you might need to update your server.js file to include the following code:
const mysql = require('mysql');
const db = mysql.createConnection({
host: 'your_host',
user: 'your_username',
password: 'your_password',
database: 'your_database',
port: 3306 // Make sure to specify the port here
});
db.connect((err) => {
if (err) {
console.error('Error connecting to database:', err);
return;
}
console.log('Connected to database');
});
Option 2: Update the PORT environment variable
Alternatively, you can update the PORT environment variable to the correct port that your service is listening on. This might involve updating your environment variables or configuration files.
For example, if your service is listening on port 8080, you can update the PORT environment variable to 8080. This will allow the system to detect the open port correctly.
To update the PORT environment variable, you can follow these steps:
Go to your FreeSQLDatabase.com dashboard and navigate to your database instance.
Click on the "Environment Variables" tab.
Update the PORT variable to the correct port number (e.g., 8080).
Save the changes.
After making these changes, try redeploying your application to see if the issue is resolved.
-
Sir i want to connect it with my next js project how can i do that? Could you please explain
have not tried this Aditya..will need to check its documentation
Thank you for this video! Is this secure for keeping information long-term? For example, if I want to create a database to keep all the information on my personal website.
Hi Sarah, no, this is just for testing and demo purpose, do not use it for any of your primary needs, Also it is not consistent and may not be available all time
@@RaghavPal why this website does not work?
Not sure, it may be down or not maintained now
Can we use it as a alternative for planetscale
Dev
I don't think it can be used as alternative to a paid DB with all features. It can be good for a demo or small testing purposes
Is it possible to use this in other programming language? Cause I don't use PHP
will need to check the documentation
Hie Sir..Great video..i have a java project and I want to use the online data so my software can access it when i install on another pc..how do I connect it with this database..im supposed to submit it as my school project..im currently using wampserver so its only running on my pc..thank you
Connecting your Java project to an online MySQL database hosted on freesqldatabase.com involves a few steps. Let's break it down:
1. Database Setup on freesqldatabase.com:
- First, create an account on [freesqldatabase.com](www.freesqldatabase.com/).
- Log in and create a new database. Note down the database name, username, and password provided by the hosting service.
2. Java Code Configuration:
- In your Java project, you'll need to use the MySQL JDBC driver to connect to the remote database.
- Make sure you have the MySQL Connector/J library (JDBC driver) added to your project. If not, download it from [here](dev.mysql.com/downloads/connector/j/) and add it to your classpath.
3. Connecting to the Remote Database:
- Replace the placeholders in the following code snippet with your actual database details:
```java
import java.sql.Connection;
import java.sql.DriverManager;
import java.sql.SQLException;
public class DatabaseConnection {
public static void main(String[] args) {
String url = "jdbc:mysql://sql5.freesqldatabase.com:3306/your-database-name"; // Replace with your database URL
String username = "your-username"; // Replace with your database username
String password = "your-password"; // Replace with your database password
try {
// Load the MySQL driver
Class.forName("com.mysql.cj.jdbc.Driver");
// Establish the connection
Connection connection = DriverManager.getConnection(url, username, password);
// Now you can execute queries or perform other database operations
// For example:
// connection.createStatement().execute("SELECT * FROM your_table");
// Close the connection when done
connection.close();
System.out.println("Connected successfully!");
} catch (ClassNotFoundException | SQLException e) {
e.printStackTrace();
System.err.println("Error connecting to the database.");
}
}
}
```
4. Testing the Connection:
- Compile and run the above Java class. If everything is set up correctly, it should connect to your remote database.
- Make sure your hosting provider allows remote connections. Some providers restrict external access for security reasons. If you encounter issues, check with your hosting support.
5. Security Considerations:
- Ensure that your database credentials (username and password) are kept secure. Avoid hardcoding them directly in your code; consider using environment variables or configuration files.
- Use prepared statements to prevent SQL injection attacks.
Remember to replace the placeholders (`your-database-name`, `your-username`, and `your-password`) with your actual database information.
Good luck with your school project
@@RaghavPal Thank You sir..we need more people like you🙏
Can't access my database anymore, can't add more mb to my space...
no one reply to my tickets. Please help
Matteo
pls use this only for some demo or testing purposes. don't rely on this for actual work
Thank you for such a helping Video. Sir i have a query, basically I made a access based software and I wanna sync access database even when it's in use by exe file linked to database is it possible?
Hi Lakshaya, not very sure on this, will need to take online help
Is there option to make php script or something similar, like you can do in xampp with placing php script in htdocs?
Yes, you can run PHP scripts on your local machine by setting up a web server environment like XAMPP or WAMP. Here's how you can do it:
Install XAMPP (or WAMP): Download and install XAMPP (or WAMP) from the official website. These packages provide a complete web server environment that includes PHP, Apache, MySQL, and other necessary components.
Start the server: Once installed, start the Apache server from the XAMPP control panel (or WAMP control panel).
Create a PHP script: In the XAMPP installation directory, you will find a folder named "htdocs" (for XAMPP) or "www" (for WAMP). Place your PHP script in this folder or create a subfolder to organize your scripts.
Access the PHP script: Open your web browser and type "localhost" in the address bar. If everything is set up correctly, it will display the XAMPP (or WAMP) default page. To run your PHP script, you can access it by navigating to localhost//.php in the browser.
For example, if you have a script named "my_script.php" located in a folder named "scripts" inside the "htdocs" (or "www") folder, you can access it using localhost/scripts/my_script.php.
By following these steps, you can run PHP scripts locally on your machine using XAMPP (or WAMP). Remember to start the server each time you want to run PHP scripts in your local web server environment.
When I created the account on myfreesqldatabase it’s not get login on phpmyadmin it’s showing error how I can resolve that.
Taniya
will need to check based on the error message you are getting..
Now I logged in correctly in Phpmyadmin but after creating tables I have to login in the admin page but I’m unable to do that may be the values of tables are not taken by the website.
Taniya
will need to check some online examples on this
Could you please assist me in finding the driver and driver class for this database?
Prasanth
1. Database Type:
- The database provided by FreeSQLDatabase.com is MySQL-based. Therefore, you'll need the MySQL ODBC driver to connect to it.
2. Driver and Connection String:
- To connect to your FreeSQLDatabase.com database using Classic ASP, you can use the following connection string:
```asp
set conn=Server.CreateObject("ADODB.Connection")
conn.Open "Driver={MySQL ODBC 5.2 UNICODE Driver};Server=sql3.freesqldatabase.com;Database=dbname;User=username;Password=password;Option=3;"
```
Replace `dbname`, `username`, and `password` with your actual database name, username, and password provided by FreeSQLDatabase.com.
- Note that the version number in the driver name (`MySQL ODBC 5.2 UNICODE Driver`) should match the version you have installed on your server
3. Port Number:
- Make sure to include the correct port number in your connection string if you intend to connect remotely via TCP/IP. If FreeSQLDatabase.com specifies a port number, add it to the connection string:
```asp
conn.Open "Driver={MySQL ODBC 5.2 UNICODE Driver};Server=sql3.freesqldatabase.com;Database=dbname;Port=1234;User=username;Password=password;Option=3;"
```
Replace `1234` with the actual port number provided by FreeSQLDatabase.com.
Remember to replace placeholders with your actual database details, and you should be able to connect successfully.
Thank you for such a helpful video. Can you recommend an db-client for Mac (ideally that runs natively on ARM)?
Hi Vadim, for Mac you can try
Workbench
PopSQL
It was a great Tutorial. Where to put the script? Like in XAMP we place it on htdocs
will need to check this
Can we connect this online database with nodejs?
I have not tried. You should be able to. But this is just for small demo and testing purpose. Try these steps:
Step 1: Install the mysql2 package
Run the following command in your terminal:
npm install mysql2
Step 2: Get your database credentials
Log in to your freesqldatabase.com account and go to the "Databases" tab. Click on the three dots next to your database name and select "Edit". Scroll down to the "Connection Details" section and note down the following:
Host
Database name
Username
Password
Step 3: Create a Node.js script to connect to your database
Create a new JavaScript file (e.g., db.js) and add the following code:
const mysql = require('mysql2/promise');
const dbConfig = {
host: 'your_host',
user: 'your_username',
password: 'your_password',
database: 'your_database_name',
};
async function connectToDatabase() {
try {
const connection = await mysql.createConnection(dbConfig);
console.log('Connected to database!');
return connection;
} catch (error) {
console.error('Error connecting to database:', error);
return null;
}
}
// Example usage:
async function main() {
const connection = await connectToDatabase();
if (connection) {
// You can now use the connection to query your database
const [rows] = await connection.execute('SELECT * FROM your_table_name');
console.log(rows);
}
}
main();
Replace the placeholders (your_host, your_username, your_password, your_database_name, and your_table_name) with your actual database credentials and table name.
Step 4: Run the script
Run the script using Node.js:
node db.js
If everything is set up correctly, you should see a "Connected to database!" message, followed by the results of the example query
-
@@RaghavPal thank a lot, I tried in the same way and it's work🔥
Thx for video... I need help ... already create table on phpmyadmin.. but when using heidiSQL got error .. cant get hostname for your address
will need to check with some online examples
@@RaghavPal thank you ... waiting for the good news
Hello, pls i was trying to login with my details to phpadmin but is not going. I dont know where the error is. Pls put me through
will need to check details
I can't connect it with wordpress. How to solve?
Not sure, will need to check on that
Hi sir, thank you for the tutorial. But can i know how to connect mysql in cloud with python code in local server
Hi Nur
If I get sometime, I will plan to do a session, for now you can check and try with some online examples
Does anyone knows how to connect this with java servlet? And what's the driver we need to add?
you will need to add the MySQL JDBC driver to your project. The MySQL JDBC driver is a library that allows Java applications to connect to MySQL databases
will need to check for this online
Thanks raghav for gr8 tutorial. Very easy and simple.
Most welcome Abhijit
thanks man nice video, but how do i grant access the database?
Once you setup the DB, you can use it, I did not get exactly what access do you need, can send more details. In General:
Connecting your project to a MySQL database involves establishing a connection from your application code to the database server. I'll provide instructions for different programming languages and environments:
1. PHP:
- If you're using PHP, you can connect to a MySQL database using either the MySQLi extension (object-oriented or procedural) or PDO (PHP Data Objects).
- Here are examples for both approaches:
- MySQLi (Object-Oriented):
```php
```
- MySQLi (Procedural):
```php
```
- PDO:
```php
```
2. Node.js:
- For connecting a Node.js application to a MySQL database, you'll need the mysql module.
- Initialize your Node.js project, download the mysql module, and create a connection using the `createConnection()` method.
- Example:
```javascript
const mysql = require("mysql");
const connection = mysql.createConnection({
host: "localhost",
user: "your_username",
password: "your_password",
database: "your_database"
});
connection.connect((err) => {
if (err) {
console.error("Error connecting to MySQL:", err);
return;
}
console.log("Connected to MySQL!");
});
```
3. Java:
- In Java, you can use JDBC (Java Database Connectivity) to connect to a MySQL database.
- Make sure you have the MySQL JDBC driver (Connector/J) in your project.
- Example:
```java
import java.sql.Connection;
import java.sql.DriverManager;
import java.sql.SQLException;
public class Main {
public static void main(String[] args) {
String url = "jdbc:mysql://localhost:3306/your_database";
String username = "your_username";
String password = "your_password";
try {
Connection conn = DriverManager.getConnection(url, username, password);
System.out.println("Connected to MySQL!");
} catch (SQLException e) {
System.err.println("Connection failed: " + e.getMessage());
}
}
}
```
Remember to replace `"your_username"`, `"your_password"`, and `"your_database"` with your actual database credentials. Once connected, you can execute queries and interact with your MySQL database.
--
How to conncet it with power bi please let me know
i have not tried this.. will need to check online
Great Tutorial! But i have a problem with Heidi, it tells me "Access Denied for User". How can I fix it?
will need to check, What I did is shown in the video
@@RaghavPal I followed the tutorial and it is explained easily but the pc gives me this error
ok, can try some online examples
how many users (i.e. programmers) can connect to the DB to work with it?
Hi Felix, I believe for this Free one it will be one user and in any case it will be very slow, can be used for some temporary testing purpose or demo
Brother is this a lifetime database? because 1 week later it shows Credential does not match. If it get changed after sometime, then how can i use it in a software like windows forms or JAVA for productions?
Om
Cannot rely on this as this is free demo db.. can use it just for demo or for some demo testing.
Thanks a lot !!! very good video. 1000 thanks ! But sir Raghav, excume me, I would like to know, how many simulteneanous connections, is posible to have ??
Hi Maria, i have not tried, you can try and check, in any case, it is a public, temp db, so it will be slow, can use it for temporary testing or demo purpose only
Hi Sir Raghav, thank you. I will try later. Again thanks a lot.
Im aws,for free tier we need to turn off the database after use else it might attract hidden charges,is there any such thing on this website?Can we keep our database live all the time with this website?
Nitin
Yes, In AWS, If you exceed the free tier limits, you will be charged for the additional usage
This Free MySQL DB can be used for demo and simple testing, I am afraid if you will be able to use for hosting websites
@@RaghavPalI made a account in freesqldatabase but after sometime it showed that my account expired and it deleted my DB. No where it was mentioned that it was only free for a fixed amount of time.
ok, I also recieved some comments saying that now they have made it paid
Hi may I know how long will that MySQL database account still free and available for us?
Joeshin
I believe the free account remains active as long as you continue to use it.
If you wish to continue using the service after your free period has expired, you can upgrade to the MySQL Full plan.
Can find more info on the website www.freesqldatabase.com/
can i connect this instance in mysql workbench ?
Not tried this Barath
freesqldatabase is doens't allow for login or sign up - any other alternatives?
Hi Heleno
There are several alternatives for free SQL databases that you can use for practice and learning purposes. Here are a few options:
MySQL Community Edition - this is a free and open-source version of the popular MySQL database that you can download and use for free.
PostgreSQL - this is another popular open-source database that you can download and use for free.
SQLite - this is a lightweight and easy-to-use SQL database engine that you can use for small projects and learning purposes.
Microsoft SQL Server Express - this is a free version of Microsoft's SQL Server database that you can use for small-scale applications.
MariaDB - this is a fork of MySQL that is also free and open-source.
All of these options have their own strengths and weaknesses, so it's worth doing some research to see which one is best for your particular needs.
Can I use MySQL Workbench with this?
Yes, you can use MySQL Workbench with FreeSQLDatabase
Here are the steps on how to use MySQL Workbench with FreeSQLDatabase:
Go to the FreeSQLDatabase website and create an account.
Once you have created an account, you will be able to create a new database.
When creating a new database, you will need to specify the following:
Database name
Username
Password
Once you have created a new database, you will be able to obtain the connection information for the database.
Open MySQL Workbench and click on the "New Connection" button.
In the "Connection Name" field, enter a name for the connection.
In the "Host" field, enter the hostname of the FreeSQLDatabase server.
In the "Port" field, enter the port number for the FreeSQLDatabase server.
In the "Database" field, enter the name of the database that you created in step 3.
In the "Username" field, enter the username that you created in step 3.
In the "Password" field, enter the password that you created in step 3.
Click on the "Test Connection" button to test the connection.
If the connection is successful, you will see a message that says "Connection successful."
Click on the "OK" button to create the connection.
Once you have created the connection, you will be able to work with the database in MySQL Workbench. You can create tables, insert data, and execute queries.
Here are some additional tips for using MySQL Workbench with FreeSQLDatabase:
You can create multiple connections to different FreeSQLDatabase databases.
You can save the connection information for each database so that you can easily connect to it in the future.
You can use MySQL Workbench to manage your FreeSQLDatabase databases, such as creating and deleting databases, and managing users
@@RaghavPal Thank you!
Ahh yes
great tutorial. Thanks alot sir. do you have tutorial also to migrate sql file to phpmyadmin?
Thanks Michael, I believe do not have that, Can check all my tutorials here - automationstepbystep.com/
What if I want my php file to work remotely too....I hosted my website but when I redirect from html page to a php one it jst downloads it to my pc. What shall I do?
Is it possible to use it for MySQL ?
can try it.. and can check its documentation
hello can you help me with this erro when trying to sign in for php
php_network_getaddresses: getaddrinfo failed: Name or service not known — The server is not responding (or the local server's socket is not correctly configured).
it worked thankyou
what did you do? @@BaraJepco
amazing! and how can i change my DB name ?
To change the name of your database on FreeSqlDatabase, follow these steps:
1. Log In to FreeSqlDatabase:
- Visit the [FreeSqlDatabase website](www.freesqldatabase.com/).
- Log in using your credentials.
2. Access Your Database:
- Once logged in, navigate to your existing database that you want to rename.
3. Database Renaming:
- Look for an option related to database management or settings.
- There should be an option to rename the database.
- Provide the new name you want for your database and confirm the change.
4. Save Changes:
- Save your changes, and the database will now have the new name.
Remember to adjust the steps based on the specific interface provided by FreeSqlDatabase. If you encounter any issues, refer to their documentation
really like it. So easy and simple. Thanks for this video.
Most welcome Manali
It's very helpful video for me & everyone Raghav. Thanks a lot
So nice of you
dear Mr Raghav , when i tried to login into the phpmyadmindatabase, the following message has appears:
phpMyAdmin - Error
Failed to store CSRF token in session! Probably sessions are not working properly. , any help please ..thanks
Hi Hazim, pls check this
github.com/phpmyadmin/phpmyadmin/issues/13404
Can we connect using node js?
I am not sure on this.. can check its documentation
Can it be connected to mysql workbench
Hi Ajay, Yes, can try
when i hit go it just refreshes the page
Ahsan, it may be down or some backend issue. You can try other options. Here are some options for creating free MySQL databases online that you can use for testing and demo purposes:
1. DB Fiddle: An online SQL database playground where you can test, debug, and share SQL snippets. It's great for experimenting with queries
2. OneCompiler's MySQL Online Editor: Write, compile, debug, run, and test MySQL queries online using OneCompiler
3. db4free.net: Create an account for free and test your applications. It's useful for ensuring your apps work after a MySQL version update and for learning new features
--
where did you get the url from?
its online public
can I use c++ to connect to the DB?
Not sure on this, will need to check
But how to connect with my project??
Connecting your project to a MySQL database involves establishing a connection from your application code to the database server. I'll provide instructions for different programming languages and environments:
1. PHP:
- If you're using PHP, you can connect to a MySQL database using either the MySQLi extension (object-oriented or procedural) or PDO (PHP Data Objects).
- Here are examples for both approaches:
- MySQLi (Object-Oriented):
```php
```
- MySQLi (Procedural):
```php
```
- PDO:
```php
```
2. Node.js:
- For connecting a Node.js application to a MySQL database, you'll need the mysql module.
- Initialize your Node.js project, download the mysql module, and create a connection using the `createConnection()` method.
- Example:
```javascript
const mysql = require("mysql");
const connection = mysql.createConnection({
host: "localhost",
user: "your_username",
password: "your_password",
database: "your_database"
});
connection.connect((err) => {
if (err) {
console.error("Error connecting to MySQL:", err);
return;
}
console.log("Connected to MySQL!");
});
```
3. Java:
- In Java, you can use JDBC (Java Database Connectivity) to connect to a MySQL database.
- Make sure you have the MySQL JDBC driver (Connector/J) in your project.
- Example:
```java
import java.sql.Connection;
import java.sql.DriverManager;
import java.sql.SQLException;
public class Main {
public static void main(String[] args) {
String url = "jdbc:mysql://localhost:3306/your_database";
String username = "your_username";
String password = "your_password";
try {
Connection conn = DriverManager.getConnection(url, username, password);
System.out.println("Connected to MySQL!");
} catch (SQLException e) {
System.err.println("Connection failed: " + e.getMessage());
}
}
}
```
Remember to replace `"your_username"`, `"your_password"`, and `"your_database"` with your actual database credentials. Once connected, you can execute queries and interact with your MySQL database.
--
It's really Helpful. Thanks myn❤️
Glad it was helpful Ramesh
Do u have other faster mysql hosting? Thanks sir
no, will need to check online
Does it work with django?
I have not tried
After create and try to login phpmy admin is show #1040- To many connections
Step 1: Understand the error message
The error message `#1040 - Too many connections` indicates that the maximum number of allowed connections to the MySQL database has been reached. This is a common issue when using a free database service, as they often have limitations on the number of concurrent connections.
Step 2: Check the connection limit
Visit the www.freesqldatabase.com/freemysqldatabase/ website and check the documentation or FAQs to see what the maximum allowed connections are for their free plan. This will give you an idea of how many connections you're allowed to have.
Step 3: Check your application's connection usage
Review your PHP application's code to see how many connections it's making to the database. Are you using persistent connections or are you closing connections properly after each query? Make sure your application is not leaving connections open, which can contribute to reaching the maximum allowed connections.
Step 4: Check for idle connections
It's possible that there are idle connections to the database that are not being used. You can try to identify and close these idle connections. You can do this by running a query in phpMyAdmin:
```sql
SHOW PROCESSLIST;
```
This will show you a list of all current connections to the database. Look for connections that have been idle for a long time and consider closing them.
Step 5: Consider upgrading your plan
If you're consistently reaching the maximum allowed connections, it might be time to consider upgrading to a paid plan that offers more connections or looking into alternative database services that offer more generous connection limits.
-
Where do I insert my username and password ? From your example URL their is none at 4.24
check this dev.mysql.com/doc/connector-j/8.0/en/connector-j-reference-jdbc-url-format.html
Sir how to connect our online database to our contact page please me regarding this query
Hi Shivam, do you want to use the same method as shown in the video? What is your database, will need more details
Man man man , you are a saviour ❤
Thanks for the kind words
I'm getting msg that ur account is expired what does it means ?
it may have some limits on usage or time. Pls check
@@RaghavPalthanks for ur help
How mucho space is there avalible?
For free account I believe its 5MB. It can be used only for testing or demo purposes. Can check more on their website
great video for hobbyists, many thanks sir.
You are very welcome Jebali
Thanks for this video. Was very helpful
You're welcome Anand
Great video! Is the website working in 2023, because I can't make an account?
Not sure, will need to check
#1071 - Specified key was too long; max key length is 767 bytes in sql free online how to solve it . Thanks
Hi Thành
The "Specified key was too long; max key length is 767 bytes" error usually occurs when you are trying to create an index or key on a column that exceeds the maximum length allowed by your database's configuration. This issue is common in MySQL when using the InnoDB storage engine.
To solve this issue, you can try one of the following approaches:
1. Adjust the column length: If the column causing the issue is not required to be that long, you can reduce its length to fit within the maximum key length limit. Alter the table and modify the column length accordingly.
2. Change the database configuration: By default, MySQL uses the UTF-8 encoding for character sets, which requires more space. You can switch to a different character set like UTF8MB4, which allows longer key lengths. However, note that changing the character set might impact other aspects of your application, so it's important to test and ensure compatibility.
3. Use a different database engine: If changing the character set or column length doesn't solve the issue, you can consider using a different database engine that supports longer key lengths. For example, you can switch to MyISAM instead of InnoDB, as MyISAM has a higher limit for key length.
4. Use prefix indexes: If you need to index a long column and reducing its length is not feasible, you can create a prefix index. This index only uses the first few characters of the column for indexing, effectively reducing the key length. However, note that prefix indexes have limitations and might impact performance, so use them judiciously.
Remember to backup your database before making any changes, especially if you are modifying table structures or switching database engines.
how to get data on your website from that?
its online public
@@RaghavPal when i use this url jdbc I have
"AxiosError: Unsupported protocol jdbc:
at dispatchXhrRequest (localhost:3000/static/js/bundle.js:46310:14)
awesome video and tutorial but guide one more thing how to change server ?
ok, will check this
If one wants to subscribe to freesqldatabase when you don't have PayPal can't master card be used?
Not sure, will need to check
Cant we import our sql file ?
not sure.. will need to check
is your account at freeSQLDatabase still running? my account was expired yesterday
these are temp db, just for testing and demo purpose
Hi , Please make a video on running spring boot/java application for free on remote
Sure Vikas, I will check
Can Ms access be Link to MySQL online?
Hi,
Yes, it is possible to link Microsoft Access to a MySQL database hosted online.
To do this, you will need to set up an ODBC (Open Database Connectivity) data source for MySQL on your Windows computer, and then use Microsoft Access to connect to the data source.
Here are the general steps to follow:
Install the MySQL ODBC driver on your Windows computer. You can download the driver from the MySQL website.
Set up a new ODBC data source for MySQL using the Windows ODBC Data Source Administrator tool. To do this, open the tool from the Control Panel, navigate to the System DSN tab, and click the "Add" button. Select the MySQL ODBC driver from the list and follow the prompts to configure the data source, providing the necessary details such as the MySQL server address, port, username, and password.
In Microsoft Access, open the database that you want to link to the MySQL database.
From the "External Data" tab, select "ODBC Database" to open the "Get External Data - ODBC Database" wizard.
In the wizard, select the option to link to the data source by creating a linked table.
In the next step of the wizard, select the ODBC data source that you created in step 2.
Follow the prompts to specify the tables or views that you want to link to in the MySQL database.
Once you have completed these steps, you should be able to access the MySQL data through the linked tables in your Microsoft Access database.
Note that the performance of the linked tables may depend on the speed and reliability of your internet connection to the MySQL server, as well as the complexity and size of the data being accessed.
@@RaghavPalthanks so much for your kind response.
Again with the above video, can I link Phpmyadmin with MS access as front end. With ODBC connector.
Or are there other approach.
I tried it, it work very fine, though slow. But I want annual subscription payment. I don't know how to go about it
Can I use foreign keys?
not sure on this app, can try
Did it work?
@@antoniofuller2331 just use cockroachdb (postgres)
Hello Sir,
I need your help to crack the interview..
The question is for Rest API autonation..
How to pass one variable API to another API and explain the connection between them...please help if possible i am stuck in the automation and I took Get and Put request using reqres public apis help
Hi Saurabh, what is the tool and platform you are using
@@RaghavPal ide Eclipse using java rest assured...I have created MAVEN project...
will need to check on this with some online examples
Ok sir, No worries I have completed task. thank you for your response and your videos keep motivating me. ❤️
How to connect database using JDBC API
To connect to a database using the JDBC API, you can follow these steps:
Load the JDBC driver for the database you want to connect to using the Class.forName() method. For example, if you want to connect to a MySQL database, you would load the MySQL JDBC driver using the following code:
Class.forName("com.mysql.jdbc.Driver");
Establish a connection to the database using the DriverManager.getConnection() method. You need to provide the connection URL, username, and password as arguments to this method. The connection URL varies depending on the type of database you are connecting to. For example, to connect to a MySQL database, you would use a connection URL like this:
java
String url = "jdbc:mysql://localhost:3306/mydatabase";
String user = "myuser";
String password = "mypassword";
Connection connection = DriverManager.getConnection(url, user, password);
Once you have established a connection, you can create a Statement object using the Connection.createStatement() method. This object allows you to execute SQL queries and retrieve results from the database. For example, to retrieve all records from a table called "customers", you can use the following code:
Statement statement = connection.createStatement();
ResultSet resultSet = statement.executeQuery("SELECT * FROM customers");
You can then use the ResultSet object to retrieve data from the database. For example, to retrieve the value of a column called "name" from the first row of the result set, you can use the following code:
resultSet.next();
String name = resultSet.getString("name");
After you have finished working with the database, you should close the ResultSet, Statement, and Connection objects in reverse order of creation using their close() methods. For example:
resultSet.close();
statement.close();
connection.close();
These are the basic steps for connecting to a database using the JDBC API. There are also more advanced features available, such as prepared statements and transactions, which can help improve performance and ensure data consistency.
Bro...is this not local host 🤔
ok
This is a very helpful video..thank you
Most welcome Alankrith
Great video sir thanks a lot👏
Most welcome
it giving me error while login in php admin
will need to check the details
they use old version from mysql database 5.6 and they after weeks or more will stop your accoutn becuse it will be exierd
Ok, If I get better options, will add videos on that
@@RaghavPal thanks alot
thank you, this worked for me !!
You're welcome!
How do I get the mysql server ip address for this
I do not remember exactly on this, will need to check the website
@@RaghavPal please check whenever you free and replay back
Hi Raghav Sir, Do we have more video on this.. Like after this If we create table in Mysql, It will be saved on AWS, can we import excel file into Mysql..??
for this one, this is the only video to show how to create a Free DB for testing or Demo purpose
@@RaghavPal Can we expect more in future on the same
5mb is enough ?
yes.. its only for small demo, testing purposes
unknown server host error i am getting
it may be down
website not loading from india
Not sure.. may be some backend issue.. can wait and try again
indeed really useful. Thanks Bro.
You are welcome
bro I wanna deploy mysql db in some paid server
Please help
don't have a session on that, will need to check online guide
Thanks bro found this helpful
Glad it helped
I had time to make coffee while waiting for the loading on Phpmyadmin🤣
ya its slow
Is their site down
Not sure
Suddenly they expired my account without any prior information
cannot say.. check if its for some limited time..
@@RaghavPal they haven't mentioned anything on their website. Also they are not replying on email and tickets
You can try other options. Here are some options for creating free MySQL databases online that you can use for testing and demo purposes:
1. DB Fiddle: An online SQL database playground where you can test, debug, and share SQL snippets. It's great for experimenting with queries
2. OneCompiler's MySQL Online Editor: Write, compile, debug, run, and test MySQL queries online using OneCompiler
3. db4free.net: Create an account for free and test your applications. It's useful for ensuring your apps work after a MySQL version update and for learning new features
--
You can try other options. Here are some options for creating free MySQL databases online that you can use for testing and demo purposes:
1. DB Fiddle: An online SQL database playground where you can test, debug, and share SQL snippets. It's great for experimenting with queries
2. OneCompiler's MySQL Online Editor: Write, compile, debug, run, and test MySQL queries online using OneCompiler
3. db4free.net: Create an account for free and test your applications. It's useful for ensuring your apps work after a MySQL version update and for learning new features
--
It isn't free. I could use this database in 10 day and afterthat it requires at least 16$ per year to continue.
Use it only for demo and initial test, or just to check the connections
the website non working
Ok, I will check
What a coincidence, i was looking for same a few days ago
Great to know Vikas, All the best
Thank youuuuu....❤❤❤❤❤
Most welocme
Great tutorial, thank you!
You're very welcome Alexandra
your amazing thanks you saved me
Most welcome