Hi
I want to repalce a field in a txt file on solaris with say 100 records and each record having a total of 10 fields separated by a ~ .
based on the following condition the record should be edited or else the record should be written as it is to a
if the seventh field is 'XX' and if... (2 Replies)
Hi All,
I have two files
file1:
abc,def,ghi,5,jkl,mno
pqr,stu,ghi,10,vwx,xyz
cba,ust,ihg,4,cdu,oqw
file2:
ravi,def,kishore
ramu,ust,krishna
joseph,stu,mike
I need two output files as follows
In my above example, each row in file1 has 6 fields and each row in file2 has 3... (1 Reply)
Hi All,
I have two files
file1:
abc,def,ghi,5,jkl,mno
pqr,stu,ghi,10,vwx,xyz
cba,ust,ihg,4,cdu,oqw
file2:
ravi,def,kishore
ramu,ust,krishna
joseph,stu,mike
I need two output files as follows
In my above example, each row in file1 has 6 fields and each row in file2 has 3... (1 Reply)
Hi All,
I have two files
file1:
abc,def,ghi,5,jkl,mno
pqr,stu,ghi,10,vwx,xyz
cba,ust,ihg,4,cdu,oqw
file2:
ravi,def,kishore
ramu,ust,krishna
joseph,stu,mike
I need two output files as follows
In my above example, each row in file1 has 6 fields and each row in file2 has 3... (3 Replies)
Hi there, I have a csv file with some columns comma sepated like this :
4502-17,PETER,ITA2,LEGUE,92,ME - HALF,23/05/10 15:00
4502-18,CARL,ITA2,LEGUE,96,ME - HALF,20/01/09 14:00
4502-19,OTTO,ITA2,LEGUE,97,ME - MARY,23/05/10 15:00
As you can see the column n. 7 is a timestamp column, I need... (23 Replies)
please help me to edit the second field using awk or sed
i have input file below
aa1001 000001
bb1002 000002
cc1003 000003
so i want the output file like below
aa1001 01
bb1002 02
cc1003 03 (38 Replies)
Hello,
For the input file, I am trying to split those records which have multiple values seperated by '|' in the last input field, into multiple records and each record corresponds to the common input fields + one of the value from the last field.
I was trying with an example on this forum... (4 Replies)
Hello,
I am trying to write a shell script that maintains the health of the passwd file. The goal is to check for duplicate usernames, UID's etc. I am able to find and sort out the UID and login names via awk (which I would like to use), but I can't figure out how to save the record field into a... (1 Reply)
Dear Team,
Can any body help me out to get the filed position of the records post sorting using AWK programming.
Thanks in advance
Example Input:
StudentID col-1 col-2 col-3 col-4
1234 14 10 12 13
1235 10 11 12 13
1236 13 12 11 10 ... (3 Replies)
Hi Friends,
Below is my input file with "|" (pipe) as filed delimiter:
My Input File:
HDR|F1|F2||||F6|F7
I want to inser values in the record for field 4 and field 5.
Expected output
HDR|F1|F2||F4|F5|F6|F7
I am able to append the string to the end of the record, but not in between the... (3 Replies)
Discussion started by: Ajay Venkatesan
3 Replies
LEARN ABOUT SUNOS
csx_parse_cistpl_format
csx_Parse_CISTPL_FORMAT(9F) Kernel Functions for Drivers csx_Parse_CISTPL_FORMAT(9F)NAME
csx_Parse_CISTPL_FORMAT - parse the Data Recording Format tuple
SYNOPSIS
#include <sys/pccard.h>
int32_t csx_Parse_CISTPL_FORMAT(client_handle_t ch, tuple_t *tu, cistpl_format_t *pt);
INTERFACE LEVEL
Solaris DDI Specific (Solaris DDI)
PARAMETERS
ch Client handle returned from csx_RegisterClient(9F).
tu Pointer to a tuple_t structure (see tuple(9S)) returned by a call to csx_GetFirstTuple(9F) or csx_GetNextTuple(9F).
pt Pointer to a cistpl_format_t structure which contains the parsed CISTPL_FORMAT tuple information upon return from this function.
DESCRIPTION
This function parses the Data Recording Format tuple, CISTPL_FORMAT, into a form usable by PC Card drivers.
The CISTPL_FORMAT tuple indicates the data recording format for a device partition.
STRUCTURE MEMBERS
The structure members of cistpl_format_t are:
uint32_t type;
uint32_t edc_length;
uint32_t edc_type;
uint32_t offset;
uint32_t nbytes;
uint32_t dev.disk.bksize;
uint32_t dev.disk.nblocks;
uint32_t dev.disk.edcloc;
uint32_t dev.mem.flags;
uint32_t dev.mem.reserved;
caddr_t dev.mem.address;
uint32_t dev.mem.edcloc;
The fields are defined as follows:
type This field indicates the type of device:
TPLFMTTYPE_DISK
disk-like device
TPLFMTTYPE_MEM
memory-like device
TPLFMTTYPE_VS
vendor-specific device
edc_length This field indicates the error detection code length.
edc_type This field indicates the error detection code type.
offset This field indicates the offset of the first byte of data in this partition.
nbytes This field indicates the number of bytes of data in this partition
dev.disk.bksize This field indicates the block size, for disk devices.
dev.disk.nblocks This field indicates the number of blocks, for disk devices.
dev.disk.edcloc This field indicates the location of the error detection code, for disk devices.
dev.mem.flags This field provides flags, for memory devices. Valid flags are:
TPLFMTFLAGS_ADDR
address is valid
TPLFMTFLAGS_AUTO
automatically map memory region
dev.mem.reserved This field is reserved.
dev.mem.address This field indicates the physical address, for memory devices.
dev.mem.edcloc This field indicates the location of the error detection code, for memory devices.
RETURN VALUES
CS_SUCCESS Successful operation.
CS_BAD_HANDLE Client handle is invalid.
CS_UNKNOWN_TUPLE Parser does not know how to parse tuple.
CS_NO_CARD No PC Card in socket.
CS_NO_CIS No Card Information Structure (CIS) on PC Card.
CS_UNSUPPORTED_FUNCTION No PCMCIA hardware installed.
CONTEXT
This function may be called from user or kernel context.
SEE ALSO csx_GetFirstTuple(9F), csx_GetTupleData(9F), csx_RegisterClient(9F), csx_ValidateCIS(9F), tuple(9S)
PC Card 95 Standard, PCMCIA/JEIDA
SunOS 5.10 24 Jan 1997 csx_Parse_CISTPL_FORMAT(9F)