Professional Hypertext Preprocessor, a widely used platform for dynamic web applications.
0
votes
1answer
23 views
RDS or Object DB for 99.99% static data of 25 million rows in one table
I have important data that consists of approx 25 million rows and will grow year on year. This dates back to 1995 and is split into yearly CSV files.
Example: 1995.csv, 1996.csv and so on up to 2016....
0
votes
2answers
8 views
Large table load slow mysql php high resources usage
in this situation i want to tell you guy's about one weird think.
Maybe its already answered for this but seriously i can't find answer.
I have table who have 130k records. 3 columns (id, product_id, ...
-1
votes
0answers
26 views
Multiple INSERT statements for two tables linked with a foreign key not submitting [duplicate]
I am trying to submit a form to my database that has a customer_t table and an event_t table. When the customer exists, the INSERT works because it grabs the customer ID and inputs it as the value for ...
0
votes
1answer
30 views
Mysql multiple check and multiple update queries
i have question about checking and updating.
The problem is that i create a very basic mysql select and update , and
two times in day i get file where php reads it. In that file have more than 14k-60k ...
0
votes
1answer
47 views
How to improve performance of a query that joins three tables?
I want to fetch data from three tables: table A, table B and table C.
Table A in databaseA has the customerid column which is a primary key
Tables B and C in databaseB also have same column ...
0
votes
2answers
29 views
Database Clog Up
I am in the process of building a messaging section for my website where clients and admin can send each other messages. I am using mysql. I am just curious, My database contains a table structured ...
1
vote
1answer
18 views
select data on base of comparing multiple values between two columns in same table
question id (1,3,2,3) responses id(1,6,4,7)
Question_Id Response_Id
1 =>1
3=>6
2=>4
3=>7
I need to select those ...
0
votes
0answers
17 views
php mysqlli select then delete [closed]
im trying to learn little mysql together with php. i can write simple queries and i know some basics on sub queries. but i want to know if it is possible to select then delete rows with fetching ...
1
vote
1answer
25 views
PHP MySQLi Lock Tables Query Sometimes Does Not Complete
I am attempting to lock some tables while running some code and unlocking the tables when I am done.
Process:
Run Lock Tables MySQL Query.
Run some PHP Code.
Run Unlock Tables MySQL Query.
While ...
0
votes
0answers
12 views
Assigning 5 letter unique id to user urls - mongodb
I haven't used mongodb ever. However, I have a query. I have 60 million unique entries(in the form of ds3qa, gkd7d, etc..) which I need to assign to urls of the user.
Would it be wise to put those ...
0
votes
0answers
13 views
Mysql Join two Tables
I have 3 tables: tbl_seller_type,tbl_seller,tbl_product.
seller_type_id on the tbl_seller references the tbl_seller_type table and the seller_id on the products table references tbl_seller table.
What ...
1
vote
2answers
43 views
High CPU Usage for single query
I recently moved from standard shared hosting to Digital Ocean.
While I've thoroughly enjoyed the experience - especially learning to manage some (relatively) large DB's - I've run into one major ...
0
votes
1answer
21 views
Get list of orders that have not been closed that are older than 60 days
I have a table te_dates that holds order status information for orders.
The table is a many-to-one relationship, so one order can have many row inserts into my order_status table.
(dsc_id is the ...
0
votes
1answer
30 views
How to better perform a query split into subquieries in PHP
In PHP I have made this query:
$getTrackID = $this->db->query("SELECT `id`,`uid` FROM `tracks`, `users` WHERE `time` > CURDATE() - interval 1 year AND `uid`=`idu` AND `public` > 0 ORDER ...
1
vote
1answer
38 views
Monthly grouped data
OK! I've a table that looks like this: SQLFiddle
And I want to get some handlers to provide to my renderer php page, so that the final result be like this:
+----------------+--------------------...
1
vote
0answers
19 views
MongoDb max timeout for all queries
I am using MongoDb/PHP on a linux server.
The problem is that, if a query takes too long to execute, the mongo server stop (apache keeps running).
So is there any way ,so that I can limit the time for ...
1
vote
1answer
35 views
How can I compare each single day of last two weeks in MySQL
I'm stuck, this job seems too complicated for me I hope in some goodness help here!
So this is my table views:
+---+--------------------+
| id| time|
+---+--------------------+
| 1 | ...
0
votes
0answers
22 views
Replicate Master to Different Slaves
I have a master database which would be the cloud server that consisted of different schools.
Now those schools are deployed to their corresponding school location which would be the local server.
...
1
vote
1answer
17 views
need to correct this Query/Loop to find and start “new branch” in the output
given these tables:
PERSONS
person_id fname lname info
1 LB Johnson "info..."
2 Bobby Baker (null)
3 Malcolm Wallace (null)
4 Billy ...
1
vote
0answers
29 views
Play with database - which option is better? [closed]
in php-mysql projects when we want to create , drop , alter, modify tables/columns
we can create through
1) phpmyadmin
2) script [.php file]
3) writing queries in .sql file and import to ...
0
votes
1answer
49 views
Disadvantage of Changing database schema - Insert or delete new columns/tables in middle
As a read in lot of links , for e-commerce shopping sites, as it may require to add lot of attributes in regular basis, is it okay if we go with Flat tables ?
Whats the disadvantage of changing ...
0
votes
1answer
71 views
How to prevent Performance issue & going for Denormalization
We are planning to do an e-commerce shopping site with PHP-MYSQL combination.
I read in almost every link related to Normalization & Denormalization : Normalize until it hurts, denormalize until ...
0
votes
0answers
54 views
How to fix duplicate column name error in PhpMyAdmin database?
I was testing my Buzzy script on XAMPP. I created a database name "buzzydbtest" and while installing and assigning database details I got this error-
SQLSTATE[42S21]: Column already exists: 1060 ...
0
votes
1answer
30 views
MySQL deleting lots of rows by id - where in or loop over each row in transaction
I have a delete query which is potentially going to delete tens of thousands of rows.
Currently it's taking quite a long time in the more extreme case (over 100000 rows to delete) using this:
...
0
votes
0answers
13 views
Firebird - Error consulting table in PHP
I have this strange error:
[Tue Sep 06 23:53:30.608936 2016] [:error] [pid 13501] [client ::1:48942] PHP Warning: ibase_prepare(): Dynamic SQL Error SQL error code = -204 Table unknown TB23040012 ...
0
votes
1answer
80 views
Simplest way to check if current user has permission to a MySQL table (from PHP / mysqli) for some desired operation?
While using an already established mysqli connection to a MySQL database from PHP, I'm looking for a simple way to check if this connection (i.e. the authenticated user for this connection, if any) ...
0
votes
1answer
47 views
Join multiple tables without overhead on the DB Server using PDO
I have multiple tables called light_readings, temp_readings, co2_readings and humidity_readings.
The column format of the tables are as below:
light_readings:
Id, light_value, unitid, date_time
...
0
votes
1answer
50 views
Query larger than table - MySQL and PHP
I am working on a db with only a few records, say 5 only. The DB has several columns; records being each row and a field being each column in the row/record. What's the correct Query?
db: movies
...
0
votes
1answer
42 views
How the input entered through the front-end form match with the existing data in database
Am working on an application that helps user to enter symptoms that matches those existing in the database and gets disease(diagnosis).
I have the following database table with information about ...
3
votes
2answers
108 views
Timeout error after SQL Server upgrade from 2008R2 to SQL Server 2014
We had a SQL Server 2008R2 Enterprise edition for our database to support a front-end application. We never had any timeout issues before. Recently the company decided to upgrade the database in to ...
0
votes
0answers
20 views
Does mysqlnd expose PDO connection data to process/log files?
So I was trying to figure out how to write an automated backup script for php on a shared webhost to execute using mysqldump, with no root access to core php.ini or mysql config on the remote database ...
0
votes
1answer
48 views
Optimal way(performance wise) to store array like data in MySQL
I am working on a website(PHP), and one of the features that the site should have is ordering items from the website, and the order will be like an array with an architecture similar to this:
order(
...
0
votes
1answer
64 views
How to connect MS sql database and php using xamp
I am trying to connect MSsql database and php using xamp. But i am unable to connect. bellow is my code. Please help me to find this.
<?php
$myServer = "x.x.x.x";
$myUser = "xxx";
$myPass = "xxxx";...
0
votes
2answers
113 views
Mysql database table shows id(auto-Increment) is 0 in all records
I am using laravel 5.2 to developed my web application. i recently upload the web application from localhost to my hosting account. I also imported MySQL tables from phpmyadmin localhost to my ...
1
vote
1answer
31 views
Combine 4 rows based on common ID and Date
I have a query that returns 4 lines per ID. I would like to be able to merge these into one single row in a new table, based on the ID and Date.
Can anyone help?
I've researched and seem can't find ...
1
vote
3answers
79 views
SQL trigger when a row is updated question
My problem is as follows.
I an creating a MySQL database for a company that whenever a row is updated on the DB i want to have a trigger that calls a cURL request to transfer the updated information ...
2
votes
1answer
236 views
Cassandra “Operation timed out - received only 0 responses.” during write
I'm using Datastax PHP Cassandra Driver and Cassandra 2.2.5 on Windows 10. This is a single-node cluster, and the keyspace replication of
{
'class': 'SimpleStrategy',
'replication_factor': 1
}...
0
votes
1answer
26 views
I am trying to run this code and I get an error at line 11 [closed]
CREATE TABLE IF NOT EXISTS `tblproduct` (
`id` int(8) NOT NULL AUTO_INCREMENT,
`name` varchar(255) NOT NULL,
`code` varchar(255) NOT NULL,
`image` text NOT NULL,
`price` double(10,2) NOT ...
-1
votes
1answer
27 views
How can I create a church attendance report system?
Please am pretty new to php and mysql. I have an assignment to create a church attendance system for our weekly services. The system would be able to know how many males and females came to church ...
1
vote
1answer
48 views
What's the advantage of the inet datatype in Cassandra vs a plain text string?
What is the inet datatype really for? The documentation refers to its usage having something to do with Python but I'm not much of a Python guy so that aspect is beyond me. Is there any advantage to ...
0
votes
1answer
26 views
MYSQL inner join , if not match try another table
I've got a very quick issue here, how can i join a table with two other tables in a way if one's info doesnt match, it goes try another one. something like:
$properties = $mysqli->query("SELECT *...
0
votes
1answer
20 views
How to make table with row name and column name
I am new to databases and now i came to a point where i need more complex table.
I have a table which contains site details. Each site can have multiple devices. Each device have multiple measurement ...
-1
votes
1answer
48 views
Recovering a lost database [closed]
Before I start, there might not be a way to do this but I thought I would ask anyway..
I built a php application with Laravel 5.2 and have suddenly noticed I have lost the MySQL database for the ...
0
votes
1answer
58 views
Reset MySQL table data after each session is completed in php
I am creating a PHP application demo. The users who login can insert, modify and delete data but when they logout the data must be reset to the default data I set before.
The data must reset ...
0
votes
0answers
79 views
PDO, create temporary table and select seem not to behave as expected
From a php cli script, I'm trying to create a temporary table and populatie it if it does not already exists. This works but is not optimised. By design, this script may try to execute the MySQL ...
0
votes
1answer
38 views
Can't login to sql server custom db
I have wamp installed in my system and sql server 2014, and configure so i can access sql server db through php.. with this code:
<?php
$serverName = "MY-PC\sqlexpress";
$connectionInfo = array(...
0
votes
1answer
65 views
How to get list of dates between From Date and To Date in MySQL [closed]
I have a table Emp_UnAvailablity_ID`, `PersonID`, `Is_UnAvailable`, `From_Date`, `To_Date` FROM `emp_unavailablity. I want to get list of all dates between From_Date and To_Date. I have tried this ...
1
vote
0answers
17 views
log_bin_trust_function_creators deterministic always throws an error on server restart [duplicate]
Everytime my rackspace server restarts because of some maintenance or an outage, all of my mysql functions stop working due to this deterministic error.
To fix this, I have to manually pull up the ...
3
votes
0answers
112 views
Inputting auto-incrementing, grouped, unique hashes?
Alright, here's what I've come up with so far:
SET @id=(SELECT IFNULL(MAX(id) + 1, 0) FROM leads);
UPDATE leads SET id=@id WHERE id IN (
SELECT id FROM (SELECT * FROM leads) AS something WHERE ...
-1
votes
1answer
77 views
Server Specifications for Web Application [closed]
I am trying to select the configuration for a web application built in PHP 5.5 and MySQL 5.1. I will also be deploying PHPmyAdmin for the MySQL database. Both the web application and the database will ...