Focal Point Banner


As of December 1, 2020, Focal Point is retired and repurposed as a reference repository. We value the wealth of knowledge that's been shared here over the years. You'll continue to have access to this treasure trove of knowledge, for search purposes only.

Join the TIBCO Community
TIBCO Community is a collaborative space for users to share knowledge and support one another in making the best use of TIBCO products and services. There are several TIBCO WebFOCUS resources in the community.

  • From the Home page, select Predict: WebFOCUS to view articles, questions, and trending articles.
  • Select Products from the top navigation bar, scroll, and then select the TIBCO WebFOCUS product page to view product overview, articles, and discussions.
  • Request access to the private WebFOCUS User Group (login required) to network with fellow members.

Former myibi community members should have received an email on 8/3/22 to activate their user accounts to join the community. Check your Spam folder for the email. Please get in touch with us at community@tibco.com for further assistance. Reference the community FAQ to learn more about the community.


Focal Point    Focal Point Forums  Hop To Forum Categories  WebFOCUS/FOCUS Forum on Focal Point     [CLOSED]6-digit character count on ALPHA

Read-Only Read-Only Topic
Go
Search
Notify
Tools
[CLOSED]6-digit character count on ALPHA
 Login/Join
 
Member
posted
Is there a better way to remove that automatic character count per line? I'm just grabbing one column from my Stored Procedure ("data"), but if I don't use "DEFINE FILE ADATA/A4000=data", the record has a counter at the beginning of each row. But when I do use DEFINE FILE ADATA/A4000, the text file pads the end with blank spaces to 4000. I can make this smaller than 4000, but some lines will still pad as they're variable lengths. Any help would be appreciated!

-DEFAULT &OUTPUTFormat='ALPHA';

ENGINE SQLMSS SET DEFAULT_CONNECTION Database

SQL SQLMSS EX [WebReport].[dbo].[SP_Name] 'ClientLogin';

SET CENT-ZERO = ON
SET NODATA=' ';
SET DROPBLNKLINE=ON
SET BYDISPLAY=ON

TABLE FILE SQLOUT
PRINT
data
ON TABLE HOLD AS HDATA
END

-*Removes 6-digit character-count from beginning of each row
DEFINE FILE HDATA
ADATA/A4000=data
END

TABLE FILE HDATA
PRINT
ADATA

ON TABLE PCHOLD FORMAT '&OUTPUTFormat.().Output Format.'
ON TABLE SET LINES 999999
ON TABLE SET PAGE NOLEAD
ON TABLE NOTOTAL
ON TABLE SET HTMLCSS ON
END

This message has been edited. Last edited by: <Emily McAllister>,


WebFOCUS 8
Windows, All Outputs
 
Posts: 4 | Registered: October 19, 2016Report This Post
Member
posted Hide Post
Nevermind, it's padding spaces to the end regardless of the Define. How do I stop the file from padding? Or can I RTRIM spaces?

Thanks!


WebFOCUS 8
Windows, All Outputs
 
Posts: 4 | Registered: October 19, 2016Report This Post
Expert
posted Hide Post
Try SQL SQLMSS SET VARCHAR OFF instead of double data handling to remove the 6 digits at the beginning of your data string.

T



In FOCUS
since 1986
WebFOCUS Server 8.2.01M, thru 8.2.07 on Windows Svr 2008 R2  
WebFOCUS App Studio 8.2.06 standalone on Windows 10 
 
Posts: 5694 | Location: United Kingdom | Registered: April 08, 2004Report This Post
Master
posted Hide Post
you can try using a variable length field. field/A4000V. Technically the file will still retain all 4000 spaces as WebFOCUS doesn't have a true variable field type, but the field will record the length of the data and there by not show trailing spaces in the output. If you still have issues with trailing spaces, that means that the field in the database was recorded with trailing spaces. Then you would need to use a trim function on the field. There are examples in the help file for the function.


Eric Woerle
8.1.05M Gen 913- Reporting Server Unix
8.1.05 Client Unix
Oracle 11.2.0.2
 
Posts: 750 | Location: Warrenville, IL | Registered: January 08, 2013Report This Post
Member
posted Hide Post
Thanks guys, I ended up switching to "FORMAT DFIX DELIMITER ' ' HEADER NO". Fortunately I only have one field.


WebFOCUS 8
Windows, All Outputs
 
Posts: 4 | Registered: October 19, 2016Report This Post
  Powered by Social Strata  

Read-Only Read-Only Topic

Focal Point    Focal Point Forums  Hop To Forum Categories  WebFOCUS/FOCUS Forum on Focal Point     [CLOSED]6-digit character count on ALPHA

Copyright © 1996-2020 Information Builders