Discussion Forum : sql

Change date format (in DB or output) to dd/mm/yyyy - PHP MySQL
MySQL stores the date in my database (by default) as 'YYYY-MM-DD' The field type for my date is 'DATE' (I do not need an ... View Detail
 Upvotes: 0   Answers: 0
How to use php array with sql IN operator?
I have and array with two values and I want to use it with sql IN operator in select query. Here is the structure of my ... View Detail
 Upvotes: 0   Answers: 0
PHP - Import CSV file to mysql database Using LOAD DATA INFILE
I have a .csv file data like that Date,Name,Call Type,Number,Duration,Address,PostalCode,City,State,Country,Latitude,Lo ... View Detail
 Upvotes: 0   Answers: 0
Log the actual SQL query using ActiveRecord with Yii2?
I'm doing this: $students = Student::find()->all();  return $this->render('process', array('students' => $students));  ... View Detail
 Upvotes: 0   Answers: 0
How to execute raw queries with Laravel 5.1?
So I have this tiny query to run on my DB and it works fine in MySQL Workbench. Basically, a SELECT with LEFT JOIN and U ... View Detail
 Upvotes: 0   Answers: 0
MySQL INTO OUTFILE override existing file?
I've written a big sql script that creates a CSV file. I want to call a cronjob every night to create a fresh CSV file a ... View Detail
 Upvotes: 0   Answers: 0
how to generate OTP and send the password to mobile via sms
I am doing a project of using OTP for the login of the websites, I have created a button named Generate once clicked it ... View Detail
 Upvotes: 0   Answers: 0
Error: mysqlnd cannot connect to MySQL 4.1+ using the old insecure authentication
I am getting the following error: Database connection failed: mysqlnd cannot connect to MySQL 4.1+ using the old ins ... View Detail
 Upvotes: 0   Answers: 0
Select all records using MySQL LIMIT and OFFSET query
I'm looking for a way to accomplish: SELECT * FROM table  but by using LIMIT and OFFSET like so: SELECT * FROM table  ... View Detail
 Upvotes: 0   Answers: 0
SQLSTATE[HY093]: Invalid parameter number: number of bound variables does not match number of tokens on line 102
I am receiving the error of SQLSTATE[HY093]: Invalid parameter number: number of bound variables does not match number o ... View Detail
 Upvotes: 0   Answers: 0
Extract a substring between two characters in a string PHP
Is there a php function that can extract a phrase between 2 different characters in a string? Something like substr(); ... View Detail
 Upvotes: 0   Answers: 0
Check SQL database if value exists and then return value if it does
I am pretty new to both php and SQL. I have a login page where I ask for the users username and password. I would like ... View Detail
 Upvotes: 0   Answers: 0
How do I use a complex criteria inside a doctrine 2 entity's repository?
Lets say I have a table that holds information about festivals. Each festival has a start and end date. I want to selec ... View Detail
 Upvotes: 0   Answers: 0
Check if a string is an email address in PHP
I am trying to do an SQL query, but I need to check somehow if the value is an email address. I need a way to check if $ ... View Detail
 Upvotes: 0   Answers: 0
Symfony2 & Doctrine: Create custom SQL-Query
How can I create a custom SQL query in Symfony2 using Doctrine? Or without Doctrine, I don't care. Doesn't work like th ... View Detail
 Upvotes: 0   Answers: 0
how do I get month from date in mysql
I want to be able to fetch results from mysql with a statement like this: SELECT * FROM table   WHERE amount > 1000   ... View Detail
 Upvotes: 0   Answers: 0
Insert into MySQL Table PHP
I am having some trouble making a simple form to insert data into a MySQL table. I keep getting this SQL error: Erro ... View Detail
 Upvotes: 0   Answers: 0
MYSQL Select Query with SUM()
I have the following table: | campaign_id | source_id | clicked | viewed | -------------------------------------------- ... View Detail
 Upvotes: 0   Answers: 0
How do I subtract using SQL in MYSQL between two date time values and retrieve the result in minutes or second?
I want to subtract between two date time values using SQL in MySQL such that I get the interval in minutes or seconds. A ... View Detail
 Upvotes: 0   Answers: 0
Increase and decrease row value by 1 in MySQL
Hi I have a MySQL database table points the user can click a button and a point should be removed from their account, th ... View Detail
 Upvotes: 0   Answers: 0
Fatal error: Call to a member function query() on null
I'm not sure what's going wrong here. I was just following a tutorial online and these errors popped up. I'm getting th ... View Detail
 Upvotes: 0   Answers: 0
Checking if mysql_query returned anything or not
$query = SELECT * FROM `table`; $results = mysql_query($query, $connection);  If 'table' has no rows. whats the easiest ... View Detail
 Upvotes: 0   Answers: 0
CREATE TABLE IF NOT EXISTS fails with table already exists
I have the following code: $db_host = 'localhost'; $db_port = '3306'; $db_username = 'root'; $db_password = 'root'; $db ... View Detail
 Upvotes: 0   Answers: 0
How to use andWhere and orWhere in Doctrine?
WHERE a = 1 AND (b = 1 Or b = 2) AND (c = 1 OR c = 2)  How can i make this in Doctrine? $q->where(a = 1); $q->andWhere ... View Detail
 Upvotes: 0   Answers: 0
Create HTML table from sql table
I have a table in a SQL database with the following fields: ID, Name, Email, University, Languages, and Experience. I wa ... View Detail
 Upvotes: 0   Answers: 0

Quick Links



Total Followers
Study Group Created
Study Group Joined
Following Teacher
Following Organization
Blog Articles Added
Questions Asked
Questions Answered
Jobs Posted
Total Members in Group
Questions asked by members
Tasks added in this Group

Please wait..


Login to Open ESchool OR Create your account    Login   SignUp