9,022 Topics
how to calculate rank in selected record set in sql server 2000 can u help me?
hi i am using sql server 2003. can we get the position of record / row index in sql server while retrieving records? like in some case we fetch records as per our criteria. And if that time need to know the postion of particular record then? how to get …
Hi, I have used oledb connection with sql to populate one of my listbox with data from the database. However, I have to remove. on click of a button. the information from a specific table called 'Salary'. The problem that I am having is that when I tried to remove …
I have a table having columns like values, like this col1 col2 col3 1000 10 2 1000 20 3 1000 30 4 2000 10 5 2000 20 6 2000 30 7 3000 10 8 3000 20 9 3000 30 10 I want to fetch records like if i enter col2 …
hi, I developed one application in visual basic 6.0 with the backend of Sql server 2000. I want this application can be run in all client level. what i did is i installed windows 2003 server and sql server 2000 in one system and i copied the exe file of …
Hi, I am trying to install a database from a backup file of a now deleted database. What happened was that the data file was at D:\SQLData\DatabasesMyDatabase_data.mdf, instead of D:\SQLData\Databases\MyDatabase_data.mdf so we wanted to move it. The main DBA here showed me a ‘quick’ way to fix this was by …
hi all, Table 1: ID | COL1 1 | 1 1 | 13 1 | 64 Table 2: ID | COL1 1 | 14 1 | 13 Output needed: ID | COl 1 | 1 1 | 13 1 | 14 1 | 64 How will i accomplish this??? Thanks …
I have a function which have return type DataRow and the parameters for the fucntion are the parameters for the stored procedure. I have to execute the Stored Procedure with given parameters and populate the datarow so that the return will be the populated DataRow with the output of the …
Hi, I am a newbie for MSSQL. Previously, I was given a question regarding MSSQL. Although the interview had over, but I am curious to find out on how to solve the question below: There are 2 tables, NAMES (ID INT IDENTITY(1,1), NAME SYSNAME) and RELATIONSHIPS (NAMEID INT, PARENT_NAMEID INT) …
Hello i want 2add the name of the person who logged in at the top of the page, but the name comes from a SQL database called details, but the username and password is kept in another table called member they both are linked by id, this code below luks …
Hi all. I have setup phpbb3 successfully in the past with MYSQL. Fast and easy. But my friend has a server that only supports MSSQL. The phpbb3 setup programs states only that "MSSQL Server 2000+ via ODBC is available." I have been spoiled using all the tolls Godaddy has to …
Hi- Here is my question. People, where I work, friends of mine, other programmers, etc. are always talking about "best practices" in application design. Specifically, people are taught/told to minimize the number of SQL queries sent. Now, here is the thing, I am personally under the impression that it doesn't …
Hi, I'm trying to save some data taken from a ISO-8859-1 encoded page into a SQL SERVER 2005. The problem I have is that when I retrieve the information and put it in a XML there are characters missing. I'm using the URLEncoder.encode method to escape the "bad" characters from …
Greetings, I'm using Flash MX connecting to an MS Access database via JET. I've stored dates using Flash/Jet into my database as 'dd/mm/yyyy hh:mm:ss' into a DATE/TIME field. However I can't update because of the WHERE clause as I am not specifying the date correctly. I believe syntax wise I …
Hello all, hope i can get some help on this one as im not brilliant with my database scripts. I have table "A" and table "B", table "A" contains information on a portfolio and table "B" is a joining table which connects this table to a user of the system …
Hi, If someone can help me with this I'd really appreciate it! I installed SQL Server 2000 Standard Edition on Windows Server 2003. This server is due to take over from our present Windows 2000 Server. It was my first time doing a SQL install, so I ended up calling …
Hi I'm writing an application which basically takes images from pixelink camera and does some calculations on them. I need to monitor the status of the system for 2 things: presence of camera and connection to SQL server. I also have a preview feature. Right now it's all being done …
hi there, I am trying to make my service to insert to a database when it starts as follows : [CODE]protected override void OnStart(string[] args) { base.OnStart(args); string query; id += 1; SqlCommand comm; conn = new SqlConnection("my connection string"); query = "insert into myTable values('" + id + "'lamya'" …
Greetings, I have a perplexing problem. I'm writing a small C# Application. I need to insert an file path into a database table. I'm using SQL Server 2005. This is the first time I've done much with SQL Server (I have had experience with other DB platforms though), so please …
hi, I have a table with two columns. i want to insert into first column the values of 2nd column where it is between 7 and 10. the table is #temp as well. so i can not use views... i need to make a function. can you guys please help …
I have the following sql statement in VB6 (latest VB SP, Win XP, SP2) that works fine in ado to sql server 2k5 but does not work in ado to access 2k3. [B]"Select ID, Make, Model, PlsPerBBL, Size, Processor, Location, From MeterData Where MeterNo = 'FQ-805 8" IN'"[/B]. I know …
I have a problem on making user login, because I am not able to set up the roles and users in my Asp.net configurations. When I choose security I get this message "[COLOR="Red"]Unable to connect to SQL Server database.[/COLOR] " and when I try to choose a provider and select …
I have looked at the syntax of SQL/XML query and tried to run a sample query. But not able to write my query using it. Can someone provide a tested and working SQL/XML?
Hy :) , I need help please ! :-/ I am developping an application with vb.net and sql server .I have a form containing a datagridview ,textboxes ,bindingsource and bindingnavigator . I want that the columns of the selectedrow of datagridview appear and change in textboxes when the selectedrow is …
Input from text box as text(not number) and by button click need all values from the sql table to be viewed in the datagridview. eg:deptname as input in textbox, and by button click take all values from table [B]matching this deptname[/B] and get output in datagridview. Can anyone help me …
i have made a simple login page with 2 textboxes for username and password and a button to login. the usernames and passwords are in an sql database . how would i go about retrieving the username and password from the database. i have tried a select where statement If …
Hi, I have two table like this: [QUOTE][B][COLOR="Red"]quote_tb:[/COLOR][/B] [B][U]ID item vendor quote[/U][/B] 11 a v1 100 11 a v2 200 11 b v1 400 11 b v2 300 11 c v1 555 11 c v2 777 22 a v1 122 22 a v2 222 22 b v1 322 22 b …
Hi, Wondering if anyone can help me overcome this curious problem... I suppose its both a maths problem and SQL problem... If anyone can help with the Maths OR the SQL would be very helpful! Synopsis: Capture the value of the current 'credit' of a user. Similar to that of …
select myColumn from myTable1 union select myColumn from myTable2
I have two tables - products and productpropertyvalue I need to select multiple fields from the productpropertyvalue as it corresponds to the product id. The script I am using is select a.id, a.productname, a.siteprice, b.propertyvalue from product a, productpropertyvalue b where a.id = b.productid and propertyid=590 This allows me to …
How do i store images in the database and retreive them in vb.net? Please help.... Thanks in advance
select CASE WHEN FirstColumn IS NULL THEN '' ELSE FirstColumn END + ' ' + CASE WHEN SecondColumn IS NULL THEN '' ELSE SecondColumn END as ResultColumn from myTable
today i came across to an sql problem from one of the threads in the database forum : to solve the problem i created a table named "names" having these columns : PKID | name | lastname and i entered some rows having the same values for name and the …
I am trying to implement an example of the built in login and createuser wizard. the ony problem is, (and this may be really retarded of me) is that when i publish it out to a web server it doesn't work. Of course, it works perfect locally. Does the aspnetdb.mdf …
hi everyone, I need to know what are the services that sql server has. e.g. reporting etc. can you guys give me a list of these services. thanks
Here is data EnqSrNo 9 9 9 9 9 9 9 9 9 9 9 9 9 9 9 9 9 9 8 8 8 8 8 8 8 8 8 8 8 8 8 8 8 8 8 8 11 11 11 11 11 11 11 11 11 11 …
hi, im using VS.net 2005 for developing a web application.im using stored procedure for inserting records into database.i want to insert time and task for a selcetd employee but its not working. kindly help me.her's my stored procedure: [CODE] create PROCEDURE [dbo].[AssignAndStore] -- Add the parameters for the stored procedure …
Hi, Is it possible to install SQL 2000 and SQL 2005 server on a single server? If yes then will it create any problem? Thanks, Kailash
In Turkey we use "." as thousand seperator and "," as decimal seperator. If you are working with currencies in sqlserver, and if the money columns is of type "money" then the problem occurs beause of the seperator issue since in its default mode sql server accepts "," as thousand …
How to insert big html markup with white spaces(i.e. line breaks) and single and double quotation marks to sql server : To insert that big html markup to ms sql server, i tried to copy the markup and paste it to the sql server table cell first. It didnt work, …
sql cache dependency allows for cached data to be evicted and refreshed when it becomes stale. Basically ASP.NET checks for the changes in the datatable in sql server, if it finds one, it refreshes the cached data. Polling based sql cache dependency is very easy to configure as follows : …
I have a form that is classic asp that basically collects some info and sends it to an email account. What I really to do is have an email reminder option added. The form is a monthly report and the idea is to have an option for the reminder. The …
hi, im using VS.net 2005 for developing a web application.im using stored procedure for inserting records into database.i want to insert time and task for a selcetd employee but its not working. kindly help me.her's my stored procedure: [CODE] create PROCEDURE [dbo].[AssignAndStore] -- Add the parameters for the stored procedure …
hii,,guys,,i m using asp.net2005 and sql server 2005...in my page i have used gridview and sql datasource,i m able to edit,update and delete the records,,the problem is tht for 1 column i would lik to use a dropdown list instead of textbox when i am in edit or update mode,,,heres …
Hi I want to write a query which will return me Sum(MarkU) and also the avg. Which is something like (Sum(Sum(MarkU)))/5 in mathematically operation or TotMark = Sum(MarkU) AvgMark = TotMark / 5 I hope you get an idea what i need. How to write this type of query in …
Hi there. i would like this procedure to delete all rows in 'sale' where date_modified < (getdate() +0.02) and all the related rows from 'sale_detail' and 'sale_address' i have written the code below, but ti think this might only delete one row from sale and its related rows in the …
Hi, currently I have a shared web hosting with MS SQL server 2000 database. I have already implemented the database, with all the data inside the database, on the server. Now I wish to copy the whole database (.mdf) down to my PC, in case I wanna change hosting or …
I have an application that was written for me by a programmer who represented VFP as the "best thing since sliced bread" and that would be robust for many years in the future and more importantly handle huge customer databases over a LAN instantly. Now, after two years the server …
If you have a column, of data type = INT, with the following numbers as separate rows. 1 3 4 5 7 10 How can you write a sql statement where you can calculate the nearest number to any give input. Example , if the input is 9 ? (the …
hi brother i have a code which saves arecord but it gives an error syntax in insert in to statement. this is ma code. arequest for a collection or an alternative code. Private Sub cmdsave_Click() Dim findpas As String Dim cnnadd As ADODB.Connection Dim rsadd As ADODB.Recordset Set cnnadd = …
The End.