Questions tagged [mariadb]

MariaDB: Empowering Databases with its Open Source Database Server, Seamlessly Replacing MySQL.

In Sequelize, the "afterBulkCreate" hook consistently provides the most recent values in the _previousDataValues, particularly when utilizing updateOnDuplicate to modify specific columns

Table.addHook('afterBulkCreate' , async (params , options) => { console.log("Table.afterBulkCreate ~ params:", params , options) }) const st1 = await Table.bulkCreate(params, { updateOnDuplicate: ["metrics", ...

Having trouble connecting through PDO, but no issues when using the command line

UPDATE: I tried connecting to the command line using the following command mysql -u root -proot -h 127.0.0.1, but it didn't work. However, connecting without the -h option worked fine. This suggests there might be an issue with the MariaDB configuration. I ...

The results of executing DB::select function can vary from running a raw query directly in phpMyAdmin

I am facing an issue with my MariaDB query in Laravel as it is only returning 4 columns instead of the expected 7. Surprisingly, when I run the same query in PhpMyAdmin SQL editor, all 7 columns are returned correctly. I'm curious about why Laravel might ...

What seems to be the issue with installing @mikro-orm/mariadb?

Seeking assistance with installing mikroorm into adminjs. I followed the instructions provided at After executing the command npm install @mikro-orm/mariadb as per the guide, I encountered the following error message: npm ERR! @mikro-orm/mariadb@" ...

SQL Exception: The value for the first parameter is not defined

I'm encountering an issue with a SqlError while trying to retrieve data from my database. It seems like the problem is within my fetchData function where I might not be passing the two parameters (startDate and endDate) correctly. The specific SqlErr ...

Combining JSON data within a MySQL column efficiently with the power of SQLAlchemy

Is there a way to consolidate JSON data that is spread out over multiple rows in a MySQL column using the Python SQLAlchemy library? I tried using json_merge_preserve but encountered difficulties applying it to an entire column. This was the code snippet ...

Using LARAVEL to connect to mariaDB and SQL Server databases with DBF tables

I have just discovered a method to connect FoxPro tables with MariaDB Server by utilizing ENGINE=CONNECT. By using MySQL WorkBench, I am able to perform insertions, updates, and deletions on existing DBF tables. After following the instructions in the tu ...

Utilizing Laravel 5.6's Eloquent ORM for table joins

As I work with Eloquent ORM collections and query builders, I am currently exploring how to perform joins and apply "where" conditions within a collection similar to the query builder. Let's consider the tables: Users: ID | Name | Last name -------- ...

Failed to bind MariaDB with Node.js using Docker Compose

I have successfully set up a MariaDB/NodeJS environment using docker-compose: version: '3' services: app: image: node:alpine volumes: - ./:/app working_dir: /app environment: NODE_ENV: development ...

Using Moment.js to showcase historical information within a specified timeframe based on the user's timezone

I'm finding it challenging to properly handle historical data display: Current Situation: The database contains records stored in "YYYY-MM-DD HH:mm:ss" format in UTC+0 (MariaDB - DateTime type) A web application (using moment.js) allows users to select ...

Using Python to Determine MariaDB Connection Status

Is there a method in the MariaDB connector for Python that checks the connection state, similar to is_connected in python-mysql? Or is there another way to determine the connection status? ...

Combine table with JSON column

Is it possible to join my JSON column with the user table in MariaDB using a query? https://i.stack.imgur.com/RcvwY.png https://i.stack.imgur.com/Jfprq.png https://i.stack.imgur.com/MXGPw.png ...

Exploring the Integration of MariaDB JSON Features with Laravel Framework

As I attempt to establish a JSON database within XAMP, utilizing phpMyAdmin reveals that I am using MariaDB. However, in my xamp-control panel v3.2.2, it indicates that MySQL is running on port 3306. My endeavor involves Laravel 5.4 framework for the datab ...

trouble with maintaining nodejs mariadb connection

Hello, I am working with nodejs to create a rest API However, I have encountered an issue Let's take a look at the code var http = require('http'); var url = require('url'); var mariadb = require('mariadb'); http.c ...

Update information for a single user with the use of NodeJS, ExpressJS, and MySQL

I attempted to develop a form that would allow users to modify their name and password, but I encountered a syntax error. Below, you can find my code along with the error message that was generated. // The usage of multiple '?' is causing issues, resultin ...

Ensuring TypeORM constraint validations work seamlessly with MySQL and MariaDB

I recently started using TypeORM and I'm trying to incorporate the check decorator in my MySQL/MariaDB database. However, after doing some research on the documentation and online, it seems that the check decorator is not supported for MySQL. I've hit a ro ...

What are the best practices for transferring stored procedures between databases?

I have been given the task of migrating a website from an old client server to a new one. I managed to do a sqldump from the old server and successfully imported it into the new server. However, I am encountering some issues with sql calls made in php usin ...

Tips for properly implementing a bcrypt comparison within a promise?

Previously, my code was functioning correctly. However, it now seems to be broken for some unknown reason. I am using MariaDB as my database and attempting to compare passwords. Unfortunately, I keep encountering an error that says "Unexpected Identifier o ...

Updating MariaDB records with JSON nested arrays using PHP's On Duplicate Key Update feature

Here's an interesting challenge I'm facing. I am currently in the process of integrating a third-party POS system into a custom inventory management software that I created for a client some time ago. The system I built uses PHP, HTML, and JavaSc ...

MariaDB encountered an issue while attempting to execute the query

Hey everyone, I'm currently working on updating the product table in my database. To make the update, users must enter the ID of the product. Here's the form: <form id="myform" method="post" action="update.php"> <table class="userinf"> ...