10,945 Topics

Member Avatar for
Member Avatar for J.C. SolvoTerra

Hey guys. I'm writing myself an online toolbox (for my code snippets). I have a "Snippets" table. My question is this. Would you save the snippet source in a Text column or would you have the snippet saved to a text file and the Snippet entry would reference the file …

Member Avatar for diafol
0
227
Member Avatar for usha_bandela

Hi.. I'm getting error in my query.. while using it in oracle it is working.. But when using it in mysql it is not working.. i'm getting error as insert into ProjectHealthReportAudit(clientid, projectid, month, year, phasesId,ACTIVITIESSUBTYPEID, ACTIVITIESARTIFACTSID,processConformance,comments, pcinumber, pciscore, colour, createddate,createdby) values ( (select clientid from client where clientName = …

Member Avatar for usha_bandela
0
1K
Member Avatar for praba_web
Member Avatar for cereal
0
11K
Member Avatar for davy_yg

`Warning: mysql_fetch_array() expects parameter 1 to be resource, boolean given in C:\xampp\htdocs\administrator\admin\schedule.php on line 187` admin/schedule.php //LOAD CLASS LIST $sqlstr = "SELECT * FROM class_list INNER JOIN `group` ON class_list.group_id = `group`.group_id INNER JOIN teacher ON class_list.teach_id = teacher.teach_id INNER JOIN class ON class_list.class_id = class.class_id WHERE datetime > '".date('Y-m-d …

Member Avatar for pritaeas
0
433
Member Avatar for miladrahimi93

Hello buddies! I'm new at Java SE Porgramming with PHP background. I've made a simple app which uses JSON to save some data and I would like to use MySQL database but there was some question for me. 1. If I used MySQL or any database, how much would my …

Member Avatar for JamesCherrill
0
215
Member Avatar for J.C. SolvoTerra

![2680a256fcbf10c900499c36825b3e55](/attachments/large/4/2680a256fcbf10c900499c36825b3e55.png "2680a256fcbf10c900499c36825b3e55") In the above model I have an Images table which holds all the filenames relevant to the image. I have two relationship tables (Image_Has_People and Image_Has_Event). Both of these tables have an FK ImageID linked to the Image table's PK idImage. I'm wondering, if I set both relationship …

Member Avatar for David_50
0
334
Member Avatar for smdjilani

i created a mailing option,when retriving messages it's taking lot of time and showing error of time delay.......can someone help??

Member Avatar for diafol
0
173
Member Avatar for J.C. SolvoTerra

Hi guys, I'm currently on the pretty cool Database development path. I've quickly got to terms with basic SQL with individual tables, and various queries. Now things seen to be getting a little beyond a concept I had been taught from a young age. Am I doing this right. The …

Member Avatar for jstfsklh211
0
188
Member Avatar for jean_5

I need to do a search that specifies in witch line of the search that the information was found. For example: select * from table where height=100; this code returns 50 lines, but i want, for example, in that search, the person 'Matheus' was in the 28th line of the …

Member Avatar for pritaeas
0
257
Member Avatar for sonalchavda

Hi i m learning PHP.How can i insert a data in mysql by using onchange event in radio button, i m not used a submit button in my code can u help me by giving a solution of my prolblem by giving a little example. Thank you so much

Member Avatar for mmcdonald
0
439
Member Avatar for ehpratah

Hi need some insight on how to show record from different database on the same server. i also tried using join but didnt get the correct output. im finding a way to make it work using just one query. my last resort will be using different query to select the …

Member Avatar for ehpratah
0
341
Member Avatar for grant.baker

Ok, what I'm trying to do is have next and prev buttons to navigate through a mysql database sorted by date. Currently, the code I wrote does this, but gets stuck on duplicate dates. $Next = mysql_query("SELECT * FROM $logbook WHERE Date>='$Date' AND ID!='$ID' ORDER BY Date LIMIT 1"); $Prev …

Member Avatar for raybigto
0
3K
Member Avatar for johnef_sh

I am inserting answer of each of my questions I need to get the question id and inserted into the answer table see my code <form action="<?php $_SERVER['PHP_SELF'] ?>" method="post" id="quiz" class="container width_648"> <?php $getTheQuiz = $db->prepare("SELECT * FROM rec_employer_quiz WHERE ad_id=?"); $getTheQuiz->bind_param('i', $ad); if ($getTheQuiz->execute()) { $res = $getTheQuiz->get_result(); …

Member Avatar for johnef_sh
0
695
Member Avatar for kaye.santos.92

i have a datagridview and a combobox. the combobox is auto populated by values from a database. i need to filter the datagridview using combobox. this is the code that i've done. it shows a error : Cannot find column [year]. can you help me??? Imports MySql.Data.MySqlClient Public Class ReportGradeLevel …

Member Avatar for kaye.santos.92
0
368
Member Avatar for zebnoon1

Dear friends, Please guide me I want to display data in PHP form from mysql database. my code is below <?PHP //connect to database $username = "root"; $password = ""; $database = "mydatabase"; $server = "127.0.0.1"; $conn= mysqli_connect($server,$username,$password,$database); // checkintin connection if($conn->connect_error){ die("".$conn->connect_error); } // select data $sql = "SELECT …

Member Avatar for zebnoon
0
4K
Member Avatar for Robin_4

Hi I am using opencart for my website...i am developing ecommerce website for online jewellery store...i want to know if its possible to change price of jewelery according to their actual daily market rates....automatically it should be....please help me

0
92
Member Avatar for markii.borabon_1

I have simple php code here, where basically asking to display the value of query : <?php $table = "tbl_product"; /******************MULTIPLE QUERIES*******************/ if($tbl_code==999){$condition = " WHERE (category = 'wellington') OR (category = 'hivis') OR (category = 'tools') OR (category = 'waterproof') ";} else if($tbl_code==998){$condition = " WHERE category = 'wellington' …

Member Avatar for markii.borabon_1
0
277
Member Avatar for kaprikorn07

Hi All, Please let me know the steps to install PHP, MySQL and PHPMyAdmin on RHEL machines.

Member Avatar for veedeoo
0
193
Member Avatar for rchawdhari

Hi all, I have two db, one db "latestdb" which have latest six months records second db "backupdb" which have oldest records of "latestdb" and this records deleted from "latestdb" I have a query which should return records from both db. Query will return new records from "latestdb" and old …

Member Avatar for rchawdhari
0
217
Member Avatar for Dani

So I currently am trying to insert a row into a MEMORY table but only if the primary key doesn't already exist. I'm using INSERT IGNORE but I was reading, much to my surprise, that INSERT IGNORE is actually slower than INSERT ... ON DUPLICATE KEY, but that letting the …

Member Avatar for pritaeas
0
430
Member Avatar for dipakatcvrca

Hi All, While going through my project work, I just came across a situation, where I needed to alter my table. I needed to add a column at the beginning of the table, i.e. the first column of the table. We have syntax for appending a column to a table …

Member Avatar for faucon
0
5K
Member Avatar for Nurul_2

Hello. I need some help to update two table.. This is my coding: $query = "UPDATE br.discharged_Date, b.book_Status SET br.patron_ID = b.patron_ID FROM borrow br INNER JOIN book b ON br.patron_ID = b.patron_ID WHERE b.patron_ID = '$patron_ID'";

Member Avatar for kamini_1
0
181
Member Avatar for filipgothic

Hello, I have page with several sections, in each section form with submit button which will load table and execute mysql queries. I need help to make long tables in more pages, or at least make scroll so user don't have to take long time to go from part to …

Member Avatar for filipgothic
0
268
Member Avatar for metalix

first create the table [CODE] create table images ( image_id serial, filename varchar(255) not null, mime_type varchar(255) not null, file_size int not null, file_data longblob not null, primary key (image_id), index (filename) ); [/CODE] the file to output the images to the browser [B]picsrc.php[/B] [CODE]<?PHP //detect if image is called …

Member Avatar for guruparthi
0
1K
Member Avatar for bradly.spicer

Hey! Long time no speak ^.^ I've been trying to make a query which would follow this logic (Which works in phpMyAdmin): UPDATE member_food SET food_id=12 WHERE member_id=4 AND food_type="breakfast" However, when I do it in PHP: $sql_breakfast1 = "UPDATE member_food SET food_id ='$breakfast1' WHERE member_id='$id' AND food_type='breakfast'"; if ($mysqli->query($sql_breakfast1) …

Member Avatar for bradly.spicer
0
131
Member Avatar for Richtofen345

Hi, I am trying to connect to mysql from php Below is the sample code i used. [COLOR="Green"]<?php <?php $username = "root"; $password = "pwd"; $hostname = "localhost"; $dbh = mysql_connect($hostname, $username, $password) or die("Unable to connect to MySQL"); print "Connected to MySQL<br>"; mysql_close($dbh); ?>[/COLOR] The problem here is I …

Member Avatar for Deepika_6
0
2K
Member Avatar for RodneyzPc

Hi..I sure hope you can help me ! 2 years ago you helped with a Update Form and I've been trying to adapt the form to my mySQL Database.As I'm just learning and trying to figure some of this out I've seemed to have hit a road block. . . …

Member Avatar for RodneyzPc
0
443
Member Avatar for HuePig

Hi, im trying to transform a string to make it a date $date1 = '$month/$day/$year'; //in jS value form type="number" $date2 = strtotime($date1); $date3 = date('Y-m-d',$date2); The problem is that when I SET date = $date3 the database saves 0000-00-00. what am I doing wrong??

Member Avatar for diafol
0
271
Member Avatar for Isaac_4

Here is a simple way to insert into a database that isn't much harder than using string concatenation - which we all know is very dangerous due to SQL injection attacks. Put the code snippet into `database.php`. Now, in a script handling a form post, such as `post_reply.php`: <?php require_once("database.php"); …

Member Avatar for diafol
4
505
Member Avatar for coolseancool

<?php require_once'start.php'; require_once'twitteroauth.php'; function cs( $string ) { if ( function_exists( "get_magic_quotes_gpc" ) && get_magic_quotes_gpc( ) ) { $string = stripslashes( $string ); } else if ( !get_magic_quotes_gpc( ) ) { $string = addslashes( $string ); } $string = @mysql_real_escape_string( @$string ); return $string; } if (!empty($_GET['get']) && $_GET['get'] == …

Member Avatar for matrixdevuk
0
314

The End.