Consider the following perl code:
#!/usr/bin/perl
use DBD::mysql;
use Data::Dumper;
$dbh = DBI->connect('DBI:mysql:database', 'user', 'password') or die "Can't connect to MySQL";
$sql = "SELECT OdL_ID FROM OdLs LIMIT 1";
$OdL_ID = $dbh->selectrow_array($sql);
print Data::Dumper->Dump([$OdL_ID]);
On my "old" SLES 11 SP4 it returns: $VAR1 = '386379';
On my "new" openSUSE Leap 15.3 it returns: $VAR1 = 386379;
How can I force my "new" openSUSE Leap 15.3 to return a string and not an integer ? Note that I have a lot of perl scripts that have this problem !!
regards Miche
print Dumper($OdL_ID);
. – Polar Bear$dbh->selectrow_array($sql) + 0
if the distinction really matters? It usually doesn't as already mentioned. – Shawn