Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
bugzilla
Project
Project
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Registry
Registry
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
Ivan Ivlev
bugzilla
Commits
24ba85e2
Commit
24ba85e2
authored
Aug 23, 2000
by
dave%intrec.com
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Fix for bug 16454: can now run checksetup.pl on databases with passwords.
parent
ff85006b
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
6 additions
and
3 deletions
+6
-3
checksetup.pl
checksetup.pl
+6
-3
No files found.
checksetup.pl
View file @
24ba85e2
...
...
@@ -502,10 +502,12 @@ my $drh = DBI->install_driver($db_base)
if
(
$db_check
)
{
# Do we have the database itself?
my
@databases
=
$drh
->
func
(
$db_host
,
$db_port
,
'_ListDBs'
);
my
$dsn
=
"DBI:$db_base:$db_name;$db_host;$db_port"
;
my
$dbh
=
DBI
->
connect
(
$dsn
,
$db_user
,
$db_pass
);
my
@databases
=
$dbh
->
func
(
'_ListDBs'
);
unless
(
grep
/^$db_name$/
,
@databases
)
{
print
"Creating database $db_name ...\n"
;
$drh
->
func
(
'createdb'
,
$db_name
,
'admin'
)
print
"Creating database $db_name ...\n"
;
$drh
->
func
(
'createdb'
,
$db_name
,
"$db_host:$db_port"
,
$db_user
,
$db_pass
,
'admin'
)
or
die
<<"EOF"
The '$db_name' database is not accessible. This might have several reasons:
...
...
@@ -518,6 +520,7 @@ The '$db_name' database is not accessible. This might have several reasons:
'\$db_check' to zero.\n
EOF
}
$dbh
->
disconnect
if
$dbh
;
}
# now get a handle to the database:
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment