How Change the name from a database to uppercase letters ?
Posted by: Jvb (---.access.telenet.be)
Date: March 21, 2021 04:26PM

Hello, i use Wampserver on my Windows 10 laptop.

i have a database id222625

i want to change this name to uppercase letters, named ID222625

how i can fix this ? Thanks in advance

Options: ReplyQuote
Re: How Change the name from a database to uppercase letters ?
Posted by: RiggsFolly (Moderator)
Date: March 21, 2021 04:54PM

Not a WAMPServer issue !

However if you mean you have a column in a database table called `id222625` then it is recommended to name all tables and columns with lower case letters.

---------------------------------------------------------------------------------------------
(Windows 10 Pro 64bit) (Wampserver 3.3.4 64bit) Aestan Tray Menu 3.2.5.4
<Apache versions MULTIPE> <PHP versions MULTIPLE> <MySQL Versions MULTIPLE>
<MariaDB versions MULTIPLE> <phpMyAdmin versions MULTIPLE> <MySQL Workbench 8.0.23>

Read The Manuals Apache -- MySQL -- PHP -- phpMyAdmin
Get your Apache/MySQL/mariaDB/PHP ADDONs here from the WAMPServer alternate Repo
-X-X-X- Backup your databases regularly Here is How dont regret it later! Yes even when developing -X-X-X-



Edited 1 time(s). Last edit at 03/21/2021 04:59PM by RiggsFolly.

Options: ReplyQuote
Re: How Change the name from a database to uppercase letters ?
Posted by: Otomatic (Moderator)
Date: March 21, 2021 05:44PM

Hi,

--- Rules for MySQL "object" names: bases, tables, columns, etc.
- Maximum length of 64 characters.
- Some characters (especially space) are either forbidden or discouraged; to avoid all problems, don't use diacritical characters, use letters from a to z, numbers and underscore (_); don't start with a number and adopt a consistent and common case policy for all your objects. (In my humble opinion, the simplest is "all lowercase", but you can adopt the "Proper Name" type, i.e. the first letter in upper case).
- They should not be identical to SQL terms, such as Create, Use, Select, Join, etc.

--- Upper case, lower case ---
The case rules (i.e. the choice between upper and lower case) change with the operating system:
- SQL keywords and column names are case insensitive, i.e. they can be written in either upper or lower case.
- Table and database names are :
-- case sensitive if MySQL is installed on Linux
-- case insensitive if MySQL is installed on Windows
This difference is due to the fact that MySQL stores databases and tables as files, and Windows is case insensitive for file names, while Linux is case sensitive.

Since you can change your host and therefore your operating system, it is best to always consider the names of MySQL objects as sensitive, so that queries work regardless of the operating system.

By using the same rules for the names of variables and PHP files, you can avoid potential errors.

---------------------------------------------------------------
Documentation Apache - Documentation PHP - Documentation MySQL - Wampserver install files & addons

Options: ReplyQuote


Sorry, only registered users may post in this forum.