9,022 Topics

Member Avatar for
Member Avatar for mangesh5588

I have 1 data gridview. in that first is ID column . for that i assign a auto index number with sql server (isidentiyt). the next colomn is response id, for this column also i want autonumber id like 1,2,3,4..... . i see we cant assign to index identity with …

Member Avatar for srikanthkadem
0
334
Member Avatar for vickyfin

These are just the tables.. STU(SSN [pk], Name, Addr) CLASS(Crs_id[pk,fk], Term[pk], Sect[pk], Fac_id[fk]) COURSE(Crs_id[pk], Description)CLASS_TAKEN (Stu_SSN[pk,fk], Crs_id[pk,fk], FAC(SSN [pk], Name, Dept) Term[pk,fk], Sect[pk,fk], Grade) CORE_CRS(Crs_id[pk,fk]) * term indicates year(4) & semester(1) (i.e, 20091 = Sp 2009) List the names of all faculty members who have taught every course in the …

Member Avatar for vickyfin
0
148
Member Avatar for pezza

Hi, I have managed to get a nested query to work partly, but i need to somehow add another nest, which i cannot get to work. To explain more, i wanted to firstly find records that did not exist in another table, to which i used the following [CODE] SELECT …

Member Avatar for pezza
0
119
Member Avatar for G-bot

I am developing a vb.net application that retrieves a recordset from a sql database with a large amount of records (30000 records) I need to process each record separately according to its contents. Is there a way of doing this in a faster method than iterating through each record?

0
69
Member Avatar for drynish

Hello! :) I have a small issue with an AFTER UPDATE Triger I implemented on one table of my db. In my trigger, I do some validation and update others (not in inserted or deleted) rows of my table. Thoses rows are updated but are not triggering my trigger (similar …

Member Avatar for drynish
0
130
Member Avatar for bajanpoet

This set of code below shows all SQL Server Agent jobs that have failed for the date 200.03.29. The run_date column is an integer, but I want to run the code in such a way that the resultset is automatically generated for the day before the current date. The code …

Member Avatar for bajanpoet
0
163
Member Avatar for sonakrish

Hiiii alll At present am doin a small project in windows application with C# as its code behind language. Now am in problem that i'm not able to connect sql server with my application. Its throwing an error that[COLOR="Red"] "sql default settings does not allow remote connections. connection can not …

Member Avatar for ddanbe
0
92
Member Avatar for blackbr

-I am using vs2008's table adapters for a DAL for several tables. -I have a computed field (FirstLastName) in my Lead table. -If I try to generate insert/update logic, the sql aborts when it tries to update the computed field. -So I dropped the field from the primary select, with …

0
68
Member Avatar for BobLewiston

Some of you may have seen my earlier thread “PasswordHash NULL problem”. I’ve started a new thread because investigation has shown that the problem is actually quite different than I previously stated. Also please note that this is unrelated to another of my previous threads, “dataAdapter.Update problem”, which incidentally has …

0
59
Member Avatar for raiko098

hey guys. . .im having a problem with my update code in vb.net.. . look at my screenshot attachment the column time_out is the problem. . . here's the code i used [CODE] Private Sub Button2_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button2.Click Dim timeout As String Dim …

Member Avatar for Teme64
0
98
Member Avatar for BobLewiston

When I try to save a new (inserted) record in an SQL database, I get the following System.Runtime.InteropServices.ExternalException message: [QUOTE]Cannot insert the value NULL into column 'PasswordHash', table 'AdventureWorks.Person.Contact'; column does not allow nulls. INSERT fails. The statement has been terminated.[/QUOTE] I have to either find out how to insert …

0
70
Member Avatar for Member #503558

i have a list of data from database, when i click on an item from this list the value from list should go to the database through SQL criteria, but it doesn't happen, it throws "Data Type mismatch in criteria expression error" (error is hightighted with red in code part). …

Member Avatar for vb5prgrmr
0
144
Member Avatar for BobLewiston

When I try to save a new (inserted) record via the following code: [CODE]DataRow row = dataTable.Rows [currRec]; // update data in DataSet from data entry WinForm row.BeginEdit (); row ["Title"] = txtTitle.Text; row ["FirstName"] = txtFirstName.Text; row ["MiddleName"] = txtMiddleName.Text; row ["LastName"] = txtLastName.Text; row ["Suffix"] = txtSuffix.Text; row …

0
47
Member Avatar for BobLewiston

Most databases have multiple users. For these databases it is a good idea to auto-increment the identity column. I understand that an SQL identity column is not incremented until the newly-created record is inserted. I guess this means the identity column is incremented when you actually reconnect to the database …

0
49
Member Avatar for kunal123

hii all, im trying to connect remote sq server using in c++ using CDatabase class. im getting an sql error Connection Failed SQL State '01000' SQL Server Error 14: [Microsoft][ODBC SQL Server Driver][DBNETLIB]ConnectionOpen (Invalid Instance()). SQL State '08001' Connection Failed SQL Server Error 14: [Microsoft][ODBC SQL Server Driver][DBNETLIB]Invalid connection the …

Member Avatar for MrSpigot
0
171
Member Avatar for GRaymer

I'm running into problems with my XML format when I generate it with SQL. I'm using SQL Server 2005. I have a query that uses FOR XML PATH that will return XML for me but it does work well with the formatting. I'm not a XML guru but when I …

0
54
Member Avatar for debeginin

I just got started with ms sql server2000,and I need a big favor from the the house,which is:please what softwares do I really need to install to get started?

Member Avatar for debeginin
0
81
Member Avatar for Tank50

Hi guys I have a problem in my project.Below I mention the coding I wrote it for testing purpose. In below coding the second while loop never run,only [CODE] SqlDataReader reader = DbCon.Get_Invoices(); int x = 0; while (reader.Read()) { x++; [B][COLOR="Red"] 1[/COLOR][/B] } MessageBox.Show(x.ToString()); chart2.DataBindCrossTable(reader, "ExecutiveCode", "Date1", "Total", ""); …

Member Avatar for Tank50
0
159
Member Avatar for freshfitz

I need to merge 2 notes fields in a sql database This select script gets me what I need how do I merge notes into Technote, I have a function to filter out the characters in the phone number that's what the stripped is [CODE]Select db1.dbo.customer.cust_no, db1.dbo.customer.Phone_home, db1.dbo.customer.technote,db2.dbo.customers.notes from db2.dbo.customers …

Member Avatar for dickersonka
0
96
Member Avatar for shers

Hi, I'm using SQL 2008 Express with a multi user VB.NET Windows application. Do I have to add each user to the SQL user account? Does NT Authority\SYSTEM work? I do not know how this works. So far I have NT Authority\SYSTEM in the Security-Logins of the Server. But do …

0
52
Member Avatar for Tank50

Hi Once I complie below coding part,it give me error meassage.The Error Meassage is Error . [COLOR="Red"]The name 'CurrentOutLet' does not exist in the current context[/COLOR] BelowI write my coding [CODE]. public SqlDataReader Current_outletReport(string code, string startdate, string enddate) { try { SqlDataReader CurrentOutLet; SqlConnection con; string str = "SELECT …

Member Avatar for Tank50
0
112
Member Avatar for MJV

I have the following code that executes an sql stored procedure and I pass a customer name and customer contact to the procedure to use to create a new record in a table. When I execute the stored procedure in sql it inputs the customer and contact in the new …

Member Avatar for JerryShaw
0
132
Member Avatar for brianhickey

Hey Guys, I was wondering could someone point me in the right direction. Getting an error: SqlDateTime overflow. Must be between 1/1/1753 12:00:00 AM and 12/31/9999 11:59:59 PM. What my code is doing is checking for the earliest date in one table(tblBookedTimes) and assigning this to earlydatestart. Then I want …

Member Avatar for JerryShaw
0
115
Member Avatar for chanchito

Hello there, I am in the need of some serious guidance/advice/direction. I am comfortable and familiar with creating DB's, however my knowledge/skills/abilities simply revolve around MS Access. I have been approached by someone that wants their existing web based DB to be overhauled. They have provided me with a very …

Member Avatar for Stylish
0
103
Member Avatar for yorockk

hiii all, iam doing a project in asp.net and the back end is sql server. so when i tried the connection code it gives me an server error "Cannot open database "C:/Program Files/Microsoft SQL Server/MSSQL.1/MSSQL/Data/projdb.mdf" requested by the login. The login failed. Login failed for user 'YOGESH\Owner'. "

Member Avatar for greeny_1984
0
182
Member Avatar for shers

Hi, I have developed a VB.NET Windows multi-user database application. This application is used within the company. The back end is SQL 2008 Express. The connection string is given in the application settings, so obviously it goes to the app.config file. This was done to change the SQL server in …

0
56
Member Avatar for shers

Hi, I'm working on a multi user VB.Net windows application with back end as SQL Server 2008 Express. The SQL Server is installed on the intranet network drive. This is the connection string I will be using. Is this correct? Data Source=.\SQLEXPRESS;AttachDbFilename=Q:\Database\PrintDB.mdf;Integrated Security=True;Connect Timeout=30;User Instance=True Thanks

Member Avatar for shers
0
156
Member Avatar for aman_dba

hi friends i am connecting to sql server with java through eclipse as IDE. here's my base connectivity class to sql server public class BaseDAO { public Connection getConnection() throws Exception { String userName = "aman"; String password = "password"; String url = "jdbc:microsoft:sqlserver://localhost:1433;DatabaseName=amandb"; // step 1 Class.forName("com.microsoft.sqlserver.jdbc.SQLServerDriver").newInstance(); // Step …

Member Avatar for aman_dba
0
119
Member Avatar for BobLewiston

Using Visual C# 2008 Express and SQL Server 2008 Express, I would like to insert new records into database "AdventureWorks", table "Person.Contact". To my surprise, this table's int-value identity column "ContactID" does not appear to be auto-increment. I don't know how to confirm for sure that this is so. (I …

0
61
Member Avatar for ITech

hi,, it seems thet i am posting too much inthe forum .what to do.i am busy with a project to finish.. ye, i just wanted to ask i have a money datatype in my table SPAINFO in sql server2005 i have done the connectin and its working fine.. the problem …

Member Avatar for ctrl-alt-del
0
108
Member Avatar for mem81

Hello, I spent hours wondering why this statement doesn`t work. I would like to insert record in a table if it doesn`t exist already.If record exists then a message will come out saying record exists. The values for the record to be inserted are current selection in combos on a …

0
68
Member Avatar for newMeg

Hi, I'm stuck in a gridview operation. Baiscally i have an sql that select filesize from database. I need to convert the file ti Giga byte. So i cant find a method to do it in sql, what i plan to do is. Get the result from the sql, convert …

Member Avatar for vizy
0
235
Member Avatar for jchandramouli

Hi, I got a table with datas that has alphanumeric values like : 1230-544,15C5487,132DE78. Now i need to extract only integers fomr these datas and convert to bigint. The other characters have no impact in my query. Is there way to produce a data like that? Thanks in advance. Mouli

0
55
Member Avatar for ntk

I have an existing table: [code=sql]CREAT TABLE Course (CourseNo int NOT NULL PRIMARY KEY, CourseName varchar NOT NULL StudentNo int NOT NULL REFERENCES Student (StudentNo)) [/code] Is it possible to code the following change in T-SQL: Introduce a new column called CourseID (int NOT NULL) and make it the PK? …

Member Avatar for urtrivedi
0
84
Member Avatar for emilio

hi i would like to write a trigger for the basic operations on a table : insert, delete, update. i know the basic syntax: [CODE=sql]create trigger on tbl_MyReports for insert,delete,update as[/CODE] my question is how can i know which rows changed ? if i inserted or deleted or updated a …

Member Avatar for urtrivedi
0
163
Member Avatar for TBotNik

All, Have a form with over 189 controls on it and trying to automate the save. I currently use the following script to init the fields: [code] On Error GoTo Err_Msg For Each ctl In Targetform.Controls ' 100 = Label, 106 = CheckBox, 109 = TextBox, 111 = ComboBox Select …

Member Avatar for TBotNik
0
105
Member Avatar for BobLewiston

I can read in an SQL table ("Person.Contact") from AdventureWorks and step through it one row at a time, but when I try to save a record, either one I'm inserting or one I'm editting, I get the following exception: Incorrect syntax near ','. Must declare scalar variable "@ContactID". Here's …

Member Avatar for BobLewiston
0
148
Member Avatar for blerina12

Hello guys. I hope you can help me with this problem. I have created a table (office) with two fields: id and location. Id is set to autonumber. I want to fill the table through a form which displays the id and takes the location. The program works fine but …

0
57
Member Avatar for kehar

Hi, I would like to replace the ACCESS with SQL Server 2000 enterprise edition. But I have the following problems: 1. While installing SQL should I install as Server or Client. 2. How to connect the SQL with VB 6 for saving,retrieving, modifying data using ADODB connectivity. Pl help me …

Member Avatar for vb5prgrmr
0
117
Member Avatar for harcaype

hi. my thread title seems strange but its really about comparing unlike values as an output. I want all values that are not LIKE the other values. To make things clearer. Here's my query: [ICODE]SELECT Records.[Officer ID], Records.[Plate Number], Records.[Violation Commited], Violations.[Violation Code], Records.[Street Name], Records.[City of Apprehension], Records.[Vehicle Category], …

Member Avatar for edgarlip
0
168
Member Avatar for cmwslw

Hello everyone! This is my first post on DaniWeb. Recently I have been working on a chart tracking system that utilizes MSSQL for a doctors' office. Now that I have finished it, I need a good way to deploy it across 50-100 computers in the office. The program will certainly …

0
61
Member Avatar for muhammad ismail

Hi every body plz inform me that how to take back up in vb.net using sqlserver. thanks for cooperation

Member Avatar for crazyhorse09
0
99
Member Avatar for casio2003uk

just wanted to know how i can input a search facility to my webpage, which is on short courses. i want it to retrieve information from my database to display on my web page. my webpage is linked to an MS Access database. if anyone could help me u would …

0
40
Member Avatar for danarashad

I am getting the following error sometimes. When the user load gets heavy I'll receive the following error. Would puting cftransaction around my update statements work? ODBC Error Code = 40001 (Serialization failure) DiagnosticsODBC Error Code = 40001 (Serialization failure Microsoft ODBC SQL Server Driver SQL Server Transaction (Process ID …

0
118
Member Avatar for cyberlan

Hi All, I am new to c#programming, actually I'm supporting our shop floor application, It uses a c# and MS SQL 2005 as a back-end. My problem is that when my server uses a time zone (GMT + 8, +7, +6 etc..), the application works fine but when I try …

Member Avatar for alc6379
0
173
Member Avatar for arvin2006

what's wrong with the code, it doesn's display the data based on the SQL query: Private Sub cmdSearch_Click() On Error GoTo Notfound squery = "": squery = "Select * from tblStation where Station like " & txtStation.Text & "" Call ExecuteCommand With Me .txtStation = rs!Station .cboCluster = rs!Cluster .txtArea …

Member Avatar for arvin2006
0
154
Member Avatar for chriscross86

hi, there..im having difficulties instaalling the microsoft SQL server. i need this to connect to the ASP.NET application.I am getting results that there is a 'cluster node failure' and I am having a lot of difficulties in encountering this. basically, i don't know where to find this cluster properties in …

0
60
Member Avatar for Lido98

HI I am very pleased to join this forum I am new to SQL programming , I am facing a challenge I need to copy the data from one table in one sql server to the same table in enother SQL Server From Server A table (Employee) To Server B …

Member Avatar for Lido98
0
1K
Member Avatar for sham

Hello, I created command object in DataEnvironment. Now I wish to change to command object's Sql Text since table name gets changed depending upon year of working.

Member Avatar for RahulV
0
330
Member Avatar for dan0

I have an application that needs the report server URL for that application's sql instance. Based on the fact that it is an instance the report server URL should be: [QUOTE]http://servername/reportserver$InstanceName[/QUOTE] When I enter the above, on the server that has the SQL server instance, the web-page displays the report …

0
51

The End.