<< < 47 48 49 50 51 52 53 54 > >>   ∑:1288  Sort:Date

odbc_prepare() - Creating Prepared Statements
How To Create Prepared Statements using odbc_prepare()? If you have a SQL statement that need to executed repeatedly many times with small changes, you can create a prepared statement object with parameters so it can be executed more efficiently. There are two functions you need to use prepare and e...
2024-06-03, 1323🔥, 0💬

PHP MSSQL - Inserting Multiple Rows with a Subquery
PHP MSSQL - How To Insert Multiple Rows with a subquery? If want to insert rows into a table based on data rows from other tables, you can use a subquery inside the INSERT statement as shown in the following script example: &lt;?php $con = mssql_connect('LOCALHOST','sa' ,'FYIcenter');mssql_selec...
2024-02-28, 1323🔥, 0💬

odbc_errormsg() - Retrieving ODBC Error Messages
How To Retrieve Error Messages using odbc_errormsg()? When you call odbc_exec() to execute a SQL statement, and the execution failed on the SQL Server, you can use odbc_error() and odbc_errormsg() to retrieve the error code and error messages. The tutorial script below shows you a good example: &...
2024-06-30, 1322🔥, 0💬

ntwdblib.dll - SQL Server Client Library DLL
What Is Wrong with SQL Server Client Library DLL, ntwdblib.dll? The second requirement to access SQL Server with PHP scripts is the SQL Server Client Library DLL, ntwdblib.dll. The good news is that the Windows binary version of PHP 5.2.3 has ntwdblib.dll included in the PHP home directory. But the ...
2024-04-14, 1320🔥, 0💬

MS SQL Server DBA Checklist - General DBA Best Practices
-- Join (or start) a local SQL Server users group -- Attend at least one professional conference each year. -- Attend at least one training session each year. -- Read at least four books on SQL Server each year. -- Read the free e-book, How to Become an Exceptional DBA -- Learn everything you can ab...
2022-01-24, 1320🔥, 0💬

Selecting Columns in a Query in MySQL
How To Select Some Columns from a Table in MySQL? If you want explicitly tell the query to return some columns, you can specify the column names in the SELECT clause. The following select statement returns only two columns, "id" and "url" from the table "fyi_links": mysql&gt; SELECT id, url FROM...
2017-11-05, 1320🔥, 0💬

PHP ODBC - odbc_num_rows() - Number of Affected Rows
PHP ODBC - How To Get the Number of Affected Rows? If you insert multiple rows with a single INSERT statement, you can use the odbc_num_rows() function to find out how many rows were inserted. odbc_num_rows($result_set) returns the number of affected rows based on the result set object returned by t...
2024-05-29, 1318🔥, 0💬

mssql_fetch_array() - Looping through Result Set Objects
How To Loop through Result Set Objects using mssql_fetch_array()? If the returning output of a query statement is captured in a result set object, you can use mssql_fetch_array() to loop through each row in the output. The tutorial PHP script below shows you how to list tables in the database: &...
2024-03-23, 1318🔥, 0💬

mssql_result() - Retrieve Field Values
How To Retrieve Field Values using mssql_result()? Once the result set is captured in an object, you can think of it as a "table" with rows and columns (fields). You can use mssql_result() to retrieve the value of any given row and column (field) with this formats: $value = mssql_result($res, $row, ...
2024-03-23, 1317🔥, 0💬

Enabling TCP/IP Protocol on a SQL Server
How To Enable TCP/IP Protocol on a SQL Server? By default, the TCP/IP protocol is turned off when a SQL Server is installed to reduce security risk. But if you want applications to connect and access the SQL Server, you need to enable the TCP/IP protocol on the server by following this tutorial: 1. ...
2024-07-25, 1316🔥, 0💬

Testing ODBC DSN Connection Settings
How To Test ODBC DSN Connection Settings? Assuming you have followed other FYIcenter.com tutorials and created an ODBC DSN called "FYI_SQL_SERVER", and planning to use it your PHP scripts, you should test this ODBC connection first as shown in this tutorial: 1. Go to Control Panel &gt; Administr...
2024-07-11, 1315🔥, 0💬

PHP MSSQL - mssql_fetch_array() - Looping through Returning Rows
PHP MSSQL - How To Loop through Returning Rows? The best way to query tables and loop through returning rows is to run a SELECT statement with the mssql_query() function, catch the returning object as a result set, and loop through the result with mssql_fetch_array() function in a while loop as show...
2024-02-28, 1313🔥, 0💬

PHP ODBC - Searching Records by Keywords
PHP ODBC - How To Perform Key Word Search in Tables? The simplest way to perform key word search is to use the SELECT statement with a LIKE operator in the WHERE clause. The LIKE operator allows you to match a text field with a keyword pattern specified as '%keyword%', where (%) represents any numbe...
2024-05-05, 1310🔥, 0💬

"ALTER TRIGGER" - Modifying Existing Triggers in SQL Server
How To Modify Existing Triggers using "ALTER TRIGGER" in SQL Server? If you want to make changes to an existing trigger, you could use the "ALTER TRIGGER" statements to refine the trigger again. The tutorial exercise below shows you how to modify the trigger defined in a previous tutorial: USE FyiCe...
2016-10-24, 1306🔥, 0💬

odbc_data_source() - Listing All DSN Entries
How To List All DSN Entries on Your Local Machine using odbc_data_source()? If you are interested to know what DSN entries are available on your local machine, you can use odbc_data_source($con, SQL_FETCH_FIRST) and odbc_data_source($con, SQL_FETCH_NEXT) in a loop to list all DSN entries defined on ...
2024-07-11, 1305🔥, 0💬

odbc_columns() - Listing All Columns in a Table
How To List All Columns in a Table using odbc_columns()? If you want to get a list of all columns in a table, you can use the odbc_columns() function, which can actually be used to list all columns in all tables and views in the database. The syntax of odbc_columns() is: $result_set = odbc_columns($...
2024-06-03, 1303🔥, 0💬

PHP MSSQL - Making Columns to Take NULL
PHP MSSQL - How To Make a Column Nullable? Based on the testing result from the previous tutorial you can find out that there is a big difference in the column definition when running CREATE TABLE statement with mssql_query(): If CREATE TABLE is executed through mssql_query() and "NULL/NOT NULL" key...
2024-03-07, 1303🔥, 0💬

"DROP TRIGGER" - Deleting Existing Triggers in SQL Server
How To Delete Existing Triggers using "DROP TRIGGER" in SQL Server? If you don't want to use a trigger any more, you should delete it from the database by using the "DROP TRIGGER" statement as shown in tutorial example: USE FyiCenterData; GO DROP TRIGGER new_user; GO SELECT * FROM sys.triggers GO na...
2016-10-24, 1303🔥, 0💬

Configuring and Testing ODBC DSN Settings
How To Configure and Test ODBC DSN Settings? Continue from the previous tutorial. Click Next after you have finished changing the port number. The ODBC Data Source Administrator will try to connect to the SQL server through the specified port number and login information. If the connection is succes...
2024-07-25, 1300🔥, 0💬

odbc_connect() - Connecting to a SQL Server through an ODBC DSN
How To Connect to a SQL Server using odbc_connect()? If you have an ODBC DSN (Data Source Name) created linking to a SQL Server, you are ready to connect to the SQL Server through the DSN with ODBC functions. There is no changes needed in the php.ini configuration file. The tutorial script below sho...
2024-07-11, 1300🔥, 0💬

odbc_fetch_row() - Looping through Result Set Objects
How To Loop through Result Set Objects using odbc_fetch_row()? If the returning output of a query statement is captured in a result set object, you can use odbc_fetch_row() to loop through each row in the output. The tutorial PHP script below shows you how to list tables in the database: &lt;?ph...
2024-06-30, 1300🔥, 0💬

Simplest Way To Create New Databases in SQL Server
What is the simplest way to create a new database in SQL Server? The simplest way to create a new database is to use the "CREATE DATABASE" statement with this syntax: CREATE DATABASE database_name For example, run this statement: CREATE DATABASE FyiCenterData GO A new database called "FyiCenterData"...
2016-11-24, 1284🔥, 0💬

odbc_result() - Retrieve Field Values
How To Retrieve Field Values using odbc_result()? After calling odbc_fetch_row(), the field values of the fetched row are available in the result set object. You can use odbc_result() to retrieve the value of any given field with two syntax formats: $value = odbc_result($field_name); #- Retrieving v...
2024-07-11, 1282🔥, 0💬

Starting SQL Server Browser Service
How To Start SQL Server Browser Service? SQL Server Browser Service is installed as part of the SQL Server. But it is turned off by default to reduce the security risk. If you want start SQL Server Browser Service to allow the SQL Server to accept network connections, you need to follow the steps be...
2024-07-25, 1275🔥, 0💬

<< < 47 48 49 50 51 52 53 54 > >>   ∑:1288  Sort:Date