Tagged Questions
MySQL is an open-source, relational database management system. If your issue relates to MySQLi, use the MySQLi tag instead.
0
votes
0answers
8 views
Notice: Undefined index: ip in C:\xampp\htdocs\ip_mac_add.php on line 64 [duplicate]
I am trying to make a php form where i could entery the data to MySql table
I am using Xampp server and I am facing a problem:
Notice: Undefined index: ip in C:\xampp\htdocs\ip_mac_add.php on line 64
...
0
votes
0answers
3 views
MYSQL Connector not installing in Windows7 64bit
OS : Windows 7 64 BIT
I am trying to install mysql connector but its failing kindly help,
I am getting following error after installing (log attached)
Can someone can provide me the zip of dll's for ...
0
votes
0answers
8 views
SQL statment works in phpMyAdmin but not PDO?
I Have a SQL query that uses PHP/PDO. I am using a left join. If I copy/paste the echoed SQL in phpMyAdmin Results come up just fine. But I get a PDO Exception in PHP. I have a Class with Static ...
1
vote
3answers
15 views
UPDATE SQL, only UPDATE image if not null
I am trying to allow users to update a table that has an image file-upload input. Only the filename is stored in the database, such as image.jpg. My problem is that if the user chooses not to change ...
0
votes
1answer
20 views
how to retrive data from my sql query
hi friends i'm trying to do report for hospital.
they need report for list of vaccine from date to to date my query are
SELECT recpt_no,vaccine,regno,vac_name,recpt_date,user_name
FROM receipt
...
-1
votes
0answers
6 views
Java iReport JDBC connection error
I am trying to create an iReport using netbeans iReport plugins.
When I Try to test a connection, it gives an error message as,
SQL problems: Access denied for user ''@'localhost' to database
...
0
votes
0answers
4 views
Laravel 5 migrations : default length of different types in Schema::table method
I'm setting up a migration on Laravel 5 and was wondering if there was some documentation for the default lengths of each of the Column Types ? Do they follow some convention like MySQL's?
Ex:
...
0
votes
0answers
7 views
Yii2 RBAC for Multiple Groups/Users
I have a web application that I am developing and am still in the design/research phase to explore best practices.
First of all, the application has multiple users, and each user has a default group, ...
0
votes
0answers
5 views
Association references unmapped class: com.service.hibernate.entities.Connetion
Sorry for bothering you. I'm newbie with hibernate and I have problem with mapping. I think that it'll be stupid mistake but I'm not able to deal with this problem on my own. I won't decribe whole ...
0
votes
0answers
7 views
Multiple duplicate columns in two tables, split off?
I have an Instrument table, and an Computer table. They have around 15 columns which are the same, so I was thinking of splitting them up.
I was thinking of having a parent table Equipment to store ...
0
votes
1answer
16 views
Display Array Value in Header (H1) Tag
I would like to use employee name in h1 tag. Can anyone please tell us how to do this. See the comment description for further info.
<html>
<head>
<title>Employee Data</title>
...
0
votes
2answers
11 views
Adding a TRIGGER to phpMyAdmin MySQL table to DELETE a row in Table A it's corresponding row is deleted in Table B
So I have two tables, RESERVATIONS and RESERVATION DETAILS.
The primary key reservationId for RESERVATIONSis a foreign key in RESERVATION DETAILS.
In my website, the user can delete a reservation ...
0
votes
0answers
24 views
Merge 2 MySQL Queries
I have 2 queries, that are almost exactly the same.
1:
SELECT cman_code, cman_name
from capder
JOIN caprange ON capder.cder_rancode = caprange.cran_code
JOIN capman ON caprange.cran_mantextcode ...
-2
votes
1answer
9 views
Database schema samples for mysql?
Sample schema and solutions for complex problems. Where can I resource like that other than database answers?
-3
votes
1answer
17 views
How does saving image on a file system instead of database works?
If i understand saving on a filesystem correctly you will just save the directory of the image to your database if that is correct what if different computer access it and the directory in my database ...
-2
votes
1answer
10 views
Connecting iOS with Mysql database without webservice
Does anybody know the method for the connection between Objective-C with Mysql without a web service??
I've worked with Objective-C and Mysql database with Json but the last week a partner worked with ...
-2
votes
1answer
10 views
MySQL server is requesting the old and insecure pre-4.1 auth mechanism
I am putting this here for reference because it was something I found and had a tough time searching for and getting any answer that worked for me, but this might work for you.
MySQL server is ...
-1
votes
0answers
17 views
Does MySQL have a text search that seems to work like Google's?
I'm making a website where the backend uses MySQL and the Ruby gem Sinatra.
My MySQL table has a LONGTEXT column with a FULLTEXT index.
I've written a MySQL query that's basically this:
SELECT Plot ...
0
votes
1answer
25 views
extra column in MySQL, can I drop it?
I have a database I'm creating and I made a 1 to 1 connection with another table in Mysql, below is a screen shot. My question is can I drop the extra column (assembly factory_id) that was created ...
0
votes
4answers
28 views
Query get all latest records based on user_id
I have a table called photos that has hundred of thousands of user uploaded photos.
Each user can obviously upload several photos.
The table schema is:
id,
user_id,
photo,
date_created
I just ...
0
votes
1answer
10 views
SQL query - Select with SUM function with limit
I'm trying to make a query to list PTR_NUM who have at total PTNG_PRICE above 7000. I'm trying to do this:
SELECT painter.PTR_FIRSTNAME, painter.PTR_LASTNAME,
SUM(painting.PTNG_PRICE) AS 'TOTAL ...
0
votes
0answers
15 views
Generating a path from mysql tables using recursive queries
I have 2 tables:
CREATE TABLE `calls` (
`id` int(11) NOT NULL AUTO_INCREMENT,
`sid` int(11) DEFAULT NULL,
`tid` int(11) DEFAULT NULL,
PRIMARY KEY (`id`),
KEY `sid` (`sid`),
KEY `tid` ...
0
votes
1answer
17 views
Importing JSON into mysql using python
Im trying to import this into mysql,
I have the json output:
{u'age': u'27',
u'foulsCommitted': u'36',
u'foulsSuffered': u'19',
u'goalAssists': u'0',
u'no': u'18',
u'pla': u'Jaume Costa',
...
0
votes
1answer
15 views
using mysql how to insert rows in audit table?
I am new to mysql,
I have two table employee and audit
employee Table have 4 columns
id
name
sal
role
audit Table have 7 columns
id
type
old_value
new_value
date
username
Here , I want to ...
-1
votes
2answers
16 views
Mysql search if last 3 records exist with same order
i have a table with a column of numbers
35
24
7
8
11
35
9
11
6
6
23
23
34
5
14
31
26
2
16
0
6
23
23
i want to check if the last 3 records
6
23
23
exist in previous records but with the same ...
0
votes
2answers
19 views
At what number of columns should you make another table?
I had a table that nearly reached 20 columns.
I find each one necessary since it's a "project" table, and the project has columns that indicate stuff such as when it was created, when it was ...
-1
votes
2answers
28 views
Pdo request, I really don't get it
Juste an simple pdo request that doesn't work. I don't get it. Really don't.
$d = strtotime("today");
$start_week = strtotime("last sunday midnight",$d);
$start = date("Y-m-d",$start_week);
$s1 = ...
0
votes
0answers
8 views
Filter table based on user inputs/checkboxes/dropdowns
I have some data that I'm having trouble figuring out how to filter on my website. The data needs to be filterable based on user entered figures (price range) and items selected from a dropdown menu ...
0
votes
1answer
4 views
How to import a cvs with a column md5 to mysql
I'm trying to import a .cvs file to MySql
This is my .cvs file:
,AI,MD5('AIRT2015'),RRHH,14,,,AION S.A. DE C.V.,
and this ismy db's structure:
when I upload the .cvs file i see password ...
0
votes
0answers
12 views
How to properly store global variables for php server code
I am writing php scripts for a server code. These include sign up, log in, and similiar functions. These functions often reference the same database and URLs. I have been reading on stackoverflow and ...
0
votes
1answer
20 views
“key column doesn't exist in table”
I'm making a database in MySQL in class and I'm having trouble adding foreign keys to my tables. I already added most of the foreign keys to my tables when I created the tables but obviously I ...
-1
votes
0answers
7 views
PhpMyAdmin automatic data value sync
I need to make a website where people can save their user balance to a database. On the website there is a button which says 'Sync'. I need to make it so the 'Sync' button will update the database ...
0
votes
0answers
7 views
DPFP login retrieving data from database
I'm trying to create an authentication application using username and fingerprint, where user puts in his username and a related fingerprint template. So far I managed to save the data into phpMyadmin ...
0
votes
1answer
17 views
Is it bad practice, security-wise, if user could know the primary key id of items
I am populating a page with a list of items from DB (lets say main.htm - each item has a link, and opening a link will display the content of the item.
I am using ajax to open the items. For ...
0
votes
0answers
10 views
how can I INSERT a random Point with X|Y which is not yet in my Mysql Database
Yeah.
I have some bases in coordinates. they are all around the center. Now I want to add one more base, at unique coordinates, near the other bases. I have thought about that so far:
INSERT INTO ...
0
votes
0answers
12 views
Creating a MySQL database in memory with PHP PDO
I'm coding a library to compare two MySQL databases.
Sources can be a SQL string, SQL file or a MySQL database connection.
Use regular expressions to parse tables/alter/indexes form sources is ...
1
vote
1answer
21 views
PHP; PDO; MySQL INSERT query with drop down
I am struggling with this two input INSERT query. It will not insert anything to the db. First, it is supposed to accept user input and the dropdown menu selection which is the id from another table ...
0
votes
1answer
29 views
MySQL SUM() giving incorrect total
I am developing a php/mysql database. I have two tables - matters and actions.
Amongst other fields the matter table contains 'matterid' 'fixedfee' and 'fee'. Fixed fee is Y or N and the fee can be ...
0
votes
2answers
21 views
PHP adding only a new record to a SQL database
I need to only new data to a database table. I am trying to query the database but and only add new data. I am somewhat lost in SQL and PHP.
I have got the code entering to the database but on ...
0
votes
0answers
22 views
MEAN with mySQL
I'm trying to learn angularjs and I want to use mySQL instead of MongoDB in my MEAN stack. Coming from a LAMP background, I am having trouble understanding the organizational/functional structure of ...
1
vote
0answers
12 views
Get Username from other table by author_id from another table CakePHP
I'm using CakePHP and i don't know how to connect data from two tables.
Here is my tables data
users
id, username, password - and so on
news
id, title, text, author
Now i have controller, in ...
0
votes
2answers
18 views
PHP or MySQL is replacing certain characters with what appears to be gibberish (even though obviously it means something to the computer)
I have code for a query that looks like this (yes, I'm aware my input is not sanitized):
$search_query = "SELECT * FROM `comments` WHERE comment LIKE '%".$_POST['search_query']."'%";
But for ...
1
vote
2answers
30 views
joining a SQL table with no value
I am doing a table join
SELECT b.type AS business,
b.business AS business,
b.city AS city
FROM businesses as b
JOIN cities AS c ON n.city = c.id;
My problem is that my table ...
0
votes
0answers
14 views
Seemingly Random Hangups/Lags Loading Website
We run an OS Commerce powered web page on our own dedicated server. In April of last year, we were forced to upgrade the server. At around that point, we started to notice that there were seemingly ...
0
votes
1answer
25 views
Using results from a query within the same query
I have a rather big SQL statement that I am working with in MS Access 2010. Here it goes:
SELECT
W.ID AS wid,
W.wpt_ty AS ty,
W.wpt_num AS num,
W.wpt_nxt AS nxt,
W.latdeg AS lat,
W.londeg AS lon,
...
-1
votes
3answers
16 views
mySql and PHP syntax.. something simple is missing
I am almost embarrassed to ask this, but I have been staring at it and feel like there is an easy answer but i'm not seeing/finding it.
I have this line in my php where i am using a string "checked" ...
0
votes
1answer
9 views
Mysql Join with pipe-separeted field
I currently have this table (wm_acquisti):
USER_ID BARCODE
12 600001
56 500003
12 600007
12 800018
32 100004
56 500007
(And so forth...)
Being a ...
-1
votes
0answers
16 views
Can you help me with my admin login code?
This code should response after typing true username and pass then redirect to the index page but it always response with "else" which give wrong (Wrong Username or Password) even if the information ...
-1
votes
1answer
29 views
Error java.lang.IndexOutOfBoundsException: Invalid index 1, size is 1 [on hold]
i'm developing an android apps using Google maps v2 and shows locations base on the coordinate that i had been put in MySQL server. the map successfully show up but an error occur when i click the ...
1
vote
0answers
13 views
Html-Entity encoded empty HTML Tag
Can this combination of characters, alone in a form field, be used for an XSS or SQL attack, if properly "Html-Entity Encoded" right at the beginning of PHP code ?
<>
Here is a very simple ...