Go Back   Access World Forums > Microsoft Access Discussion > Reports

 
Reply
 
Thread Tools Rate Thread Display Modes
Old 05-14-2008, 09:41 AM   #1
sunil3071
Registered User
 
Join Date: May 2008
Posts: 5
Thanks: 0
Thanked 0 Times in 0 Posts
sunil3071 is on a distinguished road
Question report by grouping with substr function

i want to generate report by Grouping, the grouping must be on substr(fieldname,5,3) but the report by default grouping by ascending or decending oder but i want to use group with substr(fieldname,5,3).. anybody plz help me..where to define substr in group option in report...

sunil3071 is offline   Reply With Quote
Old 05-14-2008, 09:48 AM   #2
pbaldy
Wino Moderator
 
pbaldy's Avatar
 
Join Date: Aug 2003
Location: Nevada, USA
Posts: 33,400
Thanks: 13
Thanked 4,125 Times in 4,057 Posts
pbaldy is a splendid one to behold pbaldy is a splendid one to behold pbaldy is a splendid one to behold pbaldy is a splendid one to behold pbaldy is a splendid one to behold pbaldy is a splendid one to behold pbaldy is a splendid one to behold pbaldy is a splendid one to behold
Welcome to the site. Can't you add that as a new field in the query, thus allowing you to group on it in the report?
__________________
Paul
Microsoft Access MVP 2007-2019

To view links or images in signatures your post count must be 10 or greater. You currently have 0 posts.
pbaldy is offline   Reply With Quote
Old 05-15-2008, 07:54 AM   #3
sunil3071
Registered User
 
Join Date: May 2008
Posts: 5
Thanks: 0
Thanked 0 Times in 0 Posts
sunil3071 is on a distinguished road
but is not giving the desire result... i tried using substr function in data but in the group wise report instead of selecting none in ascending/decending option it is automatically ascending the group..how can i disable sorting in grouping wise report...

sunil3071 is offline   Reply With Quote
Old 05-15-2008, 08:08 AM   #4
pbaldy
Wino Moderator
 
pbaldy's Avatar
 
Join Date: Aug 2003
Location: Nevada, USA
Posts: 33,400
Thanks: 13
Thanked 4,125 Times in 4,057 Posts
pbaldy is a splendid one to behold pbaldy is a splendid one to behold pbaldy is a splendid one to behold pbaldy is a splendid one to behold pbaldy is a splendid one to behold pbaldy is a splendid one to behold pbaldy is a splendid one to behold pbaldy is a splendid one to behold
Can you post a sample db that illustrates the problem? I don't think I'm really visualizing what you have/want.
__________________
Paul
Microsoft Access MVP 2007-2019

To view links or images in signatures your post count must be 10 or greater. You currently have 0 posts.
pbaldy is offline   Reply With Quote
Old 05-15-2008, 11:46 PM   #5
sunil3071
Registered User
 
Join Date: May 2008
Posts: 5
Thanks: 0
Thanked 0 Times in 0 Posts
sunil3071 is on a distinguished road
Question

Quote:
Originally Posted by pbaldy View Post
Can you post a sample db that illustrates the problem? I don't think I'm really visualizing what you have/want.
thanx for the reply..

boss i have attached the sample data test.dbf the sorting of gstno is substr(gstno,5,3) i want ot group the gstno with total of price... but he grouping of gstno is based on substr(gstno,5,3) which is required.. r in the same pattern as it is in data file....
Attached Files
File Type: zip TEST.zip (46.3 KB, 85 views)
sunil3071 is offline   Reply With Quote
Old 05-16-2008, 02:59 AM   #6
gemma-the-husky
Super Moderator
 
gemma-the-husky's Avatar
 
Join Date: Sep 2006
Location: UK
Posts: 13,830
Thanks: 56
Thanked 1,032 Times in 998 Posts
gemma-the-husky is a name known to all gemma-the-husky is a name known to all gemma-the-husky is a name known to all gemma-the-husky is a name known to all gemma-the-husky is a name known to all gemma-the-husky is a name known to all
in the query that drives the report add an extra column - not substr

mid(mystring,5,3)

returns a string of 3 chars starting at position 5

if this is supposed to be a number then instead

val(mid(mystring,5,3))

will make it numeric

now you can sort and group on this new field more easily
gemma-the-husky is offline   Reply With Quote
Old 05-16-2008, 07:11 PM   #7
sunil3071
Registered User
 
Join Date: May 2008
Posts: 5
Thanks: 0
Thanked 0 Times in 0 Posts
sunil3071 is on a distinguished road
Question

Quote:
Originally Posted by gemma-the-husky View Post
in the query that drives the report add an extra column - not substr

mid(mystring,5,3)

returns a string of 3 chars starting at position 5

if this is supposed to be a number then instead

val(mid(mystring,5,3))

will make it numeric

now you can sort and group on this new field more easily

dear i have treid this method also but not giving the required result.. but i want the result same pattern as it is in the attached txt file.. in the txt file grouping the based on 'Tin No. ' which is Character field. but i dont think this type of report is possible in access..because people are saying that it is one of the worst databse type with lot of problem.. but may i u r expert in this database can solve this problem.. i f u can plz give me the complete access report file in attachment ur mail to me at bhagat_sunil2000@yahoo.com. thanx a lot.

sunil3071 is offline   Reply With Quote
Old 05-19-2008, 09:00 PM   #8
sunil3071
Registered User
 
Join Date: May 2008
Posts: 5
Thanks: 0
Thanked 0 Times in 0 Posts
sunil3071 is on a distinguished road
Talking

anyone here who can say i am expert in access to solve this problem
dear i have treid this method also but not giving the required result.. but i want the result same pattern as it is in the attached txt file.. in the txt file grouping the based on 'Tin No. ' which is Character field. but i dont think this type of report is possible in access..because people are saying that it is one of the worst databse type with lot of problem.. but may i u r expert in this database can solve this problem.. i f u can plz give me the complete access report file in attachment ur mail to me at bhagat_sunil2000@yahoo.com. thanx a lot.

sunil3071 is offline   Reply With Quote
Reply

Thread Tools
Display Modes Rate This Thread
Rate This Thread:

Forum Jump

Similar Threads
Thread Thread Starter Forum Replies Last Post
Multiple linked images on report ronculbert Reports 0 08-07-2006 06:58 PM
Make report data different from the one in table - Replace function? Ramzess II Reports 4 09-10-2004 06:23 AM
docmd.copyobject = runtime error 2501 plucnik Modules & VBA 8 02-09-2004 02:31 PM
Split Database goaksmith General 4 08-16-2002 07:02 AM
[SOLVED] Function to gather user input to determine a query to send to report PROBLEMS!!! BradTSS Modules & VBA 0 02-15-2002 09:59 AM




All times are GMT -8. The time now is 03:23 AM.


Microsoft Access Help
General
Tables
Queries
Forms
Reports
Macros
Modules & VBA
Theory & Practice
Access FAQs
Code Repository
Sample Databases
Video Tutorials

Featured Forum post


Sponsored Links


Powered by vBulletin®
Copyright ©2000 - 2019, Jelsoft Enterprises Ltd.
(c) copyright 2017 Access World