|
No problem. Glad to help.
|
|
|
|
|
I downloaded Oracle's ADO.net connector and added support for it in my database classes. That meant that I could access Oracle databases from my console and WinForms apps, including one that allows the user to enter ad hoc queries and view the schema.
|
|
|
|
|
SQLTools[^] if you want it lightweight.
TOra[^] is at the other end of the spectrum.
Both are opensource.
SQL Developer and Oracle Developer Tools for Visual Studio has already been mentioned. They are from Oracle and are supported, ... sort of.
You will also need to install some version of the Oracle Client which is available in several versions such as the normal Client, Instant Client or Oracle Data Provider for Dotnet.
Oracle Developer Tools for Visual Studio has the Client built in.
|
|
|
|
|
I save image to database using byte array to SQL server image type, if i save 10 MB image, is it going to be bigger or smaller in database?
|
|
|
|
|
10 Mb will remain just that, unless you use a CompressionStream .
Bastard Programmer from Hell
|
|
|
|
|
I had a programmer in a foreign country develop an application for me, I had to dismiss him because he would not finish the program on time. I asked him for the source code to MySQL db and he would not provide it. I paid him so that wasn't the issue. I need to move my application from one cloud server to another company and I need help in figuring out how to break the db code to move the application. There are a lot of connection points in and out of the db so I can't just copy the db and move it over.
Thanks
|
|
|
|
|
Isn't the password mentioned in the connectionstring?
Bastard Programmer from Hell
|
|
|
|
|
hello,
I have a table named: 'Applicant' having fields:
'id_Applicant', 'name,'date_of_birth','date_of_death'
the sql or oracle query is:
'Select all applicant who are alive on 30-05-2012'
Please it's urgent
thanks alot.
|
|
|
|
|
What have you tried so far?
The difficult we do right away...
...the impossible takes slightly longer.
|
|
|
|
|
m_safaaaa wrote: Please it's urgent
That's a big no no to say in a forum post. People will help you when they can. As the other poster has mentioned, what have you tried so far?
""Real programmers just throw a bunch of 1s and 0s at the computer to see what sticks" - Pete O'Hanlon
|
|
|
|
|
I suspect that 2012-05-30 just might possibly be between the date_of_birth and the date_of_death (or some date in the future if null).
You are using DATE or DATETIME fields, right? Right?
modified 9-Jun-12 17:11pm.
|
|
|
|
|
|
SELECT * FROM Applicant
WHERE Date_Of_Death > CONVERT(VARCHAR,'30-05-2012',106)
- Happy Coding -
Vishal Vashishta
|
|
|
|
|
Works great, if the guy is still alive today...
Your query selects all who have already died past that date - that's a difference.
|
|
|
|
|
Either date_fo_death is null or greater than the given date:
SELECT *
FROM Applicant
WHERE date_of_death is null
OR date_of_death>@somedate
|
|
|
|
|
SELECT
id_Applicant,
name,
date_of_birth,
date_of_death
FROM
Applicant
WHERE
'5/30/2012' BETWEEN date_of_birth AND ISNULL(date_of_death,'1/1/3000')
|
|
|
|
|
Just wondering what differences there are between these two connection methods in SSIS? We are connecting to SQL 2008 R2 databases.
Is one better performing than the other? Or is one easier to use? There does seem to be certain tasks that can only use one or the other.
|
|
|
|
|
An ADO.net connection will use the native client classes so it is better.
|
|
|
|
|
I am trying to insert string date to datetime column with the following way.(Sql2000)
CONVERT(DATETIME, @To, 103)
but this is not saving the DD/MM/YYYY format in the webserver, but it is working in my local machine.In the webserver sql it is saving as MM/DD/YYYY format.
|
|
|
|
|
Use a parameterized query, that will do the magic around the date format.
|
|
|
|
|
It is based on how the systems are setup. Cannot remember the SET command and have to go to work. Sorry.
|
|
|
|
|
SET DATEFORMAT DMY
that the one you were thinking of?
Lobster Thermidor aux crevettes with a Mornay sauce, served in a Provençale manner with shallots and aubergines, garnished with truffle pate, brandy and a fried egg on top and Spam - Monty Python Spam Sketch
|
|
|
|
|
|
Your string-representation is a culture-dependent format, a way of displaying a date in a specific culture. Date (and time) itself is not a string, but a number.
Make sure it's a DATE column in the database, and pass a Date (not a string ) to the query. Use parameters as suggested.
using (var con = new SqlConnection(connectionString))
using (var cmd = con.CreateCommand())
{
cmd.CommandText = "SELECT * FROM SomeTable WHERE MyDate = @MyDate";
cmd.Parameters.AddWithValue("@MyDate", DateTime.Now);
}
Bastard Programmer from Hell
|
|
|
|
|
the purpose of a database is to store information, not to format it. Store dates and datetimes in fields with the appropriate type, and let your applications take care of formatting when presenting results to the user. Do not try and have the database format stuff, you will get lots of trouble and never get satisfactory results.
And as others have said, use SQL parameters rather than SQL string concatenation, to feed dates and datetimes to the database; thus avoiding all conflicts with regional settings and the like.
|
|
|
|