Skip to content
  • Register
  • Login

LT BYTES

Learn Tech Bytes

  • Home
  • AWS
  • PHP

Sql

Posted inAll / Sql

Concat fields in mysql

by SuryaApril 18, 2011December 4, 20230

By using CONCAT function in mysql, we can concat fields or string. SELECT CONCAT(‘field1’, ‘-‘, ‘field2’, ‘-‘, ‘field3’); // Output: // ‘field1-field2-field3’

Posted inAll / Sql

get number of days between two given dates using MySQL

by SuryaJanuary 15, 2011December 4, 20230

SELECT DATEDIFF(“2007-03-07”, “2007-03-01”); // For static dates SELECT DATEDIFF(ColumnA, ColumnB); // For Table column based dates

Posted inAll / Sql

get number of records count in mysql

by SuryaJanuary 15, 2011December 4, 20230

To get the records count of table in mysql: SELECT COUNT(‘fieldname’) AS RecordsCount FROM TableName; (OR) SELECT COUNT(*) FROM TableName;

Posted inAll / Sql

Maximum length of a Database name, Table name, Field name in MySQL

by SuryaJanuary 15, 2011December 4, 20230

Database name: 64 characters Table name: 64 characters Column name: 64 characters

Recent Posts

  • Deploying AWS Lambda with Docker & Serverless Framework
  • Create and Update SNS Subscription Filter Policy using Python Boto3
  • Turn on errors in PHP
  • Php coding standards
  • WordPress plugin to save contact information to database

Recent Comments

No comments to show.

Archives

  • February 2025
  • January 2024
  • December 2023
  • March 2013
  • December 2012
  • April 2012
  • August 2011
  • April 2011
  • February 2011
  • January 2011
  • October 2010
  • July 2010
  • June 2010
  • January 2010
  • December 2009
  • November 2009
  • October 2009

Categories

  • All
  • AWS
  • Javascript
  • Joomla
  • Php
  • Python
  • Sql
  • Uncategorized
  • Wordpress
Copyright © 2025 LT BYTES.
Powered by WordPress and BNM.
  • Home
  • AWS
  • PHP