|
In sqlserver 2005 u can handle exceptions
using try catch block
but in sqlserver 2000
u have to rollback the transaction if any error occurs
That will be caught by @@error
"Aim to go where U have never been B4 and Strive to achieve it"
http://groups.yahoo.com/subscribe/dotnetforfreshres
http://himabinduvejella.blogspot.com
|
|
|
|
|
Hi:
how can i change the crystal report from portrait to Landscape in Design time ......
Thanks in Adv for viewing and replying.
Have a good day
|
|
|
|
|
while u are desing report right click in space choose Design->Printer Setup there u can make changes.(chose Landscape)
_____________________
Proud to be Albanian
_____________________
|
|
|
|
|
I have a Employee I want Add he in many groups : Group1 & Group 2 ....
I want create PROCEDURE use Transaction Insert Employee on groups
Can't U help me
Exameple: Emp is E001
Groups : Group1,Group2.....
|
|
|
|
|
|
I want to create a windows application which contains a datagridview control, and a ‘save’ button.
Once the form is loaded a table (Table1) will be populated into the datagridview automatically. Users can modify the data cell contents and then click the save button to update the MS access database file.
I setup the datasource and datamember of the datagridview porperty to be a simple MS Access datatable file db.mdb which only contains a table “Table1” with 2 fields, ‘ID’ (Text) and ‘value’(Number), 2 columns are displayed in the datagridview automatically.
Then I added a button_click event of the save button, and coding as below:
this.testTableTableAdapter.Connection.Open();
this.testTableTableAdapter.Update(this.dataSet.Table1);
this.testTableTableAdapter.Connection.Close();
Once the application is running, the values in Table1 are populated successfully into the datagridview, however after the user modified some of the values in the cells and then click ‘Save’, the MS Access database file is not updated.
I have checked that the dataset is updated as the user modifies the values, so the parameter of the Update method of the data adapter has no problem.
Could anyone give me a help, thanks.
|
|
|
|
|
Make sure your DataAdapter logic, including TableMappings, Fill, etc are all within a Try/Catch block, the you can print out the Exception.Message to see what is causing the I/O failure.
Good Luck
Mike Luster
CTI/IVR/Telephony SME
|
|
|
|
|
Where can I find information on how to convert an Access 2003 database to SQL Server 2005?
-- modified at 13:48 Monday 20th March, 2006
|
|
|
|
|
I just found the option at menu choice: Tools/Database Utilities/Upsizing.
|
|
|
|
|
I want to implement a search engine that will search in the tables of a database. Number of tables are fixed but these tables contains more than 1 lacs entry. Again user can search the given text in diffrent tables with diffrent column type. Can anyone please guide how to implement these kind of search ?
any suggestion or advice is welcome. Thanks in advance.
Arindam D. Tewary
|
|
|
|
|
Hello,
I am getting DB_E_DATAFIELD_OVERFLOW error while using the Value property of Field object.
Sample Code.
Set rs = cmd.Execute(, , adCmdText)
Set Field = rs.Fields(0)
MsgBox Field.Name
MsgBox Field.Type //Returned Value = 19 i.e Unsigned Long
MsgBox Field.Precision // Returned Value = 10
MsgBox Field.Value // Run-time error DB_E_DATAFIELD_OVERFLOW
Details
1. Using SQL Server Database.
2. Data type of the Column is Numeric. (Length = 9 , Precision = 10)
3. Values those need to be stored in the column are in range (0 - 4294967296).
Important Detail about Provider:
a. Using our own Provider to connect to the database.
b. Provider is using the some APIs, abstracted from us, to fetch the data.
c. Data from those APIs are returned in the form of unsigned long.
d. RecordSet is generated and data is returned to the client.
Please Help
Thanks in Advance...
Suraj Gupta
|
|
|
|
|
Just a guess, but don't you need a length of 10 in order to handle an unsigned long?
Chris Meech
I am Canadian. [heard in a local bar]
When I want privacy, I'll close the bathroom door. [Stan Shannon]
BAD DAY FOR: Friendly competition, as Ford Motor Co. declared the employee parking lot at its truck plant in Dearborn, Mich., off limits to vehicles built by rival companies. Workers have to drive a Ford to work, or park across the street. [CNNMoney.com]
Nice sig! [Tim Deveaux on Matt Newman's sig with a quote from me]
|
|
|
|
|
No, it is not required. It works fine.
At the first place itself data would not get entered if such was a case.
Thanks for replying.;)
Suraj Gupta
|
|
|
|
|
Database Restore Problem on MSDE.
I am using two database servers, SQL Server 2005 and MSDE in my application.
One module of this application provides database backup/restore tool using SQLDMO.dll.
In restore module I am killing currently connected users to that database before starting restore process.
It works fine with SQL Server 2005 but it fails on MSDE and it gives message "only user processes can be killed"
Then I tryied to kill connections using command KILL <spid> on MSDE but still it gives same error message.
Ex. If I am connected to test database using jc as user who has all the server role rights.
After this if I retrieve current spid's then it shows spid=7, user=jc, database=test etc.
When I try to kill this process then it fails on MSDE its giving message "only user processes can be killed"
Can anybody help me on this MSDE issue.
Thanks
Jitendra C.
|
|
|
|
|
Hi all
this is my first posting in this forum.
i am struck in a problem in asp.net 2.0.
i am using master file and a css file for my default page.
now i want the user change the css file attributes of the master file in the run time.
my question is that how can i do that?
if any one has an answer please let me know this.
thanks to all.
SP
sp
-- modified at 2:06 Monday 20th March, 2006
|
|
|
|
|
This thread should be in the ASP.NET section...
As for your question: could you provide more information. Becouse I really don't see what is the point of doing this...
Q:What does the derived class in C# tell to it's parent?
A:All your base are belong to us!
|
|
|
|
|
I have a slight problem and wondering if someone else has encountered this.
Host platform: Windows 2000 Server, SP4
- MySQL Server 5.0.18 was running perfectly.
- Added MSSQL 2000 to 2K Server and now MySQL is getting a signal to exit.
It is desirable to run both on my server, and access either one as needed. I am thinking someone must have ran into this before and know of any compatibility issues.
Thanks for your help!
Mike Luster
CTI/IVR/Telephony SME
|
|
|
|
|
I am guessing here, but maybe you should check the ports they are using...
Make shure they use different ports...
Q:What does the derived class in C# tell to it's parent?
A:All your base are belong to us!
|
|
|
|
|
CWIZO wrote: I am guessing here, but maybe you should check the ports they are using...
Make shure they use different ports...
Yes, check and make sure they are not the same. By default, MySQL is port 3306 and MSSQL 2000 is like 1433 (not 100% on this but close).
PJC
|
|
|
|
|
Yep, MySQL uses 3306, and MSSQL uses 1433 and 1434 I hear. I'll try reinstalling MySql at the expense of hosing MSSQL, lol Stay tuned.
Mike Luster
CTI/IVR/Telephony SME
|
|
|
|
|
Hi,
Im a newb to MS SQL so some help would be appreciated. I need to detect duplicated records in a DB by their email. Ive got the following code which works fine for displaying the email adress and the number of occurences -
sSQL = "SELECT *, COUNT(email) AS NumOccurrences FROM Contacts WHERE AccountHolderID = " & makeSQL(session("SAT_USERID")) & "GROUP BY email HAVING ( COUNT(email) > 1 )"
However i need to be able to display data associated with the email such as the username and firstname of each occurrance. So ultimately i need to display all records where the email adress of that record is also present in another record. Then display all the data associated with those records. I also need to group the matching emails together.
Im sure this must be possible, so your help would be rather good!
Thanks!!!!
|
|
|
|
|
You could consider current your SQL staterment as a View, then you create another SQL staterment that joint with above view on Email field. Hope that could work
-- modified at 5:36 Monday 20th March, 2006
|
|
|
|
|
Hi,
Im not sure what you mean. Could you give me an example?
Thanks!
|
|
|
|
|
SELECT a.*, b.* FROM Contacts AS a, (SELECT Email, COUNT(Email) AS NumOccurrences FROM Contacts GROUP BY Email HAVING NumOccurrences > 1) AS b WHERE a.Email=b.Email
Also, I dont really understand what you mean. So hope that work
|
|
|
|
|
nguyenvhn,
I tried the code you gave me and got the following error:
Microsoft OLE DB Provider for SQL Server error '80040e14' <br />
<br />
Invalid column name 'NumOccurrences'. <br />
Ok let me explain....
I have a table which holds members contact / address book. I need to determine if they have duplicate entries for the same email in their contacts. So for example:
Dave, Smith, Dave@mywebsite.com
and
D, Smith, Dave@mywebsite.com
would be considered duplicate entries because they both have the same email address. Because each member has often several thousand contacts, their maybe 4 or 5 copies of a contact.
So i need to be able to display all these duplicate contacts on screen, and grouped together so that for example all the
Dave@mywebsite.com 's are all grouped to gether on screen and all other duplicates are on screen eg:
D, Smith, Dave@mywebsite.com
Dave, Smith, Dave@mywebsite.com
Dve, Smith, Dave@mywebsite.com
Paul, Wills, Paul@wills.com
P, W, Paul@wills.com
etc etc.
Hope this makes it clearer?
So what would be the code i need for this?
Thanks for the help so far!!!!!
|
|
|
|