Then how does it comparable with CGI::FastCGI and
what are differences between FastCGI and embperl package?
Which is better?
In what circumastances FastCGI, embperl can be suitable?
Plese give, clear info what to choose?
Thank you inadvance.
-SubbaReddy
--
On Tue, 30 Oct 2001 02:19:31
Can Oracle convert date/time values such as
'03-NOV-2001 15:50' to GMT (or UTC) which for
me is -11 hours from my local time?
I thought I could do this by:
select to_char(date_occurred,'DD-MON- HH24:MI', 'GMT') from report
but I got an invalid NLS parameter error...
Thanks in advance,
I am having some severe difficulties with multiple DBI objects. It seems
that it is not possible to keep two connections alive and functional at
the same time if both use Oracle but with different userids. Ex:
$dbh1 = DBI->connect("dbi:Oracle:host=foo:sid=bar","snark","snarkpw");
$dbh2 = DBI->con
Ilya,
Thank you for that. My INSERT is now working.
Many thanks,
Regards,
Stacy.
"Sterin, Ilya" wrote:
>
> No, the variable can't contain the whole conversion string, since it will be
> bound as a value. Rather do this...
>
> $dbh->do("INSERT INTO $fault_db VALUES (?,?,?,?,?,to_date
See my previous note, and if you look at the trace output you will see the
problem of how the to_date is bounded:-)
Ilya
> -Original Message-
> From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED]]On
> Behalf Of Stacy Mader
> Sent: Saturday, November 03, 2001 12:12 AM
> To: Terrence Brannon
www.mysql.com/doc
Dodger
- Original Message -
From: "Dieter" <[EMAIL PROTECTED]>
To: <[EMAIL PROTECTED]>
Cc: <[EMAIL PROTECTED]>
Sent: Friday, November 02, 2001 7:16 PM
Subject: TYPE integer values and their respective data types
Hello,
i am looking for a complete list of the integer v
Okay,
$dbh->do(qq{
INSERT INTO $fault_db (
FAULT_NO,
REPORTED_BY,
PROJECT_NO,
DATE_OCCURRED,
DATE_REPORTED,
TIME_LOST,
No, the variable can't contain the whole conversion string, since it will be
bound as a value. Rather do this...
$dbh->do("INSERT INTO $fault_db VALUES (?,?,?,?,?,to_date(?,'DD-MON-
HH24:MI'),to_date(?,'DD-MON- HH24:MI'),?,?,?,?,?) ",
undef,
$fault_no,
$reported_by
my %db;
$sth->bind_columns( \( @db{ @{ $sth->{NAME} } } ));# magic
while ($sth->fetch)
{
#... and no worries about which order the columns get returned in
#... since you access them via the $db{ColumnName} method :)
Right, no worries, but a good point to make is tha
The 'Best way' may not be Perl. Is this a one time shot, or something where
the two servers need to interact constantly?
If this is one time, or something that needs to happen only periodically, I
would recommend Data Transformation Services (DTS). That is part of the MS
SQL installation if it is
The users_old table has 120,000 rows and the users_new has 910,000 rows.
If you have no indexes, I'm not at all surprised it takes that long or even
longer to get results from a join on MySQL on two tables with this many
rows. The join must be completed before results are returned, and that is
You need DBD::ODBC to access MS Access using Perl and DBI. It can be
downloaded from CPAN, or if you are using ActiveState, or PPM you can use
them to search, locate download and install this module.
Steve H.
-Original Message-
From: Linda Xu [mailto:[EMAIL PROTECTED]]
Sent: Friday, Nove
On Friday, November 2, 2001, at 06:30 PM, Stacy Mader wrote:
> Thanks for that Jeff.
>
> Now that I have:
>
> $dbh->do("INSERT INTO $fault_db VALUES (?,?,?,?,?,?,?,?,?,?,?,?) ",
> undef,
> $fault_no,
> $reported_by,
> $project_no,
> undef,
> $date_o
Thanks for that Jeff.
Now that I have:
$dbh->do("INSERT INTO $fault_db VALUES (?,?,?,?,?,?,?,?,?,?,?,?) ",
undef,
$fault_no,
$reported_by,
$project_no,
undef,
$date_occurred,
$date_reported,
$time_lost,
Stacy Mader wrote:
>
> $allocated_to = $dbh->quote('NULL');
That's wrong for two reasons: don't use quote() on something that
already has quotes around it unless you want the literal quotes in the
string; and if you mean an actual SQL NULL, it should not be quoted by
either method.
> Can
Hi Linda,
try ODBC option that might work.
Anton
-Original Message-
From: Linda Xu [mailto:[EMAIL PROTECTED]]
Sent: Friday, November 02, 2001 5:42 PM
To: DBI Users
Subject: Does perl has DBD for MS Access?
Hi,
Does perl has DBD for MS Access? Where I can download it?
Linda
Hi,
Does perl has DBD for MS Access? Where I can download it?
Linda
Hi all,
I have the following:
$reported_by = $dbh->quote($reported_by);
$project_no = $dbh->quote($project);
$project_comments = $dbh->quote('NULL');
$one_line_summary = $dbh->quote($one_line_summary);
$issue= $dbh->quote($issue);
$new_report = $dbh->quo
Hello,
i am looking for a complete list of the integer values and their respective data types
returned from the TYPE statement handle attribute.
I followed both links in the 'Programming the Perl DBI book, but they did not lead to
any results.
I am interested in all MySQL data types, especiall
On Fri, Nov 02, 2001 at 02:41:05PM -0500, Scott R. Godin wrote:
> In article <[EMAIL PROTECTED]>,
> [EMAIL PROTECTED] (Tim Bunce) wrote:
>
> > On Fri, Nov 02, 2001 at 02:18:15PM +0100, Bart Lateur wrote:
> > > On Fri, 02 Nov 2001 07:27:49 -0500, Scott R. Godin wrote:
> > >
> > > >my %db;
>
this isn't ontopic for the dbi-list try perl friends or something like
that.
Aaron
On Fri, 2 Nov 2001, Nigel Gall wrote:
> Hi! I'm a new user of PERL and I'm trying to write a script to give me a
> condensed list of file permissions of an NTFS file system. For example, if
> I have a folder na
Hello,
We are migrating our systems from Informix to Oracle. We have a lot of code
written using DBI and DBD::Informix. DBD::informix has something like
ix_sqlcode to return the sqlcode for the operation. Does Oracle have
anything like this or is the status of a database operation just returned i
Hi
You wrote:
Hi! I'm a new user of PERL and I'm trying to write a script to give me a
condensed list of file permissions of an NTFS file system. For example, if
I have a folder named E:\, with a hundred subfolders (and so on), I'd like
to get a list of subfolder names with their associated pe
Hi all,
I am connecting to a DB2 database on an AS/400 using the Client Access
Express ODBC driver (version 6). At times, I will have need to return some
rather large datasets (around 10Mb total). Unfortunately, the CAE driver
only allows the information to be sent in 8Kb segments before it pau
If the query just hangs there in mysql, putting it into DBI is not going to fix
that. Are the columns indexed in the tables? If not, you've probably got it
doing nested full table scans. Try adding indexes to the tables on the join
columns.
Get the query to run in mysql before you ever try it
Hi! I'm a new user of PERL and I'm trying to write a script to give me a
condensed list of file permissions of an NTFS file system. For example, if
I have a folder named E:\, with a hundred subfolders (and so on), I'd like
to get a list of subfolder names with their associated permissions (ACLs)
On Thu, 1 Nov 2001, Ivan Kavuma wrote:
> I am developing an Intranet for my company. We have an oracle
> database version 8i running on another Linux machine. which I
> want to use as a backborn.
Please don't cc the list-owner on mails to the mailinglists.
- ask
--
ask bjoern hansen, http
oops...forgot to change the name from LOG to DATATEMP
my($data_log) = "/home/chastie/sony_showbiz.txt";
open (DATATEMP, ">>$data_log");
flock (DATATEMP, $exclusive_lock);
while($row = $sth->fetchrow_arrayref) {
print DATATEMP "$row->[0]\t$row->[1]\n" or die "Error: $!\n";
}
flock (DATAT
Thanks Marcelo for all three of those points.
I tried performing just the query from mysql, but it just hangs there also,
even if I leave it for an hour!
I've modified the code to stop opening and closing the file in the loop, and
added the lock values, but it's still just running and running and
In article <[EMAIL PROTECTED]>,
[EMAIL PROTECTED] (Michael Peppler) wrote:
> > my $rows = $sth->rows;
> > # only expecting one row for a unique ID . this should NEVER happen.
> >safe_error("invalid number of rows returned from database ($rows) for
> > ID $id")
> > if $rows
In article <[EMAIL PROTECTED]>,
[EMAIL PROTECTED] (Tim Bunce) wrote:
> On Fri, Nov 02, 2001 at 02:18:15PM +0100, Bart Lateur wrote:
> > On Fri, 02 Nov 2001 07:27:49 -0500, Scott R. Godin wrote:
> >
> > >my %db;
> > >$sth->bind_columns( \( @db{ @{ $sth->{NAME} } } ));# magic
> > >
> > >
In article <[EMAIL PROTECTED]>,
[EMAIL PROTECTED] (Tim Bunce) wrote:
>
> There were connect() changes made between DBI 1.14 and 1.15 but I'd need
> people to look into it for me. Should be trivial to debug by enabling
> DBI tracing and Apache::DBi debug.
Unless your admin refuses to run any of
In article <[EMAIL PROTECTED]>,
[EMAIL PROTECTED] (Eric Kolve) wrote:
> I have traced it back to prepare_cached() (at least that is what I
> notice).
>
> Scott, try replacing your calls on startup with prepare() instead of
> prepare_cached().
no, I'm using prepare(). an earlier post thread o
1) Did you try to perform that query from mysql instead of a perl program
to measure the time?
2) Is this code correct? :
open (DATATEMP, ">>$data_log");
flock (DATATEMP, $exclusive_lock);
print LOG "$row->[0]\t$row->[1]\n";
close (LOG);
You never open
Is there any performance issues (or advantages) to using an Oracle Stored
Procedure and receiving a BY REF cursor, compared to a straight SQL
statement?
Thanks,
Matt
What trace level should I use? I figure I can run trace and debug for
when it works and doesn't work; dump to two separate log files and post
to either the group or just send it to you Tim if you have time to look
at it.
thanks,
--eric
Tim Bunce wrote:
>
> But prepare_cached/prepare has noth
Hello to all!
This is my first time posting to this group! But I'm in desperate need of
any help!
(BTW, thanks for all the emails from contributors to this list..I learn a
lot from you guys every day!)
I have two tables in a mySQL db, named users_old and users_new, both with
UserId and Email c
I guess I'm not that concerned with that level of detail. there are a
million different ways to do that part. It was just the part of finding
the groups that I needed help with.
Thanks though.
Don.
On Fri, 2 Nov 2001, Wilson, Doug wrote:
>
> > From: Don Seiler [mailto:[EMAIL PROTECTED]]
> >
On Fri, Nov 02, 2001 at 02:18:15PM +0100, Bart Lateur wrote:
> On Fri, 02 Nov 2001 07:27:49 -0500, Scott R. Godin wrote:
>
> >my %db;
> >$sth->bind_columns( \( @db{ @{ $sth->{NAME} } } ));# magic
> >
> >while ($sth->fetch)
> >{
> >#... and no worries about which order the
But prepare_cached/prepare has nothing to do with multiple connections.
There were connect() changes made between DBI 1.14 and 1.15 but I'd need
people to look into it for me. Should be trivial to debug by enabling
DBI tracing and Apache::DBi debug.
Tim.
On Fri, Nov 02, 2001 at 07:51:33AM -0800
The breakout of where a subroutine ends and begins is largely a matter of
personal preference. You'll have to iterate over all the groups somewhere,
I would tend to do it where my rough example showed so that subroutine
group_is_OK wouldn't need to know whether the group being examined is part
> my %groups;
> while (my $hashref = $sth->fetchrow_hashref) {
> push @{$groups{$hashref->{group_num}}}, $hashref;
> }
>
> then later...
>
> foreach my $group_number (keys %groups) {
> delete $groups{$group_number} unless group_is_OK($groups{$group_number});
> }
I don't understand why you
When I pass in a hash to a function like below:
group_is_OK($groups{$group_number});
I'm confused as to how to handle that argument with in the function,
knowing the there are multiple values for that key.
I start out with this:
sub group_is_OK
{
my $hash = $_;
#
}
I want to loop throu
Scott R. Godin writes:
> the absolute neatest trick I've seen with this, that is so totally
> perlish it defies description.. you stare at it for a bit and suddenly
> all becomes clear.
>
>$sth->execute
> or die("Cannot Execute SQL Statement: ", $sth->errstr(), "\n");
>
I have traced it back to prepare_cached() (at least that is what I
notice).
Scott, try replacing your calls on startup with prepare() instead of
prepare_cached().
I was also able to eliminate the problem if I commented out the
following line in DBI.pm
# $dbh->STORE('CachedKids', $cache = {})
GENIUS! That did the trick.
Thanks much,
Don.
On Fri, 2 Nov 2001, Ronald J Kimball wrote:
> On Fri, Nov 02, 2001 at 08:42:42AM -0600, Don Seiler wrote:
> > Perhaps I wasn't supposed to take it so literally, and my hash handling
> > skillz aren't quite what they should be.
> >
> > When I do thi
On Fri, Nov 02, 2001 at 08:42:42AM -0600, Don Seiler wrote:
> Perhaps I wasn't supposed to take it so literally, and my hash handling
> skillz aren't quite what they should be.
>
> When I do this:
>
> while (my $hashref = $csr->fetchrow_hashref())
> {
> print "Adding record from group " . $has
Perhaps I wasn't supposed to take it so literally, and my hash handling
skillz aren't quite what they should be.
When I do this:
while (my $hashref = $csr->fetchrow_hashref())
{
print "Adding record from group " . $hashref->{group_code} . ".\n";
push (@{$groups{$hashref->{group_code}}}, $has
On Fri, 02 Nov 2001 07:27:49 -0500, Scott R. Godin wrote:
>my %db;
>$sth->bind_columns( \( @db{ @{ $sth->{NAME} } } ));# magic
>
>while ($sth->fetch)
>{
>#... and no worries about which order the columns get returned in
>#... since you access them via the $db{Colum
I am using DBD:Sybase to interact with Sybase database
and using DBD:ODBC for Mssql database. I tried to copy
image data either way , but unfortunately failed. Could
anybody please suggest me like what is the best way
to transfer the data from sybase to Mssql or vice versa.
Thanks
prasad
In article <[EMAIL PROTECTED]>,
[EMAIL PROTECTED] (Eric Kolve) wrote:
> I think I have found a curious bug in DBI. It seems that since DBI 1.15
> - 1.20, when you bring up apache/mod_perl and execute queries against
> the database handle in the parent process (startup.pl), multiple
> connection
In article <[EMAIL PROTECTED]>,
[EMAIL PROTECTED] (Bart Lateur) wrote:
> On Thu, 01 Nov 2001 18:56:18 -0800, Venkataramana Mokkapati wrote:
>
> >How do I get column names and order of column names
> >for a "select * from ..." query.
>
> If you have
>
> $sth = $dbh->prepare("select * fro
On Thu, 01 Nov 2001 18:56:18 -0800, Venkataramana Mokkapati wrote:
>How do I get column names and order of column names
>for a "select * from ..." query.
If you have
$sth = $dbh->prepare("select * from ...");
then try
@column_names = @{$sth->{NAME}};
You may have to do an "ex
$sth->{NAME} returns a reference to an array of field names for each
column
e.g.
foreach my $column (@{ $sth->{NAME} }) {
print $column;
}
--
Simon Oliver
54 matches
Mail list logo