|
its up to you but if i were you i would use transaction. (depending uopn your words about the writing process)
anonymous wrote:
So are application like MSWord,...also adopts transactions ?
can you be more clear?
|
|
|
|
|
MSWord is not a database, so it neither supports not needs transactions. If you are making multiple related changes to multiple taples (for example: insert new row in main table, insert new row(s) in detail table using foreign key from new row in main table) you should always enclose these in a single transaction, so that if one of the dependant changes fails (an unexpected null value, an out of range value, etc. ) you can easily cancel the preceding changes (rollback the transaction). Adding the transaction support is relatively easy, and should not take much code,
Transactions really have nothing to do specifically with multi-user scenarios, instead the have to do with keeping changes consistent - preventing partial updates that could corrupt the data.
Absolute faith corrupts as absolutely as absolute power
Eric Hoffer
The opposite of the religious fanatic is not the fanatical atheist but the gentle cynic who cares not whether there is a god or not.
Eric Hoffer
|
|
|
|
|
When creating table in access, the default item is not null.
How to create item which could be null?
Thanks!
|
|
|
|
|
Open the table in design view. Select the field in which you wish to allow nulls
set the "Required" entry to "no". If the field is a text or memo type, you may also want to set "allow zero length" to yes (this allows an empty string as a value, not the same as a null).
Absolute faith corrupts as absolutely as absolute power
Eric Hoffer
The opposite of the religious fanatic is not the fanatical atheist but the gentle cynic who cares not whether there is a god or not.
Eric Hoffer
|
|
|
|
|
hii all,
Am working with sql server 2000,i have a series problem my database log file is expanding in unusual way; my data file(MDF) just 50MB but my log is 2 GB can u imagine that. i know i can restrict size but why its expanding like this?
marcoryos
|
|
|
|
|
Wow 2 GB is quite a lot, make sure there are no errors, you can avoid using the LOG but changing to Simple. Thought to let you know!
Al
|
|
|
|
|
What is the recovery model set to? Unless it is 'simple', the log file will not be automatically truncated, but will continue to grow until you truncate it either by issuing a 'backup log with truncate only' or by making a full backup and truncating the log as part of the backup command. Otherwise all changes are saved for possible use in restoring the database changes since the last backup. The 'simple' recovery model says you are only going to depend on backups and won't use logs for restore, so the log will be truncated as soon as changes are commited.
Absolute faith corrupts as absolutely as absolute power
Eric Hoffer
The opposite of the religious fanatic is not the fanatical atheist but the gentle cynic who cares not whether there is a god or not.
Eric Hoffer
|
|
|
|
|
Hi Folks,
Using
MS-SQL Server 2000
Windows XP Pro
VB 6
I need to find the actual data size for a nvarch, datefields, money etc.. using a SQL Statement. When I use the 'sp_column' command in SQL Server it doesn't tell me the actual field length that has been defined for the Table. Does anyone have a SQL Statement that can give me the correct field size. If you look at the table definition is Enterprise Manager it shows me the correct values. Just need to replicate this info into a sql statement.
Cheers,
Narly..
Narly
|
|
|
|
|
sp_help returns the correct length for columns (in the 2nd recordset returned). You could extract the code that generates the second recordset and create your own sproc...
Absolute faith corrupts as absolutely as absolute power
Eric Hoffer
The opposite of the religious fanatic is not the fanatical atheist but the gentle cynic who cares not whether there is a god or not.
Eric Hoffer
|
|
|
|
|
Thanks Eric. I'll give it a try.
|
|
|
|
|
|
Absolute faith corrupts as absolutely as absolute power
Eric Hoffer
All that is necessary for the triumph of evil is that good men do nothing.
Edmund Burke
|
|
|
|
|
I want to know if you can call a store procedure in a datepart function. I am trying to pass the datepart dates that are created by a stored procedure. I am not sure that this is even possible. My main goal is to count work days between two given dates. I thought I could use the datepart function to count the 6th and 7th day. Than I could subtract their totals from the final count. The code I am trying is below.
select datepart(weekday, dbo.sp_work_day_count '45')
Scott Moore
Developer
|
|
|
|
|
Hi, I currently faced a problem on inserting decimal value from vb .net into SQLCE which declared as money data type. ANyone know how to solve this??
Thanks in advance!
|
|
|
|
|
How can I use DTS to migrate some tables and views from SQL server to a new access database?
I want to be able to do this programmatically, so that the windows application user can create an access database from an existing SQL server.
Thanks,
Martin
|
|
|
|
|
Search for "creating package dts" or see the samples in SQL Server manual. Or google for it. I found this[^] and this.[^]. Is this help?
<italic>Work hard, Work effectively.
|
|
|
|
|
|
Hi,
I was wondering if any one had some ideas or good places to look for help on a alphnumeric counter.
The count I want to put into place is one that starts at 'AAA000' and continues with 'AAA001' and so on. So when the number hits 999, the next record will have a id of 'AAB000'
Please let me know if you have any ideas or a good site to visit.
Thanks.
|
|
|
|
|
Can any body have idea about minimum and maximum values for the following factors for
sql server2000 if i want to monitor sql server2000
Total Memory - KB
SQL Cache Memory - KB
Lock Memory - KB
Optimizer Memory - KB
Connection Memory - KB
Granted WorkSpace Memory - KB
Memory Grants Pending -
Memory Grants Success -
Buffer Hit Ratio -
Page LookUps/Min -
Page Reads/Min -
Page Writes/Min -
Total Pages -
Database Pages -
Free Pages -
Please help me
T.I.A
Shashank
|
|
|
|
|
Hi,
I want to import data to the SQL server from one table to another.
My question is "Should the 2 tables be of same design structure"?
The table to were i need to copy the datas has extra fields.
Pls help
Ram
|
|
|
|
|
If your destination table has extra fields, you can define a constant value, or they need a default value.
Christian Graus - Microsoft MVP - C++
|
|
|
|
|
Anonymous wrote:
"Should the 2 tables be of same design structure"?
No, you can define the transformation, which field to copy and the desination
field.
<italic>Work hard, Work effectively.
|
|
|
|
|
Does anyone know of a programmatic way of finding which server(s) may be running, so a new client installation can be provided with a drop-down list of where the data may be held? There will be a defined instance in each case, so all servers to be found will be of the form "machinename\myinstance" - I just need to find possible values for 'machinename'. (pretty much like the facility in Enterprise Manager for finding a new server registration).
We are using C# (.NET 2003) but I can translate from other methods if required.
|
|
|
|
|
|
Many thanks Luis. This looks perfect.
And it seems I need to keep up with the times, Google is getting good for this sort of thing.
|
|
|
|