7,494 Archived Topics
Remove Filter ![]() | |
Hi all, I'm attempting to get some numbers from an XAL database (MS SQL Server 2005). My query is below. There are some conditions commented out. If I add either one of the lower ones the query executes in a matter of seconds but if I replace them with the … | |
Hi everyone. I'm using sqlite3 in Linux and I currently have a problem. I have a database and 2 tables in it: db1 and db2. db1 has 3 columns: empID, empName, empAddr. db2 has just 1 column: empID and its value is set to 0 by default. I created a … | |
I wish to delete all the tables that I have made so far........What should I do ???? Please help !!! Databases oracle | |
Hi, I need some help with this MySQL Update I've got three tables as below. tbl1 id eid quantity 1 3 2 2 4 3 tbl2 tid eid qnty status type 1 3 1 1 1 2 3 0 1 0 3 4 1 1 1 4 4 0 1 … Databases mysql | |
![]() | Alright this is a little hard to explain, but I have two tables of very different data. Both tables have a date timestamp. The timestamps are not going to match, but I need to join table2 on to table1 via the next date equal to or less than. So.. Table1 … Databases mysql |
Hello: I have a table where a column called [I]ActiveStatus[/I] (of datatype 'bit') I am trying to run a query on may contain values Boolean values or NULL. Which means, if there are 10 rows in the table, a likely scenario would have 5 NULLs, 2 FALSEs, and 3 TRUEs. … Databases mssql | |
Let's say that I want to retrieve rows from just one table and exclude rows with certain ID's. Hypothetical table: [CODE] +----+-------+------+ | id | value | type | +----+-------+------+ | 1 | foo | cool | +----+-------+------+ | 2 | bar | cool | +----+-------+------+ | 3 | lor … Databases mysql | |
I have a stored procedure where I need to insert from some other tables when those items do not exist in the original table. Here’s the stored procedure that I wrote. [CODE] ALTER PROCEDURE [dbo].[sp_CreateRequestedItems] AS BEGIN INSERT INTO dbo.RequestItems ([request], [applicationProfile]) --select from requests and profiles table into requestitems … Databases mssql | |
I made 10 tables for a project. But the first 9 tables along with the values that I entered, are saved in the database. But the last table is not able to save it's values. I have to enter the values every time I run SQL. It always shows "No … Databases oracle | |
I have the following three tables: ClassHeader ClassID Major TeacherClasses TeacherID ClassID StudentClasses TeacherID Major I want to select all TeacherClasses where the a given Major = ClassHeader.Major Databases mssql | |
Hello! I run SQL queries from JAVA program (an example is shown below). My question is: Is it possible to run SQL query, if column names are defined in an array and the array size is not known apriori? Thanks! [CODE] public void setQuery(String query) { try { int rs … | |
Hello! I’ve got three tables that I want to link together. When I try to upload images and text throught a form, the web browser show this error message: [QUOTE]Error, query failed 1452-Cannot add or update a child row: a foreign key constraint fails (`mn000532_almacen`.`images`, CONSTRAINT `images_ibfk_1` FOREIGN KEY (`itemID`) … Databases mysql web-browser | |
[CODE]<?php include("includes/connection.php");?> <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd"> <html xmlns="http://www.w3.org/1999/xhtml"> <head> <meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1" /> <title>Untitled Document</title> </head> <body> <?php echo $sql= "SELECT * FROM forms WHERE today >= CURDATE() - INTERVAL 30 DAY"; $result=mysql_query($sql); while($row=mysql_fetch_array($result)) {echo $City= $row['City']; echo $Name=$$row['Name'];} ?> </body> </html> [/CODE] i just … | |
O.K. I've been agonizing over this for some time now, in this website i'm building, every registered user is gonna have some data that he can review add update delete. what would be the best way to store this data? in sql?, so that we have this one huge table … | |
i want to concateneate my query with textfield value [I][B][COLOR="Green"]select tablename.columnname From TableName[/COLOR][/B][/I] lyk this Select tablename. & Me.textfield.text & from tablename plz tell me where m i doing wrong actually i m trying to only select single column by combo box.whenever combo box value is equal to column name … Databases mssql | |
Hey! I've got a SELECT query which fetches rows based on a search string using LIKE command. I was wondering, how could I make it to skip "The " from the beginning of the value? For example, I have TV series listed in the database, like "Futurama", "The Office", "The … Databases mysql | |
This SQL operation will get the desired Proposal_ID. [CODE]SELECT P.Proposal_ID, AVG(c.Task_Good_Idea) AS Average FROM proposals P, proposal_appraisal c LEFT OUTER JOIN users b ON (c.Evaluator_ID = b.User_ID) LEFT OUTER JOIN submission_status d ON (c.Primary_Evaluation_Status_ID = d.submission_status_ID) WHERE (P.Proposal_ID = c.Proposal_ID) AND P.Proposal_ID >= 931 AND d.Submission_Status_ID = 2 GROUP BY … Databases mysql | |
Hi, I've writen a stored procedure that is supposed to load 4 tables in a database that are to be used by a vendor to load their tables for an application we purchased from them. being that our data is on multiple servers, the query must read from two servers … Databases mssql | |
Hi there, How can I write a stored procedure to select a value from a table and return that value?? I have a table Employee, when I send the email as a parameter to the stored procedure, I should get the employee number (it should return the employee number) I … | |
Given the following two SQL operations: [CODE]select prod_Id, P.proposal_id, P.institution_Name from proposals P group by P.proposal_ID having mark >= 50 order by P.proposal_id desc select prod_id, P.proposal_id, PA.evaluator_ID, U.user_Given_Name, U.user_surname from users U, proposals P LEFT outer JOIN proposal_appraisal PA ON (P.proposal_Id = PA.proposal_id) where PA.evaluator_ID = U.user_id group by … Databases mysql | |
I have made 8 tables, that are connected with primary keys among each other......What command should I use, to delete all tables at once ???? Databases oracle | |
i have code [CODE]Protected Sub btn_submitt_Click(ByVal sender As Object, ByVal e As System.EventArgs) Handles btn_submitt.Click Try If (ddl_Country.SelectedItem.Text = "Select Country") Then Me.Label1.Visible = True Me.Label1.Text = "Please Select Country" Else Me.Label1.Visible = False Dim n As Int32 Dim connString As String = System.Configuration.ConfigurationManager.ConnectionStrings("containerConnectionString").ConnectionString Dim con As SqlConnection = New … | |
I have a machine logging production info to a database whenever certain conditions change state, so pretty much randomly throughout the day. The plant runs 24/7 so data is continuously flowing into it with about 500 entries in a 24 hour cycle. The shifts are strictly time based and are … Databases java-swing mysql | |
![]() | Hi I am a bit rusty with SQL, not used it for about 8 years so would appreciate a bit of help. I have three tables, normalised, organisation, stores org_name and org_id ativities stores activity_name and ativity_id org_activity stores org_id and activity_id I need to get a list that contains … Databases mysql ![]() |
hi, i'm using phpmyadmin & would like to create an additional field in the following table. Field // Type Collation Attributes Null Default Extra Action user_id // int(10) first_name //varchar(20) last_name // varchar(40) email // varchar(80) pass // char(40) user_level //tinyint(1) active // char(32) registration_date// datetime the field would be … Databases mysql | |
[CODE]create table items_avail ( pro_id varchar2(10) primary key, mod_id varchar2(5), comp_name varchar2(25) ); [/CODE] I wish to remove the primary key constraint......and add make the prod_id and mod_id as primary keys together. i.e. primary key(prod_id, mod_id) But he thing is this table is already connected to three more tables by … Databases oracle | |
I'm working on a mysql server 5.0.45 hosted on linux RHEL 5.0. 1. I've 2-tables as below: [INDENT]table1: acct_no VARCHAR(15) column1 varchar(10) table2: acct_no VARCHAR(12) column2 varchar(10)[/INDENT] In both the tables, there are many rows with identical A/c nos. 2. Of the below 2-queries, only the second one works. [INDENT][COLOR="maroon"]SELECT … Databases mysql | |
Can anyone please help me with installation of oracle 11g on windows 7 home basic 64 bit? On prerequisite check its giving an error that "this version is supported by os version up to 6.0 only and not by this version 6.1" Databases oracle | |
[CODE] create table item_avail ( pro_id int primary key, mod_id int, color varchar(10) ); create table Laptop ( pro_id int primary key, mod_id varchar(5) not null check (mod_id like "L%"), color varchar2(10), comp_name varchar2(20), RAM number(5), spaceHD number(4), foreign key (pro_id, mod_id, color) references item_avail (pro_id, mod_id, color) ); create … Databases oracle | |
Wasn't sure whether to put this with PHP or Mysql I'm having trouble with the below code, it only does the inner while loop once, while still cycling past it every time. It should update the "favourite" integer column in each "link" by checking if it's in the favourites of … Databases mysql | |
Hello Could help me get the right MySQL on my computer. I had it installed but it was a couple years ago. My cp crashed. I can't remeber how or what to install. All I have left is the script I used. I was running the command window one. that … Databases mysql | |
Hello Everyone, I hava design just a register page and a login page ,a user can register then login..during registration i used the password() for password field insert value to database. During login I used as password('_POST[pass]') and comparing with the inserted value but its not working .... I just … Databases database-design mysql | |
[code=sql]DELIMITER $$ DROP PROCEDURE IF EXISTS `hrprocess_temp`.`sp_alltabinsert1` $$ CREATE DEFINER=`invensis`@`%` PROCEDURE `sp_alltabinsert1`(empid varchar(10),fname varchar(45),lname varchar(45), fathername varchar(30),dob varchar(20),gender varchar(6),maritalstatus varchar(9),spousename varchar(15),children varchar(8), commadd varchar(250),permadd varchar(250),mobileno varchar(15),landlineno varchar(15),email varchar(40), languages varchar(25),nationality varchar(25),bloodgroup varchar(5),drivingno varchar(20),panno varchar(15), passportno varchar(15),imagepath varchar(100),resumepath varchar(1000),skill varchar(250),deptname varchar(30), Course varchar(20),Specialize varchar(35),institute varchar(25),PassYear varchar(10), Organization varchar(25),Designation varchar(25),FromDt varchar(15),ToDt varchar(15),ReasonsChange … Databases mysql | |
hi all i was wonder if its possible to join 3 tables, so i could see the result from the 3 tables. for example lets say that i have INVOICE(invoice_id, client_id,item_id) CLIENTS(id, client_name) ITEM(item_id, item_name) i want 1 table that shows: invoice_id, client_name,item_name is this possible? 10x! Databases oracle | |
Hello... Can anyone help me...? I have the problem when installing SQl Server 2008 on Vista.. The message is : The performance counter registry hive is corrupted... please I need it Quickly... thanks...... | |
I've looked at this from every angle, but can see nothing wrong. The MS Access table "LocationLinks" contains only 6 fields. LocationLinkKey - autonumber, primary key. LocationKey - long integer, required, indexed, duplicates OK LocationType - string length 4, not required, not indexed RelatedLocationKey - long integer, required, indexed, duplicates … Databases java microsoft-access sql | |
I'm trying to teach myself a bit more php/mysql so that I can implement better usability on my osCommerce site. I've set up a bit of space on the web server and the db server so that I can play about with stuff and I'm close to doing what I … Databases mysql php web-server | |
hi all, I am new to mssql but C# programmer, can anyone help me on how to merge columns from different tables to a single table in sql for example i've 4 tables and the first table has a,b,c,d columns second table has e,f,g,h thrid table has i, j, k, … | |
Hi folks I need some help! I have two tables the first contains account information, and the second contains flags that records in the account table may have. These are joined by the account?id. One account record may have several flags from the flag table. ie the following select select … | |
Is it possible to store images in oracle db, if yes then what will be the data type of the field.? Please illustrate with example....thanx a lot. Databases oracle | |
Hey guys, In my DB, i've got appointments set, and i need to select all appointments which are an hour or less away. For example i want to do something to the following (Dont worry, i know this wont work as is) [CODE]SELECT * FROM timetable WHERE time has one … Databases mysql | |
Hello all, I have msaccess that I use to insert data into a mysql database on a local in house server. Now what I would like to do is I have the below query [CODE] INSERT INTO User_logins ( GroupWiseID, ConnexLogin, [Password] ) SELECT NewHireIDs.[GW ID], NewHireIDs.[LIC ID], NewHireIDs.[ACD ID] … Databases microsoft-access sql | |
I'm looking to re-order a table while keeping the table's id column constant. ie, Links has entries in no particular order, whereas LinksPopular is a duplicated table but I want it ordered by category X, while leaving the id category unchanged. That way the first most popular is at id … Databases mysql | |
I have a query which generates an xml file from data collected. There are 2 columns in the data (reason, TotTime) but they are joined together into one column using the concat command. Currently the results are ordered by reason, but I want to limit my results to only the … Databases java-swing mysql xml | |
Hi, I am developing a program which requires access to my websites' MySQL. I keep getting errors trying to connect to it. My firewall is allowing the connection but MySQL won't accept it. How can I solve this problem? Thanks in advanced Kieran :) Databases mysql | |
Here are the 2 procedures in question and the code that I use to call it. I will follow it all up with the error that is being produced. [code] set ANSI_NULLS ON set QUOTED_IDENTIFIER ON GO ALTER Procedure [dbo].[usp_GetPropertyData]( @page int, @page_len int, @sortfield varchar(100), @desc bit ) as … Databases mssql | |
[B]hello..! required a help i want to store a date in sql server field...i set the field type is datetime..bt i jus want to save only Month and year ...kindly help me in it..! i m working with vb6 i set the date formate [/B] [COLOR="Green"]myDate = Format(cmbMonth1.Value, "MMMM-yy")[/COLOR] [B]bt … | |
Im Writing a c# Code that Takes an Excel Sheet ,creates the Corresponding SQl table and Dumps the data in a new table in SQL. Now My problem is: In the " create table" command , i have to specify the DATATYPE for the column !i.e. CREATE TABLE "table_name" ("column … | |
Hi guys, I'm trying to create the simplest of databases. The database needs all the standard tasks, such as: add record, delete record, show all records. I need this accessible on the internet, so anyone can check it out. I will probably put it in a password protected directory, unless … Databases mysql |
The End.