 |
| MySQL General discussion about the MySQL database. |
Welcome to the p2p.wrox.com Forums.
You are currently viewing the MySQL section of the Wrox Programmer to Programmer discussions. This is a community of software programmers and website developers including Wrox book authors and readers. New member registration was closed in 2019. New posts were shut off and the site was archived into this static format as of October 1, 2020. If you require technical support for a Wrox book please contact http://hub.wiley.com
|
|
|
|

July 28th, 2006, 12:23 AM
|
|
Registered User
|
|
Join Date: Jul 2006
Posts: 5
Thanks: 0
Thanked 0 Times in 0 Posts
|
|
sql query i need
Hello guys ,
I need sql query to get the first field values without specifying the name of that field, i also don't want to use fetch_array,fetch_row like mysql concepts over here.
Anybody please provide me ASAP
|
|

July 28th, 2006, 12:25 AM
|
|
Registered User
|
|
Join Date: Jul 2006
Posts: 5
Thanks: 0
Thanked 0 Times in 0 Posts
|
|
i need the result within today, atleast say it is possible or not.
|
|

July 29th, 2006, 02:27 AM
|
|
Authorized User
|
|
Join Date: Mar 2006
Posts: 22
Thanks: 0
Thanked 0 Times in 0 Posts
|
|
Dear Seearam,
Write in detail about your prbolem. So that it will be easy for all to have atlest a sketch.
We WILL...
Best regards
Milind
|
|

July 29th, 2006, 08:57 AM
|
|
Registered User
|
|
Join Date: Jul 2006
Posts: 5
Thanks: 0
Thanked 0 Times in 0 Posts
|
|
Hi guys,
I will give the explanation regarding sql query :
assume a table (user) having fields :
user_name,pass_word,ranking.
i need sql query to get the values of the user_name, without specifying user_name in the sql query.
like "select user_name from user"; this one i dont want , i need is there any query to get user_name values without specifying field name.
|
|

August 28th, 2006, 11:06 PM
|
|
Authorized User
|
|
Join Date: Mar 2005
Posts: 25
Thanks: 0
Thanked 0 Times in 0 Posts
|
|
Quote:
quote:Originally posted by seearam
Hi guys,
I will give the explanation regarding sql query :
assume a table (user) having fields :
user_name,pass_word,ranking.
i need sql query to get the values of the user_name, without specifying user_name in the sql query.
like "select user_name from user"; this one i dont want , i need is there any query to get user_name values without specifying field name.
|
hi,
is it possible for you to user something like below
$sql="select * from user";
$res=mysql_query($sql)
$row=mysql_fetch_array($res);
and now u can fetch your values
echo $row[0]
hope it help if i got you correctly.
Regards
|
|

July 6th, 2007, 05:37 AM
|
|
Registered User
|
|
Join Date: Jul 2006
Posts: 5
Thanks: 0
Thanked 0 Times in 0 Posts
|
|
i dont want php to retrive first feild, i need to specify it in query
|
|

November 20th, 2008, 03:11 AM
|
|
Registered User
|
|
Join Date: Jul 2006
Posts: 5
Thanks: 0
Thanked 0 Times in 0 Posts
|
|
SELECT column_name
FROM information_schema.columns
WHERE table_name = 'tablename'
|
|

November 30th, 2008, 03:14 AM
|
|
Authorized User
|
|
Join Date: Nov 2006
Posts: 13
Thanks: 0
Thanked 0 Times in 0 Posts
|
|
select top(1) from table_name
returns one row
|
|
 |