10,940 Topics

Member Avatar for
Member Avatar for bolfescu

hy i'm having problem with this mysql qry, i dont whant to insert in the db if its empty the field, ive tryied with is NULL, but its not working... $qry=mysql_query("INSERT INTO trans_autista (autista, ditta) SELECT * FROM (SELECT '$trans_autista', '$cat') AS tmp WHERE NOT EXISTS ( SELECT autista FROM …

Member Avatar for bolfescu
0
220
Member Avatar for darragh.mcmahon.5

Hi guys Im trying to save a combobox selected item to my database but i cant get it working, it saves "user" instead of the username that is stored in the combobox, any suggestions? here's a snippett Try '----------------Sends the message------------------------------------------------------------------- MysqlConn.Open() ' opening the connection to the DB Dim …

Member Avatar for darragh.mcmahon.5
0
2K
Member Avatar for kevwood

i am trying to write a script that stores information from a html form into a mysql db. i have had the code work to stoer the information into the db but have since modified the code to accomodate the image up load also. i wan the code to stoe …

Member Avatar for kevwood
0
1K
Member Avatar for JosephHanh

Need help with the quiz problem. I want to set time limit for each question in quiz module (say 30 seconds) and after that time, the form will auto submit the question (auto submit = no option selected = unanswered). There are 3 questions, so total time limit is 90 …

Member Avatar for minitauros
0
183
Member Avatar for subbu_1

I have a database table named with books. it consists of something like below ex database given below, user is trying to search the value by author or title and based on category ex: if user search for adapt by selecting fiction need display both adapt and adaxx below is …

Member Avatar for subbu_1
0
196
Member Avatar for subbu_1

if query passed in search box by selecting the category as fiction or whatever it may be, it should search in both title and author, if value got in title then no need to search in author, if not need to search in author, $search = $_POST['searchvalue']; //assume search value …

Member Avatar for subbu_1
0
270
Member Avatar for PulsarScript

![Untitled1.jpg](/attachments/large/4/af84738d3622fd36115e8d4a78a992f1.jpg "align-center") Hi all,how do i do cascade on delete and update on this to tables,i have database,once i enter lecturer i can not delete because of constraints between this 2 tables.I tried in Lecturer table choose cascade on delete and update,not allowed,if do from module table same story. ![Untitled.jpg](/attachments/large/4/7437ddeb602b1183a2451fa886597054.jpg …

0
106
Member Avatar for asaidi

Hi i have a table day position 1 1 1 2 1 3 1 4 2 1 2 2 2 3 2 4 3 1 3 2 3 3 3 4 4 1 4 2 4 3 4 4 how i can order my day the same way as the …

Member Avatar for diafol
0
80
Member Avatar for jacob21

Chats table maintain chat history b/w users and agent.Type(0,1,2) indicates start and end point of chat by user/agent. Please suggest how we cam give each chat a unique session For Example Chat b/w company_id(5969) and user_id(67) has 1 unique chat id. Not Sure Is it possible in query or have …

Member Avatar for AleMonteiro
0
222
Member Avatar for asaidi

Hi how i can use this sql in php.. SET @a = 0; UPDATE van SET position = @a:=@a+1 where day='2';===>can be variable it goes from 2 to 30 thanks

Member Avatar for asaidi
0
280
Member Avatar for Mushfik

Hello. Please look at the code below and tell me the correct code for it please. here is the message i get.."Warning: mysql_fetch_array() expects parameter 1 to be resource, boolean given" <?php include("function.php"); ?> <?php include("header.php"); ?> <?php include("headscript.php"); ?> <script type="text/javascript"> function noAcc(){ $.fallr('show', { icon : 'error', content …

Member Avatar for Mushfik
0
469
Member Avatar for ramsiva

This code is not working INSERT INTO student_profile set student_id =MAX(student_id )+1; any body help me, my table student_id is abc0001, while inserting another student details it will be abc0002 but not working.

Member Avatar for ramsiva
0
129
Member Avatar for MAtkins

I've got 4 tables: divisions (ID, Division) teams (ID, Team) scores(ID, RelationID, Score) relatives (ID, RelationID, FieldID, ValID) The relatives table is to 'link' divisions and teams by RelationID The FieldID defines the table (1=divisions; 2=teams) The ValID = the ID of the given table. So, my fk is a …

Member Avatar for MAtkins
0
364
Member Avatar for kevwood

hi all, i had this code working yesterday (to an extent any way lol). the first part of the code seems to be working correctly an tells me i am connected to the db. but then i am getting a an error saying no db selected. here is the code …

Member Avatar for kevwood
0
198
Member Avatar for Chris920

I am running a unmanaged VPS - CentOS 6, 1gig of ram, 60gig storage, 256mb Vswap my.conf file: [mysqld] datadir=/var/lib/mysql socket=/var/lib/mysql/mysql.sock user=mysql symbolic-links=0 max_connections=100 max_user_connections=30 max_allowed_packet=64M wait_timeout=30 interactive_timeout=50 query_cache_type=1 query_cache_size=4M query_cache_limit=1M long_query_time=5 thread_cache_size=4 key_buffer_size=16M table_open_cache=80 log-queries-not-using-indexes log-slow-queries=/var/log/mysql/log-slow-queries.log #innodb_use_native_aio = 0 innodb_file_per_table [mysqld_safe] log-error=/var/log/mysqld.log pid-file=/var/run/mysqld/mysqld.pid MySql tuning logs: ![myturner.png](/attachments/large/4/1956cd6cace6d0b9912f6a38d4d3f912.png "align-center") ![myturnprimer.png](/attachments/large/4/5860e0cc711113ecbe783cad32fdaa7b.png …

Member Avatar for Chris920
0
376
Member Avatar for baloch123

Hi Hope,everyone is doing good out there. I need some help regarding which strategy to use for one of my projects. Here are the project details I want to generate PDF forms, by gathering data from user.There are different questions to ask and based on each answer,we will ask next …

Member Avatar for baloch123
0
736
Member Avatar for socialmd

This is the report.php view [CODE] if(isset($_POST["addReport"])) { $report = new Report(); $report->employee_id = $_POST["employee_id"]; $report->date = $_POST["date"]; $report->job_id = $_POST["job_id"]; $report->description = $_POST["description"]; $report->attachment = file_get_contents($_FILES['attachment']['tmp_name']); for($i = 0; $i < count($_POST['date_range']); $i++) { $report->request_date[$i] = $_POST["request_date"]; } for($i = 0; $i < count($_POST['date_range']); $i++) { $report->quantity[$i] = $_POST["quantity"]; …

Member Avatar for Ashvin_1
0
5K
Member Avatar for cngerra

I'm still a noob in JavaFX, I can print the content of the table that I query, the problem is that I want the content to be placed inside the tableview. This is the code that I have done. public class TableViewController implements Initializable{ @FXML private TableView<studentInfo> tblViewer = new …

Member Avatar for bharath_5
0
7K
Member Avatar for sathish_nadu

i tried to upload some data from csv to MySql data base. but it not working someone help me on this. the below one is my code #!/usr/bin/perl -w use DBI; use strict; use TEXT::CSV; use warnings; my $driver = "mysql"; my $database = "test"; my $host = "localhost" my …

Member Avatar for class11a
0
203
Member Avatar for Sunil_13

Hi, I need MYSQL coding for develop a MLM Single Leg Plan as per below plan :- 1 Root 2 Child in sponser of 1 3 Child can be sponser with root or 1 4 Child can be sponser with root, child 1 or child 2 as on...... please help …

Member Avatar for pritaeas
0
59
Member Avatar for mangel.murti

HI All , i have an offer table like offer_id , user_id , no_of_clicks , price...etc i want to fetch records and show to user like "best selling offer" , "value for money". best selling offer means the offer which sell more and displaying those offers to users. but what …

Member Avatar for diafol
0
155
Member Avatar for altjen

Hi every one. I post a topic similar with this at mobile development section but posted here too because I need help from a VB.net programmer I want to create a software for my windows phone 8.1 but already stucked on online database. I tried to use this VB code …

Member Avatar for altjen
0
673
Member Avatar for sohail_bloke
Member Avatar for ehpratah

Hi everyone i need some help down here. i am trying to connect multiple db and at the same time i want to sum the value of the column. what i have right now is this SELECT SUM(total) as branch1sales FROM icm.sales UNION SELECT sum(total) as branch2sales FROM hism.sales its …

Member Avatar for ehpratah
0
331
Member Avatar for sriprasadk

Hi, I would like to know if can we update one table's values while we insert or update values of another table. Both these table have relation but can not be joined directly. They have to joined with the help of a third table which has a common key needed …

Member Avatar for djjeavons
0
129
Member Avatar for asaidi

Hi i m trying to count all for example vans who has record as Van1,Van2 ETC... physically in the database i have more than 200 Van1 ..but with select count gives me only 6.. SELECT COUNT(*) FROM route WHERE van='Van1' the rsult only 6 for others 0 and so any …

Member Avatar for asaidi
0
138
Member Avatar for Rhyan

Hi there. Hope somebody can advise on the following: I have created a table into my database which has a coloumn with datatype defined as DATE. The normal MySQL date order is YYYY-MM-DD, however I need to enter it in format DD-MM-YYYY. I am using php to insert data into …

Member Avatar for Gakwaya Joel
0
17K
Member Avatar for altjen

Hi every one. I want to create a software for my windows phone 8.1 but already stucked on online database. I tried to use this VB code that I use for 1 of my softwares Mysqlconn = New MySqlConnection Mysqlconn.ConnectionString = "server=db4free.net;Port=3306; user id=a****; password=******; database=****" Try Mysqlconn.Open() Dim Query …

0
58
Member Avatar for fireburner29

how to insert multiple checkbox values in multiple rows mysql database using php pdo? Please give multiple insert option Here is my script: $create = sizeof(isset($_POST['create']) ? $_POST['create'] : array()); $edit = sizeof(isset($_POST['edit']) ? $_POST['edit'] : array()); $delete = sizeof(isset($_POST['delete']) ? $_POST['delete'] : array()); $view = sizeof(isset($_POST['view']) ? $_POST['view'] : …

0
197
Member Avatar for yaragalla_mural

Hi i have a table called hospitails. the table structure is as below **Hospitals:-** Hospital_id Bigint name varchar(45) city_id bigint district_id bigint state_id bigint now i need to search hospitals based on name,city_id,district_id,state_id. the query must cntain all the 4 fields. when user does not provide any of the value …

Member Avatar for pclfw
0
148

The End.