|
I can't give you numbers, but I've seen it bring a SQL server down when it was close to capacity, so don't profile when the system is close to failure. Also, only use it for relative ranking between batches, not for any absolute numbers.
I can imagine the sinking feeling one would have after ordering my book,
only to find a laughably ridiculous theory with demented logic once the book arrives - Mark McCutcheon
|
|
|
|
|
Hi, how do you configure SQL "Server Log" (NOT transaction log/ldf) to recycle every now and then? Say, everytime when "Server Log" size hit 50MB?
Thanks.
|
|
|
|
|
what is oj, it is used with from clause while joining tables
please explain fully
thank u
|
|
|
|
|
dev dhoundiyal wrote: what is oj
Well, my understanding was that OJ is an abbrebiation of Orange Juice.
dev dhoundiyal wrote: it is used with from clause while joining tables
Then I'm guessing it refers to the first letter each of OUTER JOIN . I have never heard it being refered to as OJ before. I suggest you don't use that as few people will understand you.
dev dhoundiyal wrote: please explain fully
There isn't space in a forum post to "explain fully" entire chapters of books are devoted to the subject.
A brief explanation is that an outer join takes all the rows on the left side and all the rows on the right side and joins them together, matching those that it can, leaving nulls in the columns where a match cannot be found.
Consider the following two tables:
A
key data
1 a
2 b
B
key data
1 d
3 e
A statement like this:
SELECT A.key AS aKey, A.data AS aData, B.key AS bKey, B.data AS bData
FROM A
OUTER JOIN B ON a.key = b.key Will produce a result like this:
aKey aData bKey bData
1 a 1 d
2 b null null
null null 3 e
By comparison, an INNER JOIN would have returned one row, the only row that matched (i.e. The row with key 1); a LEFT OUTER JOIN would have return two rows (all the rows in A [the left side] and any matching rows in B); a RIGHT OUTER JOIN would have returned two rows again (all the rows in B [the right side] and any matching rows in A)
Does this help?
ColinMackay.net
Scottish Developers are looking for speakers for user group sessions over the next few months. Do you want to know more?
|
|
|
|
|
That seems a pretty damn good explaination of an OJ to me
|
|
|
|
|
I'm trying to make a form or perhaps simply use Web Developer 2005 or SQL Server 2005 management to populate a database with pictures. So simply I want upload images to an sql database, if I make a form I would like to use asp.net.
Option 1
If I make the form using asp.net, i have no idea what to use to put them in that db. I have use db before with access to put text in the db, that's it.
Option 2
In Web Developer and SQL server I can run a query to pass the data into the db, but I don't know how to write sql besides the basic select, update, delete and insert into with basics one word string.
Can anybody give me a clue, link or code to do this...thanks
|
|
|
|
|
See here[^].
NOTE: Posting the same question in multiple forums is considered bad manners.
-- LuisR
Luis Alonso Ramos
Intelectix - Chihuahua, Mexico
Not much here: My CP Blog!
The amount of sleep the average person needs is five more minutes. -- Vikram A Punathambekar, Aug. 11, 2005
|
|
|
|
|
I want to create an application where is one Access database.
In this database there is table called customers.
I've made Crystal Report called CrystalReport1. When I start the program
it asks me for user name and password, server name and database name.
How can I create a report from password protected database in C#?
|
|
|
|
|
string cnnString = "Server=localhost;Port=3306;Database=tibia;Uid=client;Pwd=password";<br />
<br />
MySqlConnection cnx = new MySqlConnection(cnnString);<br />
<br />
string cmdText = "SELECT * FROM queue";<br />
MySqlCommand cmd = new MySqlCommand(cmdText, cnx);<br />
<br />
cnx.Open();<br />
<br />
MySqlDataAdapter myDataAdapter = new MySqlDataAdapter(cmdText, cnx);<br />
string szInsert = "INSERT INTO queue VALUES ('testing')";<br />
myDataAdapter.InsertCommand = new MySqlCommand(szInsert, cnx);<br />
<br />
cnx.Close();
I don't recieve an error and my database is not being updated. I can recieve data using close to the same code, but I can not send data to the database. See the problem? Thanks for the help!
|
|
|
|
|
Aren't you missing some kind of query execution method from the MySQLDataAdapter class? Your code you've supplied looks good as far as getting ready to execute the query. Try something like ExecuteReader() or whatever MySQLDataAdapter uses to execute the query specified in the InsertCommand attribute.
I hope this helps,
Paul
|
|
|
|
|
Wow, I can not believe I missed that.
Thanks a ton man.
|
|
|
|
|
Glad to be of help
PJC
|
|
|
|
|
Is there a function in MS SQL server to get the total size of the current database (or a single table) in KBs?
It's possible to get this information through Enterprise Manager but I would like to get it through C# code.
|
|
|
|
|
You may want to investigate the stored procedure called sys.sp_databases
It returns all of the databases that are online, along with their size, and
any remarks about the database.
I hope this is a starting point for you
Paul
|
|
|
|
|
Thank you very much. This is exactly what I needed!
|
|
|
|
|
You're very welcome
|
|
|
|
|
Hello
I would like to know more on how you call Stored Procedures to fill a datagrid?
Very new to the SQL / Dev world but would like to try the sys.sp_databases mentioned in this thread. If there is am example that would be great.
Thanks..
When people make you see red, be thankful your not colour blind.
|
|
|
|
|
This is off topic for this thread - You may wish to start your own thread to start a new topic.
ColinMackay.net
Scottish Developers are looking for speakers for user group sessions over the next few months. Do you want to know more?
|
|
|
|
|
I was relating it to your original reply regarding sys.sp_databases...
But your point it well taken...
Thanks for the fast response...
When people make you see red, be thankful your not colour blind.
|
|
|
|
|
You can fill a datagrid with a stored procedure like the one I mentioned to theaton. Instead of using an SQL query, you'd use the stored procedure and instead of commandType being query, you'd specify that you are calling a stored procedure.
I hope this helps some,
Paul
|
|
|
|
|
Hi there,
I've installed SQL Server 2005 and SQL Server 2000 side by side.
Now when I open SQL Server Management Studio it runs the SQL version 8 that belongs to SQL Server 2000.
How can I start with SQL Server 2005 (SQL 9.0) to create new database under the new features?
thank you.
|
|
|
|
|
Majid Shahabfar wrote: Now when I open SQL Server Management Studio it runs the SQL version 8 that belongs to SQL Server 2000.
When I open SQL Server Management Studio it gives me the option of which server I'd like to connect to. The default instance is the default option. And because the default instance is SQL Server 2000 that is selected. However, I can pull down the list and select the SQL Server 2005 database. Do you not see your SQL Server 2005 in that list?
Majid Shahabfar wrote: How can I start with SQL Server 2005 (SQL 9.0) to create new database under the new features?
It may be that SQL Server 2005 service is not running.
In the SQL Server 2005 folder in the Start-->All programs menu find Configuration-->SQL Server Configuration Manager and ensure the service is running.
Does this help?
ColinMackay.net
Scottish Developers are looking for speakers for user group sessions over the next few months. Do you want to know more?
|
|
|
|
|
No, I don't see SQL Server in that list.
In SQL Server Manager I have only SQL 2000 service and SQL Express edition service.
I can use SQL Server Express Edition but I really want to use the SQL Server 2005 Enterprise edition.
-- modified at 7:30 Saturday 25th February, 2006
|
|
|
|
|
Curious...Which one did you install first?
RageInTheMachine9532
"...a pungent, ghastly, stinky piece of cheese!" -- The Roaming Gnome
|
|
|
|
|
I've installed SQL Server 2000 first.
|
|
|
|