10,940 Topics

Member Avatar for
Member Avatar for garyjohnson

I know there are other post conserning this but they dont seem to help me. When I run the varaible `$results` through the function `Mysql_num_rows()` it returns as an error saying its not a valid result. Also same for the `mysql_fetch_array()`. function results(){ if ($_POST['search'] != "") { $search = …

Member Avatar for garyjohnson
0
211
Member Avatar for chira.laura.9

If I have relation schema R(A, B, C, D, E) with functional dependencies: AB->C, CD->E, C->A, E->D: a)find all the (minimal) keys for R b)state the normal form for R and describe functional dependencies that violate higher NF c)decompose R into 2 (or more) relations that are in highest possible …

Member Avatar for peter_budo
0
95
Member Avatar for adishardis

I'm trying to get an xml file from an ftp and then insert select data into mysql db. I'm shooting in the dark but from googling this is what i've tried so far: $curl = curl_init(); $file = fopen("import.xml", 'w'); curl_setopt($curl, CURLOPT_URL, "ftp://company@company.company.se/company/import.xml"); #input curl_setopt($curl, CURLOPT_FILE, $file); #output curl_setopt($curl, CURLOPT_USERPWD, …

Member Avatar for adishardis
0
480
Member Avatar for adishardis

Hi, I, getting a new xml file everyday to one of our external ftp servers. I want to get that file and then insert select data into my mysql. What I'm thinking is that I would use curl to get the file, then simplexml and then insert into database. But …

Member Avatar for adishardis
0
217
Member Avatar for pucivogel

<?php mysql_connect("localhost", "root", "") or die(mysql_error()); mysql_select_db("agenda") or die(mysql_error()); $q = mysql_query("INSERT INTO kontakte (emri, mbiemri,e-mail,nr,adresa,shenime) VALUES( '{$_POST['emri']}' '{$_POST['mbiemri']}', '{$_POST['e-mail']}', '{$_POST['nr']}', '{$_POST['adresa']}', '{$_POST['shenime']}') "); if (!$q) { $message = 'Invalid query: ' . mysql_error() . "\n"; $message .= 'Whole query: ' . $query; die($message); } ?> <html> <head></head> <body> <div …

Member Avatar for urtrivedi
0
139
Member Avatar for chuyauchi

I have three tables: collections [clientID][isbn] books [title][isbn][author] clients [cliendID][firstName][lastName] I am making a seach functon on php. The function will search the clientID and display the name (from the clients table) and what book that client has (fro collections table). What should I do for the query? $query = …

Member Avatar for LastMitch
0
85
Member Avatar for garyjohnson

I am making a mysql query that gathers comments for a user, it works properly, I connect to the database and recieve the comments for a user, but it is not showing the first comment for the user. Here is the code function comments(){ //connect to db connect_db_members(); //start query …

Member Avatar for garyjohnson
0
306
Member Avatar for karo.toapanta

CREATE TABLE `camioneta` ( `codigo_vehiculo` varchar(20) NOT NULL, `cabina` varchar(50) DEFAULT NULL, `capacidad` int(11) DEFAULT NULL, `num_puertas` int(11) DEFAULT NULL, PRIMARY KEY (`codigo_vehiculo`), CONSTRAINT `fk__camioneta__codig__300424b4` FOREIGN KEY (`codigo_vehiculo`) REFERENCES `vehiculos` (`codigo_vehiculo`) ON DELETE CASCADE ON UPDATE CASCADE ) ENGINE=InnoDB DEFAULT CHARSET=utf8; /*!40101 SET character_set_client = @saved_cs_client */;

Member Avatar for LastMitch
0
175
Member Avatar for Noth

Hi everyone. I'm trying to verify whether the variables $username and $password_recovery (both are unique - impossible for them to be the same) both come from the same row in the rable 'users'. This is the query I am using: return (mysql_result(mysql_query("SELECT COUNT(`user_id`) FROM `users` WHERE `username` = '$username' AND …

Member Avatar for urtrivedi
0
196
Member Avatar for dinhunzvi

i have two tables the following structures. CREATE TABLE `tblbranches` ( `branchID` tinyint(3) unsigned NOT NULL AUTO_INCREMENT, `branchCode` varchar(30) NOT NULL, `branchName` varchar(30) NOT NULL, `regionID` tinyint(3) unsigned NOT NULL, `branchAddress` varchar(400) NOT NULL, `cityID` smallint(5) unsigned NOT NULL, `countryID` smallint(3) unsigned NOT NULL, `branchContact` varchar(50) NOT NULL, `branchFax` varchar(20) …

Member Avatar for dinhunzvi
0
191
Member Avatar for kevinkev

I have the following php code that queries my Database called get_cost.php.The query is working as it displays all content of my TABLE si, kindly assist! <?php /* * Following code will list all the products */ // array for JSON response $response = array(); // include db connect class …

0
59
Member Avatar for edensigauke

I want to know what method to use to view Images from my MYSQL database using PHP. i know that for basic data it is getString(). what about for images?

Member Avatar for edensigauke
0
242
Member Avatar for NagyAndor1995

Hi, I've been searching for a solution for this problem, but couldn't find anything that would help me. I get this error: Warning: mysql_num_rows() expects parameter 1 to be resource, boolean given in C:\xampp\htdocs\lab2.andornagy.info\lib\core\login.php on line 15 My codes: Login.php: <?php include_once("../autoload.php"); $login = new Login(); ?> <!DOCTYPE html PUBLIC …

Member Avatar for NagyAndor1995
0
321
Member Avatar for davecoventry

I have a client who deleted users on his database. Is there any possibility that the records have been flagged for deletion rather than physically deleted? If so how do I recover them? It's a Joomla system and there are no backups. Thanks. (Yes, I know).

Member Avatar for pritaeas
0
113
Member Avatar for Szabi Zsoldos

Hi guys, I have a database with hundreds of persons and doing a live-search with ajax. And I have this query. The idea is that I do have the test line in the db but it has a status 0, but it is keep showing up in the results even …

Member Avatar for VR4Creativity
0
103
Member Avatar for showman13

I have a table of withdrawal requests that has a datetime field called 'create_date' I need to query that table to see if a member has submitted a withdrawal request within the past 24 hours If they have, I need just the most recent record within 24 hours that matches …

Member Avatar for showman13
0
133
Member Avatar for ebc3142

I'm trying to use this code to populate my drop down menu from a mysql table: <select name="fileselect"> <?php $pdo = new PDO('mysql:host=localhost;dbname=contisec_portal', 'root', ''); $stmt = $pdo->prepare("SELECT dateid FROM date_header"); $stmt = $pdo->execute(); while ($row = $stmt->fetch(PDO::FETCH_ASSOC)) { echo "<option value='" . $row['dateid'] . "'>" . $row['dateid'] . "</option>"; …

Member Avatar for diafol
0
7K
Member Avatar for dashawk

Hi guys, I have a php code that displays a list of dishes where a user can check on those dishes and then save the selection to the database. My code works find when selecting and saving the data. But the problem is that when I try to uncheck one …

Member Avatar for dashawk
0
272
Member Avatar for joshmac

I am using a framework, and I am having an issue with getting the results of this particular associative array. All others work except for this one and I am not sure why. This one only returns one result. Here is what I have in my model: public function listStats($id) …

Member Avatar for joshmac
0
227
Member Avatar for Some-Jackass

In my MySQL database I have my regular tables, and a couple of VIEWS. Everything runs like clockwork, until I remove Remote Access to the database. I cannot access any of my VIEWS. Accessing any regular tables still work 100%. The thing is, the PHP script accessing the VIEW is …

Member Avatar for Some-Jackass
0
273
Member Avatar for GraficRegret

is it posible to pass information held inside a MySQL database into a javascript array using PHP code? something like: $sql = mysql_query("SELECT * FROM uploads WHERE ref_id = '$refID'"); //javascript below var array = new Array() while(<?php echo $row = mysql_fetch_array($sql)?>) { array.push(<?php echo $row['name']; ?>) } or am …

Member Avatar for diafol
0
312
Member Avatar for mrhankey

hi, i am adding in a basic accounts table to my system. what i need to know is what is the best way to insert repeat payments. such as rent monthly? many thanks

Member Avatar for adam_k
0
182
Member Avatar for amweasel

1. Can ZoDB replace MySQl or both of them serve different purposes? 2. If yes, is ZoDB as good as MySQL for handling a dynamic website?

Member Avatar for amweasel
0
193
Member Avatar for jasonmark238

Hi frinds. What is normalization and what is BCNF. Please give me brief description with simple example. Please help me. Thanks & Regards Jasonmark

Member Avatar for AARTI SHRIVAS
-1
178
Member Avatar for Szabi Zsoldos

Hi guys, I'm working on a holiday scheduling app and I was wondering that if a person wants his holiday for example 10 days. id uid data1 data2 ore tip_concediu ts 7 244 2013-01-25 2013-02-05 3 2 2013-01-25 16:08:35 How would it be possible that I could track the holiday …

Member Avatar for Szabi Zsoldos
0
371
Member Avatar for mrhankey

hi, i have looked on net all over and cannot find an occupations table. basically for my application i need a table of occupations so if anyone has this in sql or excel please can you post up here? many thanks

Member Avatar for mrhankey
0
160
Member Avatar for Vincentas

Hi there, Can someone tell me how do i upload the data created in mysql command line client into the Mysql server, I mean, i have created some tables using mysql command line client in my system, it is accessible only to me. How do i upload it into the …

Member Avatar for Vincentas
0
79
Member Avatar for s0wh4t

Hi. Well, i'm trying to add new data to mysql, <input type="text" name="name"/> example: Billy Boy when I check mysql table, it shows "BillyBoy" How do I fix that error? Thank you.

Member Avatar for s0wh4t
0
228
Member Avatar for MargateSteve

On the surface, the top n per group query is a fairly common one and I have used a few variations on other projects. However, I really cannot get my head around this one and I think it is due to the number of joins. My query (at the bottom …

Member Avatar for MargateSteve
1
294
Member Avatar for Fiorentino01^

I could not put Wamp on line because port 80 was used by IIS7, so I changed it to port 81 and the icon became green,is on line. If I click on phpmyAdmin though I get error 404 not found.I read that phpmyAdmin also uses port 80 so should I …

Member Avatar for Fiorentino01^
0
228

The End.