10,940 Topics

Member Avatar for
Member Avatar for Dani

I'm trying to select rows from a table that meet a bunch of criteria, but one of the criteria is that a row doesn't already exist with two matching columns both being true at the same time. For example, suppose table t1 has columns: a, b, c and d Here's …

Member Avatar for BitBlt
0
291
Member Avatar for kiLLer.zoh

if have checked this query several times but it aint passing the data to database..in other way every thing seems fine in this query kindly please sort out ths problem. $qry="Insert into `postjob` (jobtitle,positions,category) VALUES('".$_POST['title']."','".$_POST['position']."','".$_POST['cate']."')"; printf mysql_query($qry) or die(mysql_error());

Member Avatar for GliderPilot
0
110
Member Avatar for cheelo007

Ok, I may be missing something very easy but when I submit and query the database the session doesn't set for some reason and I'm sent back to admin.php per instruction of my index.php file. Could someone please give this a look over, maybe it's a very simple fix, but …

Member Avatar for cheelo007
0
379
Member Avatar for akash1190

how can i fecth my record from mysql database from two rows in asingle table? and both feild are different where i want to fetch my record?

Member Avatar for pritaeas
0
29
Member Avatar for romanromeo89

Hello I'm running a php function to get some user information from mysql using pdo. The problem is that i don't get the results i want. This is my php code: <?php require_once('db_connect.php'); function mila(){ global $dbh; // Set dummy variables $required_id=1; // Select table with query $sth = $dbh->prepare("SELECT …

Member Avatar for diafol
-1
220
Member Avatar for davy_yg

Hello, I am a mysql table called: adsmgt which consists of: idads and time I would like to count the number of row in adsmgt how to do so? I try this: mysql_select("select TABLE admgt count(idads)"); This error appears: (it doesn't matter if the idads are twins they still have …

Member Avatar for diafol
0
176
Member Avatar for bbjybon89

Hi, I have a problem to delete data from mysql database using checkbox. This the error appear in my page and the data cannot delete. <?php $host="localhost"; // Host name $username="root"; // Mysql username $password=""; // Mysql password $db_name="mentormentee"; // Database name $tbl_name="appointment"; // Table name // Connect to server …

Member Avatar for broj1
0
204
Member Avatar for Dani

Is there any way to set the long_query_time for the slow query log to less than < 1s? We consider anything over 0.5s something wrong. Or can you recommend any MySQL monitoring software that can handle a super high load without a super amount of storage space?

Member Avatar for pritaeas
0
623
Member Avatar for venkyb47

I am using Decimal data type to store time like 1.30(1 hour 30 min),0.40(40 minutes) in MySQL. I want to calculate total time. When I use SUM function it was giving result in unexpected way. example: 1.30 + 0.30 = 1.60 -> SUM function gives like this. But I want …

Member Avatar for pritaeas
0
583
Member Avatar for mpc123

Hi I have variables set in the head of the page as they are used for other parts of the page. I have a problem where by I am trying to get the variable to echo out in the result. I have tried several ways but either ther eis an …

Member Avatar for AndreRet
0
113
Member Avatar for christian.i.wibowo

hi... i want to insert data from array using mysql from php..and now i using this code : for ($i = 0; $i < count($data1); $i++) { $insert_sql = sprintf("INSERT INTO detail_paket (id_paket, menu_paket) select paket.id,'\"%s\"' from paket where paket.nama_paket='$nama_paket'",%data1[$i]); mysql_query($insert_sql); } data1 is the array.. what is the correct …

Member Avatar for simplypixie
0
389
Member Avatar for Backslider

I need to find valid records as part of a database cleanup script. What I need is a regular expression that will match, for a single column: records containing BOTH numbers AND letters (or any other character). records containing ONLY numbers (including decimals) Invalid records are those which contain ONLY …

Member Avatar for Backslider
0
76
Member Avatar for code739

Hi guys, im kind of curious, is there a query or some way to fuse two colums like `select a.col1,b.col1 from table1 a left join table2 b on a.id=b.table_a_id` then as a result i want to display only one column containing a.col1,b.col1 thanks =)

Member Avatar for code739
0
291
Member Avatar for GraficRegret

I am trying to get my code working so that I can store the path of an uploaded picture onto a table so that I can call upon the uploaded file whenever I need it. So what happens on the web page is, a person enters information on a vehicle …

Member Avatar for diafol
0
180
Member Avatar for murali1

Hello everybody , Im created an Application in vb6.0 . In that application i have to store data in a web Mysql database.How can i connect tht

Member Avatar for AndreRet
0
2K
Member Avatar for LindaJ

Hi, I need a hand from a kind MySQL guru. I am running XAMPP for WinXP ver 1.6.8, phpMyAdmin ver 2.11.9.2, PHP Version 5.2.6 - on a local host (my laptop). I'm running Joomla 1.5.7 (on both my net server and on my local host). What I need to do …

Member Avatar for shafi.nce
0
573
Member Avatar for andarivaadu1

Here is my query UPDATE tracks SET People_id_Reference = (SELECT People_id FROM People RIGHT JOIN top100 ON People_name=top100.artist LIMIT 1) WHERE People_id_Reference IS NULL; But that query inserts same people_id value into all rows of People_id_reference Can some on help me with this. Thanks in advance

Member Avatar for andarivaadu1
0
196
Member Avatar for giovannitao

Hello, I'm developing script php about cell phone specific, now I want to insert an uploader for image of cell phone. I want to upload image to a fecific folder and save url to mysql table. Can you help me to create form and how to do this?

Member Avatar for B1ts
0
3K
Member Avatar for swapna7999

hi i need to connect a vb application to a mysql database which is in a remote server plz suggest solutions thank u very much

Member Avatar for choeychoco
0
797
Member Avatar for a.abhishek1229

I am getting an error..Need help.. " Parse error: syntax error, unexpected T_STRING in C:\xampp\htdocs\test2.php on line 24"; line 24 is --"header("Content-Type: application/xls");"-- <?php $DB_Server = "localhost"; //MySQL Server $DB_Username = "root"; //MySQL Username $DB_Password = ""; //MySQL Password $DB_DBName = "test"; //MySQL Database Name $DB_TBLName = "sample"; //MySQL Table …

Member Avatar for LastMitch
-1
305
Member Avatar for eburlea

Hello. I have a larger database that I want to import and I cannot do that using phpmyadmin. I tried to do this in many possible ways by command line, but I get message 'wrong syntax'. I have Windows Vista, MySQl version 5.5.24, wamp server. The path to mysql.exe is: …

Member Avatar for urtrivedi
0
398
Member Avatar for nnehadixit

hi friends, here is my problem i'm designing a page with no. of checkboxes but not able to insert its value in mysql... here is my php code: **<?php $host="host"; // Host name $username="root"; // Mysql username $password=""; // Mysql password $db_name="packtest"; // Database name $tbl_name="test"; // Table name // …

Member Avatar for nnehadixit
0
305
Member Avatar for bikertz

I am reading data from a mysql database and displaying it on a web page for the user to make changes. One of the values that I am getting from the database is to be displayed in a Select tag: Manufacturer: <select name="Manufacturer" tabindex="1" > <option></option> <option>Aprilia</option> <option>BMW</option> <option>Moto Guzzi</option> …

Member Avatar for bikertz
0
627
Member Avatar for dharmendra1986

I am not able to restore sql file from linux command prompt. I have used the below command. Here is the message.No table is restored. I am running this in my local machine adminuser@virtualboximagescom-VirtualBox-34s7dkv4:/$ mysqldump -u root -p replication_test </home/adminuser/Downloads/rp.sql Enter password: -- MySQL dump 10.13 Distrib 5.5.28, for debian-linux-gnu …

Member Avatar for dharmendra1986
0
209
Member Avatar for primzon

Hello again! Now i stucked with another little problem. I have a table: ID____Name______Age_______City 1_____Robert_____20_______London 2_____Fabio______31_______Rome 3_____Hans______35_______Berlin 5_____Josh_______25_______London Now i don't know how to get a city which has the most population in this table. With my code: SELECT City, COUNT(Name) AS Population_number FROM Person GROUP BY City; I get …

Member Avatar for primzon
0
155
Member Avatar for OsaMasw

Hello buddies , I have no Idea what is subquery, every time I tried to link two tables in one sql query I failed here is the scenario I want: in this pic I have posts with "**user_id**" only I need to show the username which stored on another tables …

Member Avatar for simplypixie
0
938
Member Avatar for xbat

Ok So I have seen a few things.. But is there anything that goes into depth more but sort of squared away... From what it looks like if you develop something in mysqli - it will be faster mysql pdo - works with a bunch of other databases.. I found …

Member Avatar for veedeoo
0
219
Member Avatar for primzon

Hello guys! Please help me with a little problem. I have one table(Person) where are some values. My current syntax is: SELECT Status, COUNT(Name) AS Number FROM Person WHERE Status = 'Married'; Result: Status_________Number --------------------- Married__________3 But I want to get the result for each status. That would be something …

Member Avatar for JorgeM
0
196
Member Avatar for rajesh.goblet

I made a wesite which have a webforum something like this site. Where a user can send message to each other. i am using php-mysql. i want to know how to store info about if user had read his message or its still unread. my site is [www.thar.co][1]. mysql table-column …

Member Avatar for rajesh.goblet
0
267
Member Avatar for wordtechinc

CREATE PROC [dbo].[INRv2_GetAllSavedJobs] AS SELECT plm.jobcode [Job No],si.seminartitle [Seminar Title] FROM (SELECT DISTINCT pm.jobNo jobcode FROM inr_mailinglist pm) plm INNER JOIN (SELECT js.jobno, sm.seminartitle FROM inr_seminarmaster sm INNER JOIN inr_jobshedule js ON sm.seminarid =js.seminarid) si ON plm.jobcode =si.jobno ORDER BY plm.jobcode RETURN GO > This SP retruns [Job No] rows …

Member Avatar for wordtechinc
0
283

The End.