Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

using backslash in alias on linux does not work [CORE5624] #5890

Closed
firebird-automations opened this issue Sep 25, 2017 · 4 comments
Closed

Comments

@firebird-automations
Copy link
Collaborator

Submitted by: Holger Klemt (klemmo)

a backslash in alias seems to be a problem,

this alias does not work with isql
e:\db.fdb=/db/db.fdb

this alias works fine with isql
e:/db.fdb=/db/db.fdb

aditional Infos from Alex Peshkoff:

This is a bug in aliases parser - slash is replaced to OS-specific slash in alias to resolve,
but not replaced in an alias read from aliases.conf. I.e. if you write
e/db.fdb=/db/db.fdb
both e/db.fdb & e\db.fdb will work from isql

based on my tests, using / in alias definitions can really be used as \ from commandline,
but isql for example on linux needs " around connection string

Entry in aliases.conf

e:/db.fdb=/db/db.fdb

succcessful connections:

root@IFS01:/opt/firebird/bin#⁠ ./isql "127.0.0.1:e/db.fdb" -user SYSDBA -password masterkey
Database: 127.0.0.1:e/db.fdb, User: SYSDBA
SQL> exit;

root@IFS01:/opt/firebird/bin#⁠ ./isql "127.0.0.1:e:\db.fdb" -user SYSDBA -password masterkey
Database: 127.0.0.1:e:\db.fdb, User: SYSDBA
SQL>

Commits: b690f21 6f5be2f c7423fd

@firebird-automations
Copy link
Collaborator Author

Modified by: @AlexPeshkoff

assignee: Alexander Peshkov [ alexpeshkoff ]

@firebird-automations
Copy link
Collaborator Author

Commented by: @AlexPeshkoff

Need in quotes on linux when backslash (\) is used is not firebird but OS feature - shell tries to parse \+char sequences itself and isql receives the result of it, i.e.

localhost bin #⁠ echo "127.0.0.1:e:\db.fdb"
127.0.0.1:e:\db.fdb
localhost bin #⁠ echo 127.0.0.1:e:\db.fdb
127.0.0.1:e:db.fdb

@firebird-automations
Copy link
Collaborator Author

Modified by: @AlexPeshkoff

Version: 4.0 Alpha 1 [ 10731 ]

Version: 3.0.2 [ 10785 ]

@firebird-automations
Copy link
Collaborator Author

Modified by: @AlexPeshkoff

status: Open [ 1 ] => Resolved [ 5 ]

resolution: Fixed [ 1 ]

Fix Version: 2.5.8 [ 10809 ]

Fix Version: 3.0.3 [ 10810 ]

Fix Version: 4.0 Beta 1 [ 10750 ]

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment