examples of user defined functions

2003-01-29 Thread Bill Lovett
I was reading about user defined functions, and although they sound interesting, I can't find many examples of their use. If anyone is using them, what are you using them for? Are they a way to manipulate data going into a record, or a way to run pre-defined queries? -bill --

Re: Replication between MySql and MS Sql Server

2003-01-25 Thread Bill Lovett
Look into a product called SQLPorter. http://www.realsoftstudio.com I used it once for a MySQL to MSSQL migration project, but you could go in the other direction. If I remember correctly, I think it includes a scheduling feature. -bill On Tue, Jan 21, 2003 at 01:15:01PM -, John Lodge wrot

Re: MYSQL + ASP Getting Started

2003-01-04 Thread Bill Lovett
If you're asking what I think you're asking, no. You can't store your MySQL queries the way you can with Access or SQLServer (views/stored procedures). Your ASP scripts have to build the queries they need by themselves. -bill John Berman wrote: Hi I have on line access databases and I query t

Re: front ends?

2003-01-01 Thread Bill Lovett
I recently found this web-based front end and am extremely impressed by it. Among other things,it lets you bookmark your sql queries. http://eskuel.sourceforge.net/ -bill Richard Nagle wrote: what would be the easy to use, gui front end for mySQL 3.23.53 (for Mac OS X ) Thanks Again, Richard

Re: Need help connecting to local database with mysql

2002-12-23 Thread Bill Lovett
Hi. I noticed a couple of weird things with your script: - The error "DBI->connect(myd) failed: Couldn't connect to..." is happening I think because 'DBI:mysqlPP:myd' is in single quotes when you call DBI->connect, and the syntax seems off. Maybe you'll have better success if you follow the syn

Re: Load data infile...

2002-12-23 Thread Bill Lovett
Try doubling up your forward slashes so that they stop being special characters. c:\temp -> c:\\temp -bill Lisa He wrote: Hi, I have a question with regards to Load data infile... I have a .txt file containging only path names e.g " C:\temp " in the bodytext. this file is imported into the

Re: time of query

2002-12-20 Thread Bill Lovett
I don't think MySQL can give you back the execution time via DBI, but you might be able to calculate something similar from the Perl side by calculating how long the script runs overall. Here's a good thread from perlmonks about how to do it: http://perlmonks.org/index.pl?node_id=35318 -bill

Re: Problem with Query based on HTML form values - Clarification

2002-12-18 Thread Bill Lovett
t all the form fields you've gotten and ignore the ones that don't have a value attached to them. -bill web-dev wrote: Bill Lovett wrote: Hello, You're getting all new boats + all sail boats + all boats of type x because you're using ORs. If you only want records tha

Re: Problem with Query based on HTML form values

2002-12-17 Thread Bill Lovett
Hello, You're getting all new boats + all sail boats + all boats of type x because you're using ORs. If you only want records that match all the criteria, use ANDs instead. SELECT * FROM boat WHERE condition='$condition' AND type='$type' Or you might try SELECT * FROM boat WHERE (condition='n

Re: Select / Calculate question

2002-12-17 Thread Bill Lovett
I don't think this can be done in a single query, but what about: SELECT Reference.id1, Reference.id2, sum(Table1.number) FROM Table1, Reference WHERE Reference.id1=Table1.id1 GROUP BY Reference.id1 Which gives you: +--+--++ | id1 | id2 | sum(Table1.number) | +---

Re: How can I duplicate a mysql template database?

2002-12-16 Thread Bill Lovett
Are you first creating a new database first with mysql_create_db() before trying to run your schema? What error message do you get? The code you've posted is only creating a table. Also, rather than opening and reading in an external file or doing all those $sql .= lines, you might have an eas