Perl Programming
 
Forums: » Register « |  User CP |  Games |  Calendar |  Members |  FAQs |  Sitemap |  Support | 
User Name:
Password:
Remember me
Go Back   Dev Shed ForumsProgramming LanguagesPerl Programming

Reply
Add This Thread To:
  Del.icio.us   Digg   Google   Spurl   Blink   Furl   Simpy   Y! MyWeb 
Thread Tools Search this Thread Rate Thread Display Modes
 
Unread Dev Shed Forums Sponsor:
Stop making mediocre tutorials.The best tutorials are video! Camtasia Studio makes it easy to create engaging, buzz-building screen videos at any size, in any popular format. Download the free trial!
  #46  
Old April 24th, 2008, 06:33 PM
keath's Avatar
keath keath is offline
!~ /m$/
Dev Shed Frequenter (2500 - 2999 posts)
 
Join Date: May 2004
Location: Leawood, Kansas
Posts: 2,513 keath User rank is Colonel (50000 - 60000 Reputation Level)keath User rank is Colonel (50000 - 60000 Reputation Level)keath User rank is Colonel (50000 - 60000 Reputation Level)keath User rank is Colonel (50000 - 60000 Reputation Level)keath User rank is Colonel (50000 - 60000 Reputation Level)keath User rank is Colonel (50000 - 60000 Reputation Level)keath User rank is Colonel (50000 - 60000 Reputation Level)keath User rank is Colonel (50000 - 60000 Reputation Level)keath User rank is Colonel (50000 - 60000 Reputation Level)keath User rank is Colonel (50000 - 60000 Reputation Level)keath User rank is Colonel (50000 - 60000 Reputation Level)keath User rank is Colonel (50000 - 60000 Reputation Level) 
Time spent in forums: 1 Week 4 Days 9 h 9 m
Reputation Power: 527
Your answer wasn't clear to me.

The $row{'column3'} has to match the name of the real column you want to split. Otherwise, it will fail to find any data.
Code:
#!/usr/bin/perl
use strict;
use warnings;
use Data::Dumper;
use CGI qw/:standard *table/;
use CGI::Carp qw/fatalsToBrowser/;

print header, start_html, start_table;

my $file = 'tsv_parse.tsv';

{
	#local $/ = "\r\n"; #not for you
	open my $fh, "<", $file or die "Can't open $file: $!";
	my $header = <$fh>;
	chomp $header;
	my @head = split /\t/, $header;
	#print Dumper \@head;
	
	while (<$fh>) {
		chomp;
		my %row;
		@row{@head} = split /\t/;
		$row{'column3'} =~ s/"//g;
		print h3('ready to split');
		my @separators = map {ord($_)} $row{'column3'} =~ m/[^A-Za-z0-9, ]/g;
		print table(Tr(td(@separators)));
		
		print start_table;
		my @repeat = split /\n/, $row{'column3'};
		foreach (@repeat) {
			my @data = map {$row{$_} || undef} @head;
			$data[2] = $_;
			print Tr(td(@data)) if $_ !~ /^\s*$/;
		}
		print end_table;
	}
}

print end_html;

In this version, following the 'ready to split', you should see a line of data. On my computer, all the values are 10. Do you see anything different?

Edit: I'm using the tab separated file still. It works for me. The CSV module barfed on the file you provided. May have been because of the embedded new lines.

Last edited by keath : April 24th, 2008 at 06:36 PM.

Reply With Quote
  #47  
Old April 24th, 2008, 06:47 PM
electron_89 electron_89 is offline
Contributing User
Dev Shed Newbie (0 - 499 posts)
 
Join Date: Aug 2006
Posts: 83 electron_89 User rank is Just a Lowly Private (1 - 20 Reputation Level) 
Time spent in forums: 18 h 18 m 21 sec
Reputation Power: 2
yeah all occurrences of those data in one cell are on column 3.
i tried both files with this code and what happened was

TSV outputted 4 lines of 'ready to split'
CSV outputted 5 lines of 'ready to split'

thx

Quote:
Originally Posted by keath
Your answer wasn't clear to me.

The $row{'column3'} has to match the name of the real column you want to split. Otherwise, it will fail to find any data.
Code:
#!/usr/bin/perl
use strict;
use warnings;
use Data::Dumper;
use CGI qw/:standard *table/;
use CGI::Carp qw/fatalsToBrowser/;

print header, start_html, start_table;

my $file = 'tsv_parse.tsv';

{
	#local $/ = "\r\n"; #not for you
	open my $fh, "<", $file or die "Can't open $file: $!";
	my $header = <$fh>;
	chomp $header;
	my @head = split /\t/, $header;
	#print Dumper \@head;
	
	while (<$fh>) {
		chomp;
		my %row;
		@row{@head} = split /\t/;
		$row{'column3'} =~ s/"//g;
		print h3('ready to split');
		my @separators = map {ord($_)} $row{'column3'} =~ m/[^A-Za-z0-9, ]/g;
		print table(Tr(td(@separators)));
		
		print start_table;
		my @repeat = split /\n/, $row{'column3'};
		foreach (@repeat) {
			my @data = map {$row{$_} || undef} @head;
			$data[2] = $_;
			print Tr(td(@data)) if $_ !~ /^\s*$/;
		}
		print end_table;
	}
}

print end_html;

In this version, following the 'ready to split', you should see a line of data. On my computer, all the values are 10. Do you see anything different?

Edit: I'm using the tab separated file still. It works for me. The CSV module barfed on the file you provided. May have been because of the embedded new lines.

Reply With Quote
  #48  
Old April 24th, 2008, 06:48 PM
electron_89 electron_89 is offline
Contributing User
Dev Shed Newbie (0 - 499 posts)
 
Join Date: Aug 2006
Posts: 83 electron_89 User rank is Just a Lowly Private (1 - 20 Reputation Level) 
Time spent in forums: 18 h 18 m 21 sec
Reputation Power: 2
i am using the same file as i sent you and the "column3" as the name is being used. now i understand what you were asking.

Quote:
Originally Posted by electron_89
yeah all occurrences of those data in one cell are on column 3.
i tried both files with this code and what happened was

TSV outputted 4 lines of 'ready to split'
CSV outputted 5 lines of 'ready to split'

thx

Reply With Quote
  #49  
Old April 24th, 2008, 06:53 PM
keath's Avatar
keath keath is offline
!~ /m$/
Dev Shed Frequenter (2500 - 2999 posts)
 
Join Date: May 2004
Location: Leawood, Kansas
Posts: 2,513 keath User rank is Colonel (50000 - 60000 Reputation Level)keath User rank is Colonel (50000 - 60000 Reputation Level)keath User rank is Colonel (50000 - 60000 Reputation Level)keath User rank is Colonel (50000 - 60000 Reputation Level)keath User rank is Colonel (50000 - 60000 Reputation Level)keath User rank is Colonel (50000 - 60000 Reputation Level)keath User rank is Colonel (50000 - 60000 Reputation Level)keath User rank is Colonel (50000 - 60000 Reputation Level)keath User rank is Colonel (50000 - 60000 Reputation Level)keath User rank is Colonel (50000 - 60000 Reputation Level)keath User rank is Colonel (50000 - 60000 Reputation Level)keath User rank is Colonel (50000 - 60000 Reputation Level) 
Time spent in forums: 1 Week 4 Days 9 h 9 m
Reputation Power: 527
Please note my edit above. I'm not using the file you sent. I had to revert to the tab delimited version.

Use a TSV file, and see what the result is. Are yo seeing 10s in the one line, and are you getting any other output below that?

This is what I'm getting:
Code:
ready to split

10 10 10 10
data1 data2 VISHAY BC COMPONENTS, 2222036 Rule Based Upgrades data4 data5 data6 data7 data8 data9 data10 data11 data12 data13 data14 data15 data16
data1 data2 VISHAY BC COMPONENTS, 2222048 Rule Based Upgrades data4 data5 data6 data7 data8 data9 data10 data11 data12 data13 data14 data15 data16
data1 data2 VISHAY BC COMPONENTS, 2222116 Rule Based Upgrades data4 data5 data6 data7 data8 data9 data10 data11 data12 data13 data14 data15 data16
data1 data2 VISHAY BC COMPONENTS, 2222151 Rule Based Upgrades data4 data5 data6 data7 data8 data9 data10 data11 data12 data13 data14 data15 data16

Reply With Quote
  #50  
Old April 24th, 2008, 07:00 PM
electron_89 electron_89 is offline
Contributing User
Dev Shed Newbie (0 - 499 posts)
 
Join Date: Aug 2006
Posts: 83 electron_89 User rank is Just a Lowly Private (1 - 20 Reputation Level) 
Time spent in forums: 18 h 18 m 21 sec
Reputation Power: 2
i had to save as tsv again and changed the extension to "tsv" like you did. that gave me this instead of just "ready to split":

Code:
ready to split  
data1 data2 VISHAY BC COMPONENTS, 2222036 Rule Based Upgrades  

ready to split
 

ready to split
 

ready to split
 

ready to split
 
" data4 data5 data6 data7 data8 data9 data10 data11 data12 data13 data14 data15 data16  

 

Quote:
Originally Posted by keath
Please note my edit above. I'm not using the file you sent. I had to revert to the tab delimited version.

Use a TSV file, and see what the result is. Are yo seeing 10s in the one line, and are you getting any other output below that?

This is what I'm getting:
Code:
ready to split

10 10 10 10
data1 data2 VISHAY BC COMPONENTS, 2222036 Rule Based Upgrades data4 data5 data6 data7 data8 data9 data10 data11 data12 data13 data14 data15 data16
data1 data2 VISHAY BC COMPONENTS, 2222048 Rule Based Upgrades data4 data5 data6 data7 data8 data9 data10 data11 data12 data13 data14 data15 data16
data1 data2 VISHAY BC COMPONENTS, 2222116 Rule Based Upgrades data4 data5 data6 data7 data8 data9 data10 data11 data12 data13 data14 data15 data16
data1 data2 VISHAY BC COMPONENTS, 2222151 Rule Based Upgrades data4 data5 data6 data7 data8 data9 data10 data11 data12 data13 data14 data15 data16

Reply With Quote
  #51  
Old April 24th, 2008, 07:02 PM
electron_89 electron_89 is offline
Contributing User
Dev Shed Newbie (0 - 499 posts)
 
Join Date: Aug 2006
Posts: 83 electron_89 User rank is Just a Lowly Private (1 - 20 Reputation Level) 
Time spent in forums: 18 h 18 m 21 sec
Reputation Power: 2
what steps should i take to revert the file?

Reply With Quote
  #52  
Old April 24th, 2008, 07:05 PM
keath's Avatar
keath keath is offline
!~ /m$/
Dev Shed Frequenter (2500 - 2999 posts)
 
Join Date: May 2004
Location: Leawood, Kansas
Posts: 2,513 keath User rank is Colonel (50000 - 60000 Reputation Level)keath User rank is Colonel (50000 - 60000 Reputation Level)keath User rank is Colonel (50000 - 60000 Reputation Level)keath User rank is Colonel (50000 - 60000 Reputation Level)keath User rank is Colonel (50000 - 60000 Reputation Level)keath User rank is Colonel (50000 - 60000 Reputation Level)keath User rank is Colonel (50000 - 60000 Reputation Level)keath User rank is Colonel (50000 - 60000 Reputation Level)keath User rank is Colonel (50000 - 60000 Reputation Level)keath User rank is Colonel (50000 - 60000 Reputation Level)keath User rank is Colonel (50000 - 60000 Reputation Level)keath User rank is Colonel (50000 - 60000 Reputation Level) 
Time spent in forums: 1 Week 4 Days 9 h 9 m
Reputation Power: 527
let me see the full output of this script:
Code:
#!/usr/bin/perl
use strict;
use warnings;
use Data::Dumper;
use CGI qw/:standard *table/;
use CGI::Carp qw/fatalsToBrowser/;

print header('text/text'); #, start_html, start_table;

my $file = 'tsv_parse.tsv';

{
	#local $/ = "\r\n"; #not for you
	open my $fh, "<", $file or die "Can't open $file: $!";
	my $header = <$fh>;
	chomp $header;
	my @head = split /\t/, $header;
	print Dumper \@head;
	
	while (<$fh>) {
		chomp;
		my %row;
		@row{@head} = split /\t/;
		$row{'column3'} =~ s/"//g;
		print Dumper \%row;
		
		print h3('ready to split');
		my @separators = map {ord($_)} $row{'column3'} =~ m/[^A-Za-z0-9, ]/g;
		#print table(Tr(td(@separators)));
		print Dumper \@separators;
		
		#print start_table;
		my @repeat = split /\n/, $row{'column3'};
		print Dumper \@repeat;
		
		#foreach (@repeat) {
		#	my @data = map {$row{$_} || undef} @head;
		#	$data[2] = $_;
		#	print Tr(td(@data)) if $_ !~ /^\s*$/;
		#}
		#print end_table;
	}
}

#print end_html;

Put it in CODE tags to preserve the formatting.

Reply With Quote
  #53  
Old April 24th, 2008, 07:08 PM
keath's Avatar
keath keath is offline
!~ /m$/
Dev Shed Frequenter (2500 - 2999 posts)
 
Join Date: May 2004
Location: Leawood, Kansas
Posts: 2,513 keath User rank is Colonel (50000 - 60000 Reputation Level)keath User rank is Colonel (50000 - 60000 Reputation Level)keath User rank is Colonel (50000 - 60000 Reputation Level)keath User rank is Colonel (50000 - 60000 Reputation Level)keath User rank is Colonel (50000 - 60000 Reputation Level)keath User rank is Colonel (50000 - 60000 Reputation Level)keath User rank is Colonel (50000 - 60000 Reputation Level)keath User rank is Colonel (50000 - 60000 Reputation Level)keath User rank is Colonel (50000 - 60000 Reputation Level)keath User rank is Colonel (50000 - 60000 Reputation Level)keath User rank is Colonel (50000 - 60000 Reputation Level)keath User rank is Colonel (50000 - 60000 Reputation Level) 
Time spent in forums: 1 Week 4 Days 9 h 9 m
Reputation Power: 527
Quote:
what steps should i take to revert the file?

Ideally, just open Excel again and save as tab-delimited.

Reply With Quote
  #54  
Old April 24th, 2008, 07:08 PM
electron_89 electron_89 is offline
Contributing User
Dev Shed Newbie (0 - 499 posts)
 
Join Date: Aug 2006
Posts: 83 electron_89 User rank is Just a Lowly Private (1 - 20 Reputation Level) 
Time spent in forums: 18 h 18 m 21 sec
Reputation Power: 2
Code:
$VAR1 = [
          'column1',
          'column2',
          'column3',
          'column4',
          'column5',
          'column6',
          'column7',
          'column8',
          'column9',
          'column10',
          'column11',
          'column12',
          'column13',
          'column14',
          'column15',
          'column16
'
        ];
$VAR1 = {
          'column16
' => undef,
          'column1' => 'data1',
          'column2' => 'data2',
          'column3' => 'VISHAY BC COMPONENTS, 2222036 Rule Based Upgrades',
          'column4' => undef,
          'column5' => undef,
          'column6' => undef,
          'column7' => undef,
          'column8' => undef,
          'column9' => undef,
          'column10' => undef,
          'column11' => undef,
          'column12' => undef,
          'column13' => undef,
          'column14' => undef,
          'column15' => undef
        };
<h3>ready to split</h3>$VAR1 = [];
$VAR1 = [
          'VISHAY BC COMPONENTS, 2222036 Rule Based Upgrades'
        ];
$VAR1 = {
          'column16
' => undef,
          'column1' => 'VISHAY BC COMPONENTS, 2222048 Rule Based Upgrades',
          'column2' => undef,
          'column3' => undef,
          'column4' => undef,
          'column5' => undef,
          'column6' => undef,
          'column7' => undef,
          'column8' => undef,
          'column9' => undef,
          'column10' => undef,
          'column11' => undef,
          'column12' => undef,
          'column13' => undef,
          'column14' => undef,
          'column15' => undef
        };
<h3>ready to split</h3>$VAR1 = [];
$VAR1 = [];
$VAR1 = {
          'column16
' => undef,
          'column1' => 'VISHAY BC COMPONENTS, 2222116 Rule Based Upgrades',
          'column2' => undef,
          'column3' => undef,
          'column4' => undef,
          'column5' => undef,
          'column6' => undef,
          'column7' => undef,
          'column8' => undef,
          'column9' => undef,
          'column10' => undef,
          'column11' => undef,
          'column12' => undef,
          'column13' => undef,
          'column14' => undef,
          'column15' => undef
        };
<h3>ready to split</h3>$VAR1 = [];
$VAR1 = [];
$VAR1 = {
          'column16
' => undef,
          'column1' => 'VISHAY BC COMPONENTS, 2222151 Rule Based Upgrades',
          'column2' => undef,
          'column3' => undef,
          'column4' => undef,
          'column5' => undef,
          'column6' => undef,
          'column7' => undef,
          'column8' => undef,
          'column9' => undef,
          'column10' => undef,
          'column11' => undef,
          'column12' => undef,
          'column13' => undef,
          'column14' => undef,
          'column15' => undef
        };
<h3>ready to split</h3>$VAR1 = [];
$VAR1 = [];
$VAR1 = {
          'column16
' => undef,
          'column1' => ' "',
          'column2' => 'data4',
          'column3' => 'data5',
          'column4' => 'data6',
          'column5' => 'data7',
          'column6' => 'data8',
          'column7' => 'data9',
          'column8' => 'data10',
          'column9' => 'data11',
          'column10' => 'data12',
          'column11' => 'data13',
          'column12' => 'data14',
          'column13' => 'data15',
          'column14' => 'data16
',
          'column15' => undef
        };
<h3>ready to split</h3>$VAR1 = [];
$VAR1 = [
          'data5'
        ];

Reply With Quote
  #55  
Old April 24th, 2008, 07:13 PM
keath's Avatar
keath keath is offline
!~ /m$/
Dev Shed Frequenter (2500 - 2999 posts)
 
Join Date: May 2004
Location: Leawood, Kansas
Posts: 2,513 keath User rank is Colonel (50000 - 60000 Reputation Level)keath User rank is Colonel (50000 - 60000 Reputation Level)keath User rank is Colonel (50000 - 60000 Reputation Level)keath User rank is Colonel (50000 - 60000 Reputation Level)keath User rank is Colonel (50000 - 60000 Reputation Level)keath User rank is Colonel (50000 - 60000 Reputation Level)keath User rank is Colonel (50000 - 60000 Reputation Level)keath User rank is Colonel (50000 - 60000 Reputation Level)keath User rank is Colonel (50000 - 60000 Reputation Level)keath User rank is Colonel (50000 - 60000 Reputation Level)keath User rank is Colonel (50000 - 60000 Reputation Level)keath User rank is Colonel (50000 - 60000 Reputation Level) 
Time spent in forums: 1 Week 4 Days 9 h 9 m
Reputation Power: 527
You said you were running this on Windows, but it looks to me that your web server must by a Unix type.

Uncomment this line and run the script again:
Code:
local $/ = "\r\n";

Reply With Quote
  #56  
Old April 24th, 2008, 07:15 PM
electron_89 electron_89 is offline
Contributing User
Dev Shed Newbie (0 - 499 posts)
 
Join Date: Aug 2006
Posts: 83 electron_89 User rank is Just a Lowly Private (1 - 20 Reputation Level) 
Time spent in forums: 18 h 18 m 21 sec
Reputation Power: 2
Sorry...

Code:
$VAR1 = [
          'column1',
          'column2',
          'column3',
          'column4',
          'column5',
          'column6',
          'column7',
          'column8',
          'column9',
          'column10',
          'column11',
          'column12',
          'column13',
          'column14',
          'column15',
          'column16'
        ];
$VAR1 = {
          'column8' => 'data8',
          'column9' => 'data9',
          'column1' => 'data1',
          'column10' => 'data10',
          'column11' => 'data11',
          'column2' => 'data2',
          'column12' => 'data12',
          'column3' => 'VISHAY BC COMPONENTS, 2222036 Rule Based Upgrades
VISHAY BC COMPONENTS, 2222048 Rule Based Upgrades
VISHAY BC COMPONENTS, 2222116 Rule Based Upgrades
VISHAY BC COMPONENTS, 2222151 Rule Based Upgrades
 ',
          'column13' => 'data13',
          'column4' => 'data4',
          'column14' => 'data14',
          'column5' => 'data5',
          'column15' => 'data15',
          'column6' => 'data6',
          'column16' => 'data16',
          'column7' => 'data7'
        };
<h3>ready to split</h3>$VAR1 = [
          10,
          10,
          10,
          10
        ];
$VAR1 = [
          'VISHAY BC COMPONENTS, 2222036 Rule Based Upgrades',
          'VISHAY BC COMPONENTS, 2222048 Rule Based Upgrades',
          'VISHAY BC COMPONENTS, 2222116 Rule Based Upgrades',
          'VISHAY BC COMPONENTS, 2222151 Rule Based Upgrades',
          ' '
        ];

Quote:
Originally Posted by keath
You said you were running this on Windows, but it looks to me that your web server must by a Unix type.

Uncomment this line and run the script again:
Code:
local $/ = "\r\n";

Reply With Quote
  #57  
Old April 24th, 2008, 07:18 PM
keath's Avatar
keath keath is offline
!~ /m$/
Dev Shed Frequenter (2500 - 2999 posts)
 
Join Date: May 2004
Location: Leawood, Kansas
Posts: 2,513 keath User rank is Colonel (50000 - 60000 Reputation Level)keath User rank is Colonel (50000 - 60000 Reputation Level)keath User rank is Colonel (50000 - 60000 Reputation Level)keath User rank is Colonel (50000 - 60000 Reputation Level)keath User rank is Colonel (50000 - 60000 Reputation Level)keath User rank is Colonel (50000 - 60000 Reputation Level)keath User rank is Colonel (50000 - 60000 Reputation Level)keath User rank is Colonel (50000 - 60000 Reputation Level)keath User rank is Colonel (50000 - 60000 Reputation Level)keath User rank is Colonel (50000 - 60000 Reputation Level)keath User rank is Colonel (50000 - 60000 Reputation Level)keath User rank is Colonel (50000 - 60000 Reputation Level) 
Time spent in forums: 1 Week 4 Days 9 h 9 m
Reputation Power: 527
Back to this:
Code:
#!/usr/bin/perl
use strict;
use warnings;
use Data::Dumper;
use CGI qw/:standard *table/;
use CGI::Carp qw/fatalsToBrowser/;

print header, start_html, start_table;

my $file = 'tsv_parse.tsv';

{
	local $/ = "\r\n"; #yes, applies to you too
	open my $fh, "<", $file or die "Can't open $file: $!";
	my $header = <$fh>;
	chomp $header;
	my @head = split /\t/, $header;
	#print Dumper \@head;
	
	while (<$fh>) {
		chomp;
		my %row;
		@row{@head} = split /\t/;
		$row{'column3'} =~ s/"//g;
		#print Dumper \%row;
		
		print h3('ready to split');
		my @separators = map {ord($_)} $row{'column3'} =~ m/[^A-Za-z0-9, ]/g;
		print table(Tr(td(@separators)));
		#print Dumper \@separators;
		
		print start_table;
		my @repeat = split /\n/, $row{'column3'};
		#print Dumper \@repeat;
		
		foreach (@repeat) {
			my @data = map {$row{$_} || undef} @head;
			$data[2] = $_;
			print Tr(td(@data)) if $_ !~ /^\s*$/;
		}
		print end_table;
	}
}

print end_html;

Reply With Quote
  #58  
Old April 24th, 2008, 07:21 PM
electron_89 electron_89 is offline
Contributing User
Dev Shed Newbie (0 - 499 posts)
 
Join Date: Aug 2006
Posts: 83 electron_89 User rank is Just a Lowly Private (1 - 20 Reputation Level) 
Time spent in forums: 18 h 18 m 21 sec
Reputation Power: 2
It WORKS!!! Thank you so much!
I asked earlier before that the comma...is it possible to move that to a new column?

so how do i insert that correctly in a database?

hey Keath, you are staying late at work for this?
i really appreciate this. we can continue tomorrow?
if you are ever in los angeles, let me know, i am in debt to you. expensive dinner and vip treatment on me.

Code:
ready to split 10 10 10 10 
data1 data2 VISHAY BC COMPONENTS, 2222036 Rule Based Upgrades data4 data5 data6 data7 data8 data9 data10 data11 data12 data13 data14 data15 data16 
data1 data2 VISHAY BC COMPONENTS, 2222048 Rule Based Upgrades data4 data5 data6 data7 data8 data9 data10 data11 data12 data13 data14 data15 data16 
data1 data2 VISHAY BC COMPONENTS, 2222116 Rule Based Upgrades data4 data5 data6 data7 data8 data9 data10 data11 data12 data13 data14 data15 data16 
data1 data2 VISHAY BC COMPONENTS, 2222151 Rule Based Upgrades data4 data5 data6 data7 data8 data9 data10 data11 data12 data13 data14 data15 data16