/ Check-in [e5169f9a]
Login

Many hyperlinks are disabled.
Use anonymous login to enable hyperlinks.

Overview
Comment:Enhance sqlite3_analyzer so that it is able to deal with multiplexed databases that have 8+3 filenames.
Downloads: Tarball | ZIP archive | SQL archive
Timelines: family | ancestors | descendants | both | trunk
Files: files | file ages | folders
SHA1: e5169f9a5b7e20b8adaf6ebb7868a64e44fd7321
User & Date: drh 2011-10-10 16:06:35
Context
2011-10-11
12:39
Fix requirements marks associate with STAT3. check-in: 9325c1a8 user: drh tags: trunk
2011-10-10
16:06
Enhance sqlite3_analyzer so that it is able to deal with multiplexed databases that have 8+3 filenames. check-in: e5169f9a user: drh tags: trunk
12:04
Fix a typo in a comment for PRAGMA journal_mode. Also amplify that same comment. check-in: c8ff2a48 user: drh tags: trunk
Changes
Hide Diffs Unified Diffs Ignore Whitespace Patch

Changes to tool/spaceanal.tcl.

39
40
41
42
43
44
45



















46
47
48
49
50
51
52
  exit 1
}
set true_file_size [file size $file_to_analyze]
if {$true_file_size<512} {
  puts stderr "Empty or malformed database: $file_to_analyze"
  exit 1
}




















# Open the database
#
sqlite3 db $file_to_analyze
register_dbstat_vtab db

db eval {SELECT count(*) FROM sqlite_master}







>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>







39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
  exit 1
}
set true_file_size [file size $file_to_analyze]
if {$true_file_size<512} {
  puts stderr "Empty or malformed database: $file_to_analyze"
  exit 1
}

# Compute the total file size assuming test_multiplexor is being used.
# Assume that SQLITE_ENABLE_8_3_NAMES might be enabled
#
set extension [file extension $file_to_analyze]
set pattern $file_to_analyze
append pattern {[0-9][0-9]}
foreach f [glob -nocomplain $pattern] {
  incr true_file_size [file size $f]
  set extension {}
}
if {[string length $extension]>=2 && [string length $extension]<=4} {
  set pattern [file rootname $file_to_analyze]
  append pattern [string range $extension 0 1]
  append pattern {[0-9][0-9]}
  foreach f [glob -nocomplain $pattern] {
    incr true_file_size [file size $f]
  }
}

# Open the database
#
sqlite3 db $file_to_analyze
register_dbstat_vtab db

db eval {SELECT count(*) FROM sqlite_master}