consider columns
name,sname,id. i want id to be first in mysql
Shaswat
0
Newbie Poster
Recommended Answers
Jump to PostIn a database, the order of the columns in the table is TOTALLY irrelevant. The same is true for the order of the rows. This is an important basic concept in relational databases.
In other words it just doesn't matter at all, you write your query and STATE the …
Jump to PostHi, According to me you want output like that form table
"SELECT id,name,sname FROM Table_name";
But I have doubt in mention query, then please mention your query in proper way,Only then I'll Help you, with efficient way.
Jump to PostFor that qyery you follow the concept of Alias, & here I mention a simple sql query,
"SELECT First_Name AS F_Name, Last_Name AS L_Name, Annual_Salary Package From Table_Name";
note here we use AS Keyword, but that's not Compulsory see carefully that Query.
All 9 Replies
hirenpatel53
-1
Posting Whiz in Training
Shaswat
0
Newbie Poster
Shaswat
0
Newbie Poster
drjohn
56
Posting Pro in Training
Shaswat
0
Newbie Poster
Shaswat
0
Newbie Poster
ichigo_cool
-4
Junior Poster
sandeepji1
0
Newbie Poster
sandeepji1
0
Newbie Poster
Be a part of the DaniWeb community
We're a friendly, industry-focused community of developers, IT pros, digital marketers, and technology enthusiasts meeting, networking, learning, and sharing knowledge.