Skip to main content

Blog

MySQL can't specify target table for update in FROM clause

If you are a developer or DB administrator it's a common situation that you need to update MySQL table , for example to set user statuses depending on Id column.

Let's say that we need to unvalidate users with Id < 100. If you try to run the following query:

update Users set Valid = 0
where Id in (
  select Id from Users where Id < 100
)

You'll get the error message:

#1093 - You can't specify target table 'xxx' for update in FROM clause

"Your Gmail address has been created" Email Explained

"Your Gmail address, xxxxxxxx@gmail.com, has been created" email

If you have Gmail account you could receive an email with the following content (or similar):

Your Gmail address, xxxxxxxx@gmail.com, has been created

Congratulations on creating your brand new Gmail address,xxxxxxxx@gmail.com.
Please keep this email for your records, as it contains animportant verification code that you may need should you everencounter problems or forget your password.

You can login to your account at http://mail.google.com/

Enjoy!

SQL Server - Collation Conflict

Collation conflicts in SQL Server

If you try to compare values or insert new records into a table from another table from another database with different collation you could get some of the following errors:

"Cannot resolve the collation conflict between "SQL_Latin1_General_CP1250_CI_AS" and "SQL_Latin1_General_CP1_CI_AS" in the equal to operation."

"Cannot resolve collation conflict for equal to operation."

SQL Server - SQLCMD Utility

What is sqlcmd utility

The sqlcmd utility lets you enter Transact-SQL statements, system procedures, and script files at the command prompt, in Query Editor in SQLCMD mode, in a Windows script file or in an operating system (Cmd.exe) job step of a SQL Server Agent job. This utility uses ODBC to execute Transact-SQL batches.

Start and Stop Scripts For XAMPP

After installing XAMPP on your computer you could experience some of the following messages during startup:

XAMPP: Another web server daemon is already running.

XAMPP: Another MySQL daemon is already running.

XAMPP: Another FTP daemon is already running.