I am using datatables v 1.10.19 As i was using the following ,the group by destroys the pagination and only shows one page. $where = “recipient='”.$recipient.”‘ AND grouped=” GROUP BY id …
Tag: pdo
Select active data by order
I have 2 tables posts and categories, There is one-to-many relation between both tables. Here are the two tables: There is a relation between category_id and c_id, So that the category_id in the posts table refers to the category id c_id. The post_order and c_order are used to order both posts and categories. And the post_active and c_active are used
PHP get return value of stored procedure
I have pleasure to work with legacy PHP application using SQL Server via PDO. How in PHP can I retrieve return value of stored procedure which is using RETURN statement as output channel? Example procedure If possible, I would prefer to not modify procedure. I am aware that there are similar questions, but they don’t cover this case Get RETURN
Impossible to load pdo driver on Windows Server 2016
Im trying to load the pdo driver for firebird database on a windows server 2016 (64 bits). Configuration is the next : Firebird in 32 bits successfully installed. Apache 2.4 successfully installed (Apachelounge binary, 32 bits). Apache configuration properly set (installed in C:/Apache24) PHP 32 bits successfully installed (in C:/PHP) as a module with mod_php (apache handler 2.0). As a
How to display messages from the database on left and right?
‘I made a simple chat box with php but the problem is i want to display my messages on the right and the other user messages on the left i made two while loops but they didn’t work. My table is like this (Sender – reciever – msg) I want to display each message ordered by time and on different
Why is my while loop spitting out the same row 50+ times? PHP
Here is my code: And here is the while loop: This is just returning 50+ of the same row, aka the only row in the database, but it should only return it once? Answer You’re running the query again in each loop. GetLatestUsers should return the statement.
How to check fetched result set is empty or not?
For example: AND How to check if result set is empty or not Answer Check $data variable like: If the result of SELECT query did return any data, variable $data will contain a non-empty array/object which evaluates to true, and a false-like value otherwise.
Select from database only values not seen before [closed]
Closed. This question needs details or clarity. It is not currently accepting answers. Want to improve this question? Add details and clarify the problem by editing this post. Closed 5 years ago. Improve this question Let’s say that I have a database with this data stored: How can I select all of this value with a PDO query excluding those
PHP 7.1 on Docker PDO Driver not installed – Verified it is on the image
I am always getting an error that PDO driver not found. I tried restarting, installing PDO extensions directly. Note that this docker setup works on my Linux box last night. Only difference is I did it from scratch compared to on my Windows box I already has images. After getting the error initially I tried to remove the images, the
PHP Warning PHP Startup Unable to load dynamic library php_pdo_sqlsrv_7_ts_x64.dll
OS: Windows 8.1 Arch: x64 php: PHP 7.1.6 mssql: Mssql Server 2014 express driver: SQLSRV 4.0 IDE: PhpStorm I’m trying to get mssql drivers to work. I downloaded the pdo driver from …