Flat Files

Hi,
I have created a flat file schema with record length of about 80.
I mapped the some string with the fields defined in the schema structure.When I tried to convert the schema document into string
using pub.flatFile:convertToString i got the error like this…
“com.wm.ff.parse.StorageException: [FFP.0015.0005] Specified an invalid schema scenario1:scenarioFlatFixedSchemaDT, is not a Flat File Schema” what would be the problem?
please help me…

parani ,

    i think u have created flat file schema right ,  have u tested that schema in creation schema level itself . if there it works then it works even in flows .. try this and give me feed back.

ya i tried that too muneer
there is no problem with the mapping of string field with the schema fields,i think the exception is due to this service pub.flatFile:convertToString ,how could i get rid out of it…

give me clear cut information about the process , i mean to say why u have created ffile and why u want to convert to string …

   i tell u one thing what ever the data u have in ffile are consider as string then why u need to converttoString again..

istead of giving schema in service in ur giving dt values …
if that currect fine then we will see…

Parani,

You should pass the FF Schema not the DT(flatfileDocument)in the convertToString.since i have noticed you are using scenarioFlatFixedSchemaDT.Please make sure you are doing right.

HTH,
RMG.

1 Like

hi all,
once again i clearly explain my scenario.
I retrived some records from the Oracle table.Each record consists of eno(number),ename(string),sal(number) and doj(date) fields.I want to convert this records into a single string.
for example record 1: 1 dani 3000 11-03-2005
record 2: 2 sam 4000 11-03-2005
i want the result to be dani300011-03-2005sam400011-03-2005*
that is the reason why i chose flat file concepts.
and i am working with that one got it.
if any one faced this kind of problem let me know ur experience
thanks rmg & muneer

I got error message such as "com.wm.ff.parse.StorageException: [FFP.0015.0005] Specified an invalid schema EDIFFSchema.UNEDIFACT.V96A:TPRICAT, is not a Flat File Schema "
during execuing wm.b2b.edi:convertToString service after the validation check of TPRICAT. What’s wrong?
Thank your help.

Hi All,

I’m facing some problem in getting the records form Oracle database to flatfile.
I have created a ffSchema and in that i have specified the delimeter and created record definition as well as field definition.
and iam using the services
select service to select the tables,
convertToString,
but the main problem is iam getting only RECORD DEFINITION, i’am not getting field definition in the output.
My point is that flatfileschema is sufficient or shall i create a flatfile dictionary.
if any one has done the scenerio plz guide me.

thanks,

Hi All,

I’m working on webMethods6.1 using flatfile schema i retrieved the records from the oracle database and written in a flatfile, but the field which is a date is missing in the flatfile.
plz guide me if anyone knows the problem.

Thanks,

hi
i need to create a flat file schema ,can any one please guide me in this regard,after that i need to read records from the flat file
the flat file is like
1kiran1000
2ramus2000
3rajas3000

the flat file is like a fixed length of 10 and it has three records

Kiran,

Create your record in the Dictionary.
Then in the Schema set it as the default record.
See Marks’ response in this post [url=“wmusers.com”]wmusers.com.

HTH,
RMG

HI
i have a problem in creating a schema for a flat file of variable length, can any one help me in this regard…
i am giving the sample format of the flatfile ,so have a look at let me know how to write the schema:

Record 1 12kiran25abc

field 1 is 12 (length of the record), field 2 is kiran (name of the employee) field 3 is abc(dept)

Record 2 25rajeshflatno:45,hyddefg
field 1 is 25(length of the record) field 2 is rajesh(name of the employee) field 3 is flatno:45,hyd (address) and field 4 is defg (dept)

so if these are the two records in a flat file then how to write a flat file schema

i will be great ful for your response

thanks
praveen

Hi ,
i have a small doubt , i am placing it in front of you people , please help me in this regard.How to and when to use the option variable length in the flat file schema structure tab.when using this option how should the flatfile look like ,can any one give me an example of the flatfile for which we have to use this option and how to use that option

I will be greatful for you response

thanks
praveen

We have a schema whose properties are as specified below

Flat file Definition:

Record Parser: Delimiter
Record Delimiter: newline
Record Identifier: Starts at Position “0”.

Fields in the record are defined as fixed length, i.e. their Extractor property is set as

“Fixed Length”. We have certain fields which has subfields in it. Hence we have declared

those fields as Composite. The extractor property of these subfields is also set as "Fixed

Length".

But the extractor property of the Composite field which contains the subfields declared

under it has no option to set Extractor has “Fixed Length”. The only option available in the

Extractor property of this composite field is “Nth Field”.

When we run the schema setting the value in “Nth field” of the composite field, it is not

recognizing the composite field.

Please clarify how to use the composite fields for the fixed length fields.

Hi,
How can we assign the values for composite fields in Flat file schema.
how can we receive the Flat file from the FTP site.i.e to get the flat file which was sent by FTP.
Pls help me.
Regards,
viji.

Vijaya,

Assign the composite fields in the Dictionary and reference those in the schema and if you put the flatfile.txt from ftp site or filepoller the webMethods receive service input should be defined as ffdata (stream object)then convert it using streamTobytes and bytesToString for parsing the filefile.

Please search in this site for more information on transporting flatfiles via ftp site or filepolling mechanism.

HTH,
RMG

Hi,

I have a flat file that I need to transform into an XML Structure. The file is an invoice. For an invoice I may have multiple pages. for each page I may have multiple record type. Until their I’m fine.

See in attachement the actual Flat file

Flat File
\Caqbmonta-ss-23\d\WMAlpha\Out\inv_12805622.ds (1.6 k)

		 and a screen shot of the Flat file record [img]http://www.wmusers.com/wmusers/messages/117/50276.jpg[/img] 

The first 3 caracters are the record type…
The logical structure of the file is:
One ENT record per file.
At least one PAG per file.
In eache PAG you may find any PRO or COM record in any order and they cand be mixed up, the last record of a PAG record is a FOO record.

My issue is that anything in a page (PAG) HAVE TO keep the same order in the XML structure as in the flat file. Can you tell me how I should do the mapping into a XML format to keep the right order?

Thanks

Serge,

How is your target XML sturcture looks like?

My issue is that anything in a page (PAG) HAVE TO keep the same order in the XML structure as in the flat file. Can you tell me how I should do the mapping into a XML format to keep the right order?

This depends on the XML structure how the PAG mapping structures build.

HTH,
RMG

RMG,

The XML Structure looks like this:

All the tags in the pages tag are optional!

Thanks