BookmarkSubscribeRSS Feed
🔒 This topic is solved and locked. Need further help from the community? Please sign in and ask a new question.
ralph_muro
Calcite | Level 5

I was wondering if anyone knows of an issue where a value will be truncated intermittently. If not can anyone tell me what I am doing wrong.

Here is my code to create the table. the sample file I pull the data from is attached

data AccgOUTmsgs;

      infile "C:\data\logs\20130726\SOMEONE_TEST.out" dlm='01'x MISSOVER;

      input

   timeout 10.

   ns_out 9.

   @'35=' outmsgtype :$1.

   @'56=' targetcompid :$30.

   @'11=' clordid :$50.

   @'39=' orderstatus :$1.

   @'55=' symbol :$7.;

  DATETIMEOUT = dhms('01jan1970'd,0,0, timeout);

  FORMAT DATETIMEOUT DATETIME.;

   complete_timeout = cat(of timeout ns_out);

RUN;

OUTPUT shows some of my symbols are being truncated. they should all be USD/JPY but some show as USD/JP. Other examples are U and US. I dont know what is causing this to happen.

timeout,ns_out,outmsgtype,targetcompid,clordid,orderstatus,symbol,DATETIMEOUT,complete_timeout

1374801420,699420767,8,SOMEONE-CCG-1,(4 2780 2),A,USD/JPY,26JUL13:01:17:00,1374801420699420767

1374801420,699518420,8,SOMEONE-CCG-1,(4 2780 2),0,USD/JPY,26JUL13:01:17:00,1374801420699518420

1374801420,900818804,8,SOMEONE-CCG-1,(4 2780 2)C,6,USD/JP,26JUL13:01:17:00,1374801420900818804

1374801420,926842284,8,SOMEONE-CCG-1,(4 2780 2),2,,26JUL13:01:17:00,1374801420926842284

1374801420,927011224,9,SOMEONE-CCG-1,(4 2780 2)C,2,,26JUL13:01:17:00,1374801420927011224

1374801425,934460890,0,SOMEONE-CCG-1,,,,26JUL13:01:17:05,1374801425934460890

1374801420,900818804,8,SOMEONE-CCG-1,(4 2780 2)C,6,USD/JP,26JUL13:01:17:00,1374801420900818804

1374801420,900818804,8,SOMEONE-CCG-1,(4 2780 2)C,6,USD/JP,26JUL13:01:17:00,1374801420900818804

1374801420,900818804,8,SOMEONE-CCG-1,(4 2780 2)C,6,USD/JP,26JUL13:01:17:00,1374801420900818804

1374801420,900818804,8,SOMEONE-CCG-1,(4 2780 2)C,6,USD/JP,26JUL13:01:17:00,1374801420900818804

1374801420,900818804,8,SOMEONE-CCG-1,(4 2780 2)C,6,USD/JP,26JUL13:01:17:00,1374801420900818804

Attached Data File is FIX string with '01' delimiter

thanks

1 ACCEPTED SOLUTION

Accepted Solutions
ballardw
Super User

Default line length that will be read is 256, try adding LRECL=500 (for your example data) to the INFILE statement to read longer lines.

On several of your records the Y in JPY falls in column 257 so that is why you're getting that particular truncation.

View solution in original post

2 REPLIES 2
ballardw
Super User

Default line length that will be read is 256, try adding LRECL=500 (for your example data) to the INFILE statement to read longer lines.

On several of your records the Y in JPY falls in column 257 so that is why you're getting that particular truncation.

ralph_muro
Calcite | Level 5

That did it. thanks for helping with my rookie mistake.

sas-innovate-2024.png

Join us for SAS Innovate April 16-19 at the Aria in Las Vegas. Bring the team and save big with our group pricing for a limited time only.

Pre-conference courses and tutorials are filling up fast and are always a sellout. Register today to reserve your seat.

 

Register now!

How to Concatenate Values

Learn how use the CAT functions in SAS to join values from multiple variables into a single value.

Find more tutorials on the SAS Users YouTube channel.

Click image to register for webinarClick image to register for webinar

Classroom Training Available!

Select SAS Training centers are offering in-person courses. View upcoming courses for:

View all other training opportunities.

Discussion stats
  • 2 replies
  • 482 views
  • 4 likes
  • 2 in conversation