-
MS beats Sun on TPC? Go Figure
Date: 06/22/05
(Open Source) Keywords: mysql, sql, linux
There's an untold story here, by the way: all the other hardware vendors are reporting their results using
Linux. Put Debian with mySQL on this machine, and you'd probably break a $1.20 -and an Apple X-serve
using lots of RAM could probably break one dollar because its X-RAID array is so cheap.
Source: http://blogs.zdnet.com/open-source/?p=345&part=rss&tag=feed&subj=zdblog
-
Testing on the fly data compression in Apache
Date: 06/23/05
(Web Development) Keywords: mysql, database, sql, apache
I had an interesting question come up? How much of a speed improvement (if any) will I get by installing mod_deflate on apache?
I would think that it would be a good bit but without some sort of test I have no way of knowing. So I wrote a Test Program It requires mozilla or firefox to run but if people here would be willing to help me out It would be very good. It is not very hard. Just click on that link and then click the “run test” button. It will take over from there. It will take a few minutes to run.
Please note that this test requires Mozilla or Firefox to run.
You don’t have to send me the output, as it will store all the timing data in a MySQL database.
I’ll post a summery here when this is done.
Thank you once again.
Source: http://www.livejournal.com/community/webdev/214042.html
-
Why isn't this working?
Date: 06/24/05
(PHP Community) Keywords: mysql, sql
I have this line on one page..
$update_totals = "UPDATE stock SET qty = $add, count = $newtotal WHERE barcode = $barcode";
$update = mysql_query($update_totals, $connect);
..and it works fine. I have an if statement echoing "success, bla bla.." if it works and it's great. So why is it that this:
$update_details = "UPDATE stock SET barcode = $barcode, prod_code = '$prodcode', printer_model = '$print_mod', desc = '$type', qty = $qty, count = $count, colour = '$colour', order_level = $reorder WHERE barcode = $old_bcode";
$update_qry = mysql_query($update_details, $connect);
..doesn't work? What am I missing/not doing?
RESOLVED thanks everyone :)
Source: http://www.livejournal.com/community/php/312514.html
-
Using PHP to query an XML document
Date: 06/25/05
(PHP Community) Keywords: xml, database, sql
Okay, the subject's kind of vague, but here is what I need to do:
Right now, the Perl programmers are using a perl script to do a database dump of multiple tables into XML format, and Im using cURL to retrieve that XML.
Now here is the problem, for some reason, they refuse to handle the proper SQL selections for what I need, so basically, I need to correlate the data in the different nodes (tables) to each other.
For instance, I have one node that contains the foreign key of another node, which then holds the foreign key of another node.
Ill give you a good example of what I need to do:
machine_user_map contains the package_service_id.
I then need to grab the package_id from package where the package_id in package_service is the same as the package_id in package.
Then, I need to grab the package name from package.
I've been using XPath so far, but there is no way to do multiple select-type commands with XPath like there is in SQL.
Does anyone have a good solution for handling this sort of thing?
Thanks in advance :)
Source: http://www.livejournal.com/community/php/312736.html
-
My apologies, but...
Date: 06/26/05
(SQL Server) Keywords: database, sql, microsoft, google
Hello everyone. I apologize in advance for being the typical newbie at this sort of thing, but I don't really have a choice. I just landed a new summer job at an Embassy and I really need some help.
I have been giving the task of sorting out maps in my department. I'm to build a database where I index all of the maps so that people in the Embassy can have easier, more organized access to them. However, I have never, ever done anything like this before and unfortunately I am stuck with Microsoft Access (I've already been told that SQL is far superior to MA). Believe me, I would switch to SQL in a heartbeat because I have heard that it is more user-friendly, but MA is what I've been given to work with and I cannot download anything onto my computer.
So far I've set up tables and created a couple of forms. I've probably already done something wrong just through that. I realize that people take courses to learn how to use MA and it's going to take more than a few LJ comments to help me get through this. What I was hoping you guys could direct me toward are some detailed MA tutorials online. I'm having specific problems trying to understand what 'queries' are and how to set up a main switchboard. The purpose of this index is to serve as sort of a search engine to look up these maps, and I don't know how to do that.
So if anyone has any links to tutorial sites, hopefully more specific to what I'm trying to do, that'd be great. I've already Googled for help and I've found a few tutorials, but I'm hoping for even more help.
Sorry about my sob-story. I'm really in a bind here. MA is making me feel really, really unintelligent.
Source: http://www.livejournal.com/community/sqlserver/29345.html
-
Some background help with PHP + API, SOAP, XML
Date: 06/27/05
(PHP Community) Keywords: php, mysql, xml, sql
I am a novice PHP scripter. I have done most of my work with PHP and MySQL, and PHP alone, but now a client is asking me to work with his API and SOAP. I am also a XML beginner.
I admit, this stuff sounds a little scary. I was wondering if working with his API will be (shoulkd be) as easy as working with PHP's MySQL functions? Am I making the right analogy? I see PHP has some XML functions, too. When the client says I will "parse the XML" and pull the info out of it, will I be searching it for a string/pattern?
I am a bit clueless and trying to do some research before I talk to him again. If you guys have any sites that you recommend for PHP use with API, SOAP and XML (or even a book), I would appreciate it the info.
Source: http://www.livejournal.com/community/php/312940.html
-
SQL Server 2005 podcast
Date: 06/27/05
(SQL Server) Keywords: asp, sql
Kimberly Tripp is a badass and you can find a 98 minute interview with her on .NET ROCKS.
Kim Tripp is back and more intense than ever. After talking about her famous USB Key demonstration of SQL 2005 partitioning, she gets into details of SQL 2005 that would make even the SQL team go "hey, that's cool!" This is one of those shows that you'll have to listen to several times to completely grasp. We know we will!
http://perseus.franklins.net/dotnetrocks_0110_kimberly_tripp.mp3.torrent
Source: http://www.livejournal.com/community/sqlserver/29642.html
-
SQL poetry, the new geek art form....
Date: 06/28/05
(SQL Server) Keywords: sql
Pretty much any moron can write SQL queries.
But can you write them into a poem using formal meter?
You should try it - what have you got to use?
Source: http://www.livejournal.com/community/sqlserver/29720.html
-
Optimising MySQL
Date: 06/28/05
(PHP Development) Keywords: mysql, database, sql, google
I'm working on a site at the moment and I'm trying to optimise the MySQL queries, to place less of a strain on the server and make generally neater code. I'm currently using this technique to pull the last 10 topics flagged as news from the database:
$query = mysql_query( "SELECT * FROM frm_topics t WHERE t.tpc_news = '1' AND t.tpc_news_mod_id > 0 ORDER BY t.tpc_sticky DESC, t.tpc_time DESC LIMIT 10", $_GLOBALS[ 'sql' ] );
Then in the loop created by $results = mysql_fetch_array( $query ) using a second query to pull the content of the post:
$news_sql = mysql_query( "SELECT * FROM frm_posts p WHERE p.pst_tpc_id = '".$results[ 'tpc_id' ]."' ORDER BY pst_time ASC LIMIT 1", $_GLOBALS[ 'sql' ] );
Now, although this works, it currently uses 11 queries, plus various others I'm using to create each page; so I'm trying to find a neater solution. I've tried some tutorials on sub-queries found on Google, to no avail. The following works if there's only one news topic but falls over if there's more:
$query = mysql_query( "SELECT * FROM frm_posts p, frm_topics t WHERE p.pst_tpc_id = ( SELECT tpc_id FROM frm_topics t WHERE t.tpc_news = '1' AND t.tpc_news_mod_id > 0 ORDER BY t.tpc_sticky DESC, t.tpc_time DESC LIMIT 10 ) AND t.tpc_id = p.pst_tpc_id ORDER BY p.pst_time ASC LIMIT 1", $_GLOBALS[ 'sql' ] );
I'd really appreciate it if anyone could lend a hand or point me in the right direction.
Source: http://www.livejournal.com/community/php_dev/59389.html
-
Deleteing from multiple tables
Date: 06/28/05
(MySQL Communtiy) Keywords: mysql, sql
I have 6 tables, all with a column called "projid" in them. I need to create a delete statement that will delete all rows in all columns where the projid is a specified number. I've read the MYSQL docs on this topic, but I'm still mightily confused. What I think I need is something like this:
DELETE FROM projecttable, collabtable, miletable, stafftable, benetable, invtable
WHERE projid=32
However, I'm fairly certain that the WHERE statement isn't right, and I'm not sure if I need to put the table names after the delete as well as after the FROM, or only one place, or what. Can anyone either explain the syntax I need or point me to a tutorial or something that will help?
Source: http://www.livejournal.com/community/mysql/60657.html
-
Moving data from version 2.5.3 to 2.6.2
Date: 06/29/05
(MySQL Communtiy) Keywords: database, sql
Hi all.
I'm trying to move some tables from an old 2.5.3 database to my new 2.6.2 one and I'm experiencing some difficulties. I'm doing my usual method of exporting the old files to a text SQL file and then uploading the file to the new database, which has always worked for me in other situations, however, in this situation whenever I upload the file to the v2.6.2 database, it gives me an error message of "No SQL query".
Edit: never mind, I figured out what I had been doing wrong. I had been forgetting to check "Extended inserts" when exporting the database files. Problem fixed. :)
Source: http://www.livejournal.com/community/mysql/60761.html
-
Creating a table dynamically
Date: 06/29/05
(PHP Community) Keywords: php, mysql, database, sql
I'm running this bit of PHP script in a page I'm writing for a real estate's site:
$query = "CREATE TABLE 'mls" . $mls . "' ('id' INT NOT NULL AUTO_INCREMENT,'photo' VARCHAR(50) NOT NULL, PRIMARY KEY ('id'))";
$result = mysql_query($query) or die("Query failed : " . mysql_error());
The idea is that it's supposed to create a table named using a variable in the database. I would like to be able to dynamically create and drop tables as real estate listings are added and deleted. I just tried it out and it didn't work. No errors but the table didn't appear in the db when I went to look using phpMyAdmin. Is there something wrong with my code or is what I'm trying to do not possible?
Source: http://www.livejournal.com/community/php/313804.html
-
Creating a table dynamically
Date: 06/29/05
(Web Development) Keywords: php, mysql, database, sql
I'm running this bit of PHP script that I'm writing:
$query = "CREATE TABLE 'mls" . $mls . "' ('id' INT NOT NULL AUTO_INCREMENT,'photo' VARCHAR(50) NOT NULL, PRIMARY KEY ('id'))";
$result = mysql_query($query) or die("Query failed : " . mysql_error());
The idea is that it's supposed to create a table named using a variable in the database. I would like to be able to dynamically create and drop tables as real estate listings are added and deleted. I just tried it out and it didn't work. No errors but the table didn't appear in the db when I went to look using phpMyAdmin. Is there something wrong with my code or is what I'm trying to do not possible?
Source: http://www.livejournal.com/community/webdev/216628.html
-
Failure of PHP to work with Apache / MySQL
Date: 07/03/05
(PHP Community) Keywords: php, mysql, sql, google, apache
I turned on my computer last night and found that PHP was refusing to communicate with MySQL - I could make MySQL work through the command line and through Perl, but not through PHP. I checked everything that I could think of and everything I could find on google without any joy. I have spent about 8 hours messing with this now and I'm getting nowhere. I've uninstalled and reinstalled php & mod_php so many times today that I've lost count. My latest idea was to uninstall php, mod_php, and apache. I've reinstalled Apache, php, and mod_php (in that order) but now PHP refuses to work with Apache. I've added APACHE2_OPTS="-D PHP5" to the apache config in /etc/conf.d/apache2 but it hasn't made any difference.
I'm running Gentoo with Apache 2.0.54, PHP 5.0.4 (along with mod_php 5.0.4), and MySQL 4.0.24.
Does anyone have any ideas how I can make it work again as I'm going insane here and feel like throwing the computer out of the window...
Source: http://www.livejournal.com/community/php/314431.html
-
PHP/MySQL Import
Date: 07/03/05
(PHP Community) Keywords: php, mysql, sql, web
I have a dump file on the web server. How do I do a mysql import of that file. It's over 2MB and I can't use phpmyadmin because of that.
Source: http://www.livejournal.com/community/php/314649.html
-
Problems with SQL query
Date: 07/04/05
(PHP Community) Keywords: php, database, sql
Hi,
I am having problems with an SQL query not returning any rows. My table in my database is set up like:
ns_event_month INTEGER
ns_event_day INTEGER
ns_event_year INTEGER
(i'm leaving many fields out)
And here is part of my code. It returns zero rows, however there are 2 records in my database that are 5/6/2005 and 5/7/2005 (m/d/y). So there are 2 archived "events" already, but this query returns nothing.
http://www.welcometothenuclearage.com/shows.php (a link to the page that isn't working correctly)
I am currently displaying all the current shows my band has booked, but I want to show all the past shows. This was working fine until one day, and then it just stopped working. So I'm lost...
Any help is greatly appreciated.
Source: http://www.livejournal.com/community/php/314881.html
-
SQL Server Connection
Date: 07/05/05
(PHP Community) Keywords: php, asp, sql
Hi,
I have some php running in the latest php stable 4.x build on Windows 2003 Server in IIS6 in ISAPI mode.
My code does a mssql_connect, this previously was working fine, this week it has stopped working. I am unaware of any specific changes.
SQL Server is running on a non-standard port, on the localhost. Client Network Utility is configured to talk on the custom port, as is server network utility. ASP Code running in the same instance connects fine.
I have tried variations such as:
localhost
localhost,[port]
localhost:[port]
\\localhost\instancename,[port]
With no change.
Any suggestions?
Source: http://www.livejournal.com/community/php/315371.html
-
Logs? Admin Question...
Date: 07/05/05
(MySQL Communtiy) Keywords: mysql, sql, google
I find these files named:
[servername]-bin.001, .002, .003, etc in my mysql folder. They look like logs, is that what they are? How can I make mysql _not_ produce them? Any assistance or pointing in the right direction would be greatly appreciated. I did try to google it, but got nothing.
Source: http://www.livejournal.com/community/mysql/61051.html
-
Bizarre error... hulp?
Date: 07/05/05
(Web Development) Keywords: database, asp, sql
IIS 6 SQL 7.0 ASP VBScript
Some simple math:
0.55 + 0.02 -0.49
Should equal 0.08 – correct?
When I add up these values from the database (the rest are 0 value - there are only three fields that have value as above)
totalAdjust = oRecordset("hisSunAdj") + oRecordset("hisMonAdj") + oRecordset("hisTueAdj") + oRecordset("hisWedAdj") + oRecordset("hisThuAdj") + oRecordset("hisFriAdj") + oRecordset("hisSatAdj") + oRecordset("his2SunAdj") + oRecordset("his2MonAdj") + oRecordset("his2TueAdj") + oRecordset("his2WedAdj") + oRecordset("his2ThuAdj") + oRecordset("his2FriAdj") + oRecordset("his2SatAdj")
I get: 8.00000000000001E-02
If I do this in code:
response.write 0.55 + 0.02 -0.49
I get: 8.00000000000001E-02
THAT is the most bizarre part because I’m just outputting the calculation – it can’t possibly be anything in the code or database because I hard coded the math and came out with the same WRONG answer!!
Just to double check that I cut and pasted the record from the database into Excel and Summed it in there, and sure enough, it gave me the (correct) 0.08 just as my calculator did.
Any thoughts??
Source: http://www.livejournal.com/community/webdev/217437.html
-
SP4 on SQL Server 7.0 on an NT4.0 machine?!?
Date: 07/06/05
(SQL Server) Keywords: database, sql
Alright, here's an oddball situation for everyone. Seems we have a client that is running the above version of SQL Server 7.0 - SP3 on NT4.0, and is attempting to upgrade to SP4. But the SP doesn't seem to be applying itself. From what I've been told, they check the version numbers after applying the SP and rebooting, and it continues to remain the same, not switch over to the newer SP4 version number. And now this got passed off to me (being the lowest on the already short totem pole), to attempt to research.
Whee... don't suppose anyone out there might miraculously have any insight into this?
And to answer some of the obvious questions, no I have no idea why they just don't upgrade past NT4 and 7.0... no, I don't have direct or even indirect access to the machine, and cannot attempt to apply the service pack myself. SQL Server continues to chug along happily. No errors are logged anywhere as far as I know either.
x-posted to databases
Source: http://www.livejournal.com/community/sqlserver/30199.html