Hello there,I just want to ask if storing data in dbase is much better than storing it in the file system? Because for one, i am currenlty developing my thesis which uploads a blob.doc file to a web server (currently i'm using the localhost of ASP.NET) then retrieves it from the local hostAlso i want to know if im right at this, the localhost of ASP.NET is the same as the one of a natural web server on the net? Because i'm just thinking of uploading and downloading the files from a web server. Although our thesis defense didn't require us to really upload it on the net, we were advised to use a localhost on our PC's. I'll be just using my local server Is it ok to just use a web server for storing files than a database?
hello, I'm am looking for a smart solution for keeping history of changes in records in my sql database. Not only history of a record but also which user caused the change and when (I have the username in session). for now I added 4 fields to each table: "created by","created on","cancelled by",cancelled on", when the user create a record the 2 first fields are filled and and a user delete a record the two last fields are filled and the record is not really deleted but it won't be shown again (I'm using "where createdby is null"). this solution is taking the performance down and it does not solve the editing record tracking. creating new records and cancelling old ones for editing/changing solve that but than I m having problems with the primary key and relations to other tables. I tried also to use a table that holds records that descirbes every change in records in my tables. it's very hard to search old data that way. I know that oracle databases has a smart solution for history... please someone advise me.. Elad.
When I go to the database restore tab the "backup history" window shows the database backups and log backups from all the way back when the database was initially created. How do I purge the old database and log backup entries?
I'm creating a db to be used to store historical trades which will then be used to report on various strategies/returns etc...
I'm struggling with the correct way to store things like price etc...
Right now I have a table tStock which has pkStockId,StockName,Sector I have a table tPrice which stores the historical prices which has pkCounter,fkTickerId,fkDate,Price,Volume. This seems odd to me since dates are being repeated. Right now I have about 100 stocks in table tStock and the tPrice table has 10 years of price data for each stock so there are a date range of historical prices which is approximately 252,000 records. That isn't a ton but I will probably end up with 500+ stocks and 20 years of data. Am I storing this correctly? Right now I have the pkStockId indexed and the pkCounter index and I also created an indes using fkTickerId and fkDate. Is there a way to create the tables such that looking up a price is faster? The reason I would like it to be faster is that when analyzing the trade history I need to get the portfolio market values based on various dates so at a certain date I will sum all buys - all sales for every stockid in the portfolio table and then look up the prices for each to get the market value of the portfolio on a particular day. I feel like I am missing something in the design process but don't have experience in this so I am asking for help.
I have a system that basically stores a database within a database (I'msure lots have you have done this before in some form or another).At the end of the day, I'm storing the actual data generically in acolumn of type nvarchar(4000), but I want to add support for unlimitedtext. I want to do this in a smart fashion. Right now I am leaningtowards putting 2 nullable Value fields:ValueLong ntext nullableValueShort nvarchar(4000) nullableand dynamically storing the info in one or the other depending on thesize. ASP.NET does this exact very thing in it's Session State model;look at the ASPStateTempSessions table. This table has both aSessionItemShort of type varbinary (7000) and a SessionItemLong of typeImage.My question is, is it better to user varbinary (7000) and Image? I'mthinking maybe I should go down this path, simply because ASP.NET does,but I don't really know why. Does anyone know what would be the benifitof using varbinary and Image datatypes? If it's just to allow saving ofbinary data, then I don't really need that right now (and I don't thinkASP.NET does either). Are there any other reasons?thanks,dave
If there is a history kept somewhere of failover events of a database in an AO group? I have 2 replicas with automatic failover and I'm looking for a history of failovers.
best way to store questionnaire data in a database.Since different questionnairs have different questions and formats i.e dropdown, radio, checkboxes etc building such a database model becomes highly complex.
I've read that if data schema is complex and higly variable it may be better to use an xml document and store that in a databse. However I dont quite understand how you store xml to a database. Do you simply store the entire structure in something like a nvarchar column or is there some other way to store xml to a database.
If you store the entire structure to the databse then how do you query the content to generate reports.
What is the best way to restore a database from a folder of backups (including full, diff and log backups) without using the backup history in msdb?
I have a restore process that restores all backups on a regular schedule in order to fully verify their integrity. To do this, I use the backup history in msdb on each server that I'm monitoring. I had a thought the other day that I would be in trouble if I lost msdb. Then my backup history would only be as good as the last backup of msdb.
What I'd like to do is read a folder of backup files and generate a restore script up to a specified time. Would I use RESTORE HEADERONLY to do this? If so, would I use PowerShell to traverse each file in the folder?
I have a bit of a dilema, that maybe someone can give a reccomendation on. I have a vb app that will calculate a duration that a process runs in hours:minutes:seconds. My question is should I store this in the database as a date/time field or calculate total seconds and store it as an integer field? I will be using this field for basic summing calculations in the future. Thanks for any help.
Im currently storing an account id in a sql table. Is there any column data type that would presere the numbers but make it appear as a series of letters and nmumbers when someone looks at the database table?
Hi, can we keep a file like word file or html file in the sql server database? if yes, then can we search any thing in these stored file? regards mihir
hello ... i have a project this semester and i had to study is storing images in a database ( using Microsoft Access ) is good or bad ? so any one could tell me the advantages and the disadvantages please ... thanks bye
An odd question from me, I know, but this time, I assure you a twist.
I have a group that wants to store images in either a database or a file share, in order to make a certain website able to run on a load balanced web farm. These images are around 1KB each in size, and have a lifespan of exactly one use (think of graphs). I went a-googling, and found no shortage of articles that say "don't do it, but here's how you can do it", but I did not find any real hard statements as to why to not do it. Needless to say, this is hurting the case for not putting these images in the database. I have found an article that says images over 8KB will have worse performance, but I can not use that factoid here. For the moment, I have the developers leaning toward the fileshare, because they will be writing transaction logs all day, which will be more work than the fileshare needs to do....I think. The best I can do, is cut the text/image datatype overhead, and have them create the table as varbinary(2000), but even then, I don't like the look of the idea.
Anyone out there have good articles/whitepapers that detail the differences between writing single-use images to a fileshare vs. a SQL database? <baiting=blatant>Failing that, do any of the Microsoft development team have an opinion?</baiting>
Alternatively, what is the general opinion of keeping session state information in a database (because I bet that will be my next battle). I see .NET includes a session state server, but not being a programmer, I can not create an opbjective test.
Hy, could someone help me in this:In design mode, i want to put pictures in database. I made column namedpics, and its type as image. How can I put pictures or some address of thesepictures in that column, or i maybe need to put pictures in Add_Data folderand make reference from there, or what I need to do?could someone explain me that process of putting at least one picture indatabase, I'm using Microsoft SQL Server 2005thanks everyone
hi,I would like to store windows passwords and usernames in database.Please tell me where to start?What database can I use?Can I use free microsoft database?ThanksBart
Hey I currently have a foreach loop container working which scans a folder, loops through the files in this folder and then moves them to a new folder.
At the same time I also do an SQL insert into a table logging the details of the transfer.
What I would like to do next is to store the actual PDF in binary in my DB (varbinary format). How would I go about this ?
hi friends, i want to show images in repeater control dynamically. i want to store the image url in database like i have stored the images on onefolder c:images this will contain images how can i store and use the urls in database or atleast how can i show the images from the folder dynamically please help me out
Hi i am trying to store the checkbox values on my page to the database, but im stuck on what to do. I have the following code already;protected void Btn_Subscribe_Click(object sender, EventArgs e) {SqlConnection conn = new SqlConnection(ConfigurationManager.ConnectionStrings["streamConnectionString"].ConnectionString); string strSQL = "INSERT INTO Newsletter(emailAddress) VALUES (@emailAddress)";SqlCommand Command = new SqlCommand(strSQL, conn); Command.Parameters.Add("@emailAddress", SqlDbType.VarChar);Command.Parameters["@emailAddress"].Value = txtEmail.Text; conn.Open(); Command.ExecuteNonQuery(); conn.Close(); } How do i now insert the values from my checkbox, this is how i am setting the checkbox;public void Page_Load(object sender, EventArgs e) {ArrayList values;if(!IsPostBack) { //Build array of data to bind to checkboxlistvalues = new ArrayList(); values.Add("Sport");values.Add("Gardening");values.Add("technology"); AlertList.DataSource = values; AlertList.DataBind(); } If i am going about it the wrong way please let me know, thanks
Hi,I have a table which I need to store times in. What is the best way of doing this? The only way I can think of so far is to save the times as a datetime such as '1/1/1900 03:00 PM' then format the date as "hh:mm tt" so that the day isn't displayed. Is this the best method?Thanks,Curt.
I have records with 50 plus fields of data.I was thinking of writing all the fields data into a XML file and then store it in a SQL server database for retrieval later on.Is there anyway i can go about doing this?
Just a quick question to ask what is the best field to store the data held in a rich text box/control. Just want to make sure that i get it right first time you know. Not sure about the amount of characters that needs held but its going to be quite a lot as this field shall contain most of my pages content.
I am having a problem in a VB.NET application, i have a form that the user fills to store data in the database, the problem is that when i enter Arabic string, it gets stored in the database as question marks '??????' The database field type is nvarchar, anybody went across this problem?
What is the best approach for storing hierarchical data in a database? For example, if I need to store a tree menu system, how would I do that allowing for the most normalization within the database, using the least number of queries/resources when pulling the data out, and using the least amount of overhead both in storage and retrival?
I'm constructing an image gallery for my site and was wondering how to store the pictures in the database? Would the best way to do it, by storing the link instead of the image in the database?
How would I use the insert and select with it? :confused:
Which is better, to store the files onto the server's folders or to a database? I tried storing to MSSQL 2000 but the varbinary does not allow me to set "MAX" for the data type.