Category "mysql"

How to Connect to MySQL datbase using Swift-Nio

I used node js to connect mysql server and it is working good. I used the API developed in node js and used in the local macOS app. The problem is querying the

How to Laravel Mysql fetch data from database using multiple table join

This is my data retrieving query: $admin_students=DB::select("select students.*,application_record.*,gender_record.*, application_record.id as app_primary_id,ap

I want to build a login form that allows users to access the welcome page using only their passwords

I want to build a login form : users access the welcome page using their passwords.

Laravel weird issue: query return data with DB::table() but not with model::

I found an issue when delete some data, so I isolated the code Route::get('v1/testapi', function (Request $request) { return [ DB::table('attendances')->

Laravel weird issue: query return data with DB::table() but not with model::

I found an issue when delete some data, so I isolated the code Route::get('v1/testapi', function (Request $request) { return [ DB::table('attendances')->

How show mysql query without NULL?

How show mysql query without NULL? I want to show my quary where "LAG(title) OVER(PARTITION BY emp_no)" IS NOT NULL, I need only titles.emp_no = "LAG(title) OV

I'm working at laravel project but there is always that error : ErrorException Creating default object from empty value

this is my candidatController.php the error is in the line before the last line($prev_canditure->etat="archifé";) $candidat_nw=Candidat::orderby('crea

I'm working at laravel project but there is always that error : ErrorException Creating default object from empty value

this is my candidatController.php the error is in the line before the last line($prev_canditure->etat="archifé";) $candidat_nw=Candidat::orderby('crea

MySQL OperationalError when deleting from DataJoint table after restricting with its part table: "You can't specify target table : 'part_table'"

Using DataJoint Python (0.12.9) on Ubuntu with MySQL 5.7 . Am running into an error with what I believed to be a fairly standard operation. Have a table named T

MySQL OperationalError when deleting from DataJoint table after restricting with its part table: "You can't specify target table : 'part_table'"

Using DataJoint Python (0.12.9) on Ubuntu with MySQL 5.7 . Am running into an error with what I believed to be a fairly standard operation. Have a table named T

SQL (MySQL etc), what is the difference about length string (1-256) and (0-256)?

Thanks for reading my post. I wanna know, what is the difference between length (1-256) and (0-256) in sql and how to store them in database?. I was asked to de

How to execute SQL query for selection of info from more than 1 table

I wanted to select values from one table according to another table I have a booking system with 'user' information table and 'appointment table', they have col

MariaDB losing data when importing CSV

I'm trying to import a CSV file into MariaDB. I've created the table with "varchar(300)" for each field, so it's not missing space. Also, when I loaded the file

How to pass all user's data when clicking edit button?

I created a display page using php where all users records are displayed in a table and there are delete and edit buttons to manage users, for the delete option

Display Data from MYSQL using PHP Dropdown

I need to display data from the 'Members' table based on the selected 'grad_date' from a drop down. I have been trying to do it for a while now but have struggl

How to use PHP natsort to sort out mysql records

I have been trying to sort out my mysql records with mysql queries but seems like its just impossible to do it in the natural order. I have values such as a1, a

Flutter http post request to a PHP file

I am using Flutter for mobile app development. I need to make a POST request to a PHP file in order to save data in my MySQL server. However, I check the reques

How do I write SQL query for average?

I have recently attended an interview on SQL. Below is the question: Write a query to retrieve city name, state name, city population and return the following c

How can I Delete an Item from a Data Grid View and Reflect the Deletion in the MySql Database

UPDATE There has been quite a few changes in the code, but the problem still persists. I was able to delete from the customer table (and the entire row on the D

node js saving all values as 0 in sql

Im making an API on nodejs with express and mysql. In the POST method i dont get any error but on mysql store al values as 0, like this: 1 0 0.00 0000-00-00 0