SUBSTRING in query

This is a discussion on "SUBSTRING in query" within the Databases section. This forum, and the thread "SUBSTRING in query are both part of the Program Your Website category.



Go Back   Webforumz.com > Main Forums > Program Your Website > Databases

Notices


Reply
 
LinkBack Thread Tools
  #1 (permalink)  
Old Oct 11th, 2006, 19:23
New Member
Join Date: Sep 2005
Posts: 4
Thanks: 0
Thanked 0 Times in 0 Posts
SUBSTRING in query

This is a query-of-query in ColdFusion and MSAccess
This works ok
<cfquery name="session.getAlpha" dbtype="query">
select distinct signerName
from session.getSigs
</cfquery>
Instead, I would like to select just the "first letter" of signerName in alphabetical order:
<cfquery name="session.getAlpha" dbtype="query">
select distinct substring(signerName,1,1) as alpha
from session.getSigs
orderby alpha
</cfquery>
and it fails. This is giving me a rough time, im just not making the query right ...
Any help much appreciated!
Reply With Quote

Reply

Tags
substring

Thread Tools

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On

Similar Threads
Thread Thread Starter Forum Replies Last Post
Nav bar query Scottie Starting Out 10 Jun 9th, 2008 21:23
Substring Problem daithi Other Programming Languages 4 Aug 30th, 2007 12:15
query about my $query ziggi PHP Forum 9 Aug 10th, 2007 14:05
MySQL query query dangergeek Databases 3 Apr 12th, 2007 12:45
Query accessman Databases 0 Sep 22nd, 2005 19:48


All times are GMT. The time now is 12:14.


Powered by vBulletin®
Copyright ©2000 - 2008, Jelsoft Enterprises Ltd.
Search Engine Friendly URLs by vBSEO 3.2.0 RC8
© 2003-2008 Webforumz.com : All Rights Reserved

1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43