Skip to main content
The 2024 Developer Survey results are live! See the results

All Questions

Tagged with
-2 votes
0 answers
45 views

Problem connecting to SQL with PHP - This extension requires the Microsoft ODBC Driver for SQL Server to communicate with SQL Server [duplicate]

I'm on a shared hosting platform with Krystal running Ubuntu, trying to connect to an SQL database in house with PHP but I'm getting the error: Caught PDO exception: SQLSTATE[IMSSP]: This extension ...
Michael Bellamy's user avatar
-1 votes
0 answers
34 views

Laravel 10 connects to SQL Server [closed]

This's first time i learn Laravel 10. I want to learn Laravel 10 by using Sql Server Database. When i try to coconnect SQL Server to Laravel 10, it always be failed. I don't know the reasons. I use ...
Stefanus Nigel Anggriawan's user avatar
-2 votes
1 answer
46 views

Connect PHP and SQL Server using Visual Studio Code. using localhost and xampp as well

Where should I place my PHP file? It's currently in a project folder. I have downloaded the Microsoft SQL Server extension in VSCode but still the undefined problem of couldn't connect the database ...
Ton's user avatar
  • 1
-1 votes
0 answers
29 views

SQSRV not found in phpinfo()

I have set up the required drivers for SQL server that suits PHP 8.3. but sqlsrv not found in phpinfo() page. whereas, for version 8.1 and 8.2, both are showing it. kindly someone help me to set up ...
Captain Sam's user avatar
0 votes
1 answer
37 views

Laravel migrations create table column with dot in colum name

I have a table in SQL Server database where a column has a dot in its name. When I first created manually the table I had no problems doing it, but now that I'm changing the db server I decided to ...
Igic's user avatar
  • 55
-1 votes
1 answer
63 views

Function runs slowly (12s) from PHP but quick (sub-second) in SSMS. What are some areas of investigation?

I have a SQL Server function that uses several WITH CTEs to pre-process some data prior to the output in FOR JSON PATH format. The query runs sub-second in SSMS but is taking twelve seconds when ...
arresteddevelopment's user avatar
0 votes
1 answer
58 views

Not able to show a pdf / image from binary data in MSSQL using PDO LOB

I go MSSQL database which contains attachments - most of them are PDFs. I want to create simple website, that will display attachment after clicking a button. I got main website prepared (there are ...
nequ2k's user avatar
  • 21
1 vote
1 answer
84 views

Strange behavior of symfony doctrine during phpunit test - field becomes null in database

I am using Symfony v6.4.8 doctrine/orm 2.19.5 phpunit/phpunit 9.6.19 I have build an REST API GET endpoint /api/contract/{$id} in Symfony. It performs an API request at another system, receiving ...
SvenW's user avatar
  • 21
0 votes
1 answer
55 views

How to Modify PHP Code to Replace Existing SQL Entry Instead of Creating Duplicate?

I have been tasked with fixing some PHP code for a website and believe I found the main snippet that is causing the frustration. When an employee is hired they are entered into the system and given a ...
user25666555's user avatar
0 votes
0 answers
66 views

SQL Server 2008/2019 Connection Issue

Connection could not be established. Not able to connect and execute queries from PHP. I'm getting this... Array ( [0] => Array ( [0] => HY000 [SQLSTATE] => HY000 [1] => -2146893042 [code]...
Captain Sam's user avatar
0 votes
1 answer
37 views

PHP PDO SQL Server - Timestamp data type issue

I am upgrading a PHP application from an older 5.4 version to the latest 8.3.8 using PDO SQLSrv to connect to my database. I have a timestamp data type in the database to check if a record has been ...
Kyle's user avatar
  • 4,441
0 votes
1 answer
141 views

Laravel 11 Connect Microsoft Azure SQL Server on Mac OS Sonoma M1

I am trying to connect Laravel 11 to Microsoft Azure SQL Server on Mac OS Sonoma M1 Before I try to install Microsoft Azure SQL Server Edge (as Microsoft SQL Server alternative for Mac OS with M1 Chip)...
bungdito's user avatar
  • 3,602
0 votes
0 answers
78 views

Laravel eloquent relationship with binary SQL Server

I have 2 tables in SQL Server. Table Account: [id] [binary](13) NOT NULL, [PRIMARI KEY] [email] [varchar](50) NOT NULL, .... Table Status: [numG] [int NOT NULL, [id] [binary](13) NOT NULL, [PRIMARI ...
blackhoLe's user avatar
0 votes
1 answer
52 views

Discrepancy in SQL_SRV Behavior Across Environments

I have a PHP script on a remote machine that pulls from a Microsoft SQL Server database and inserts the data into a MySQL database. I have a cron job set up to run the script hourly so the MySQL ...
Spencer Ke's user avatar
0 votes
0 answers
46 views

PHP Variable contains extra information after SQL Query Execution

I have some weird behavior happening with a parameter passed by reference to a SQL Server Stored Procedure. I have a variable ($FormType2) in a parameter array passed to the Stored Procedure. When the ...
Jack Duece's user avatar

15 30 50 per page
1
2 3 4 5
447