473,387 Members | 1,621 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,387 software developers and data experts.

converting field type in active database

When I designed my db in several tables I used unsigned integer fields
to hold an integer that each bit was a 'flag'. Now I realize that the
set field type does just what I was trying to accomplish. Is it safe to
convert the field(s) from uint to set and keep their current values?

Obviously all external programming (queries) will have to be adjusted,
but it seems to make more sense to use the set type.

Bill
Oct 30 '05 #1
2 1380
On Sun, 30 Oct 2005 17:38:01 +0000, William Gill wrote:
When I designed my db in several tables I used unsigned integer fields
to hold an integer that each bit was a 'flag'. Now I realize that the
set field type does just what I was trying to accomplish. Is it safe to
convert the field(s) from uint to set and keep their current values?


Probably! Maybe!

But why not just insert a brand new field with your set type then:
UPDATE {table}
SET {NewSetField} =
See how it works out alongside the original int field.

When you are happy everything works, you can delete the old
int field.
Thomas Bartkus
Oct 31 '05 #2
With the added benefit of having both fields to test against in external
queries, until I get everything updated.

Thanks,

Bill

Thomas Bartkus wrote:
On Sun, 30 Oct 2005 17:38:01 +0000, William Gill wrote:

When I designed my db in several tables I used unsigned integer fields
to hold an integer that each bit was a 'flag'. Now I realize that the
set field type does just what I was trying to accomplish. Is it safe to
convert the field(s) from uint to set and keep their current values?

Probably! Maybe!

But why not just insert a brand new field with your set type then:
UPDATE {table}
SET {NewSetField} =
See how it works out alongside the original int field.

When you are happy everything works, you can delete the old
int field.
Thomas Bartkus

Oct 31 '05 #3

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

13
by: | last post by:
I have an Access database used to track donor pledges. In it, there is a table that contains three fields for each donor: Gift_Amount, Gift_Per_Year, and Matching_Gift_Ratio. The following...
2
by: Christopher W. Douglas | last post by:
I am working on a project in VB.NET using Visual Studio.NET 2003. I use dialog windows to get user information, and throw exceptions when there are user errors, such as leaving a field blank or...
6
by: Larry R Harrison Jr | last post by:
I have a database I'm designing in Access 97. I have a custom field in a query which looks in {Table of Documents} and shows them all. It then needs a "latest revision number," stored in another...
2
by: Asbjørn Ulsberg | last post by:
Hi. I'm trying to convert Brady Hegberg's great RTF2HTML VB 6.0 module to C#. I've managed to convert the VB code to VB.NET, which gave me the following code: Option Strict On Option...
9
by: Pam Ammond | last post by:
I need the code to update the database when Save is clicked and a text field has changed. This should be very easy since I used Microsoft's wizards for the OleDBAdapter and OleDBConnection, and...
5
by: amitbadgi | last post by:
Hi guys, I am getting the following error in teh insert statement , I am converting this asp application to asp.net, here is teh error, Exception Details:...
9
by: anupamjain | last post by:
Hi, After 2 weeks of search/hit-and-trial I finally thought to revert to the group to find solution to my problem.(something I should have done much earlier) This is the deal : On a JSP...
12
by: Frederik Vanderhaeghe | last post by:
Hi, I have a problem converting text to a double. Why doesn't the code work: If Not (txtdocbedrag.Text = "") Then Select Case ddlBedrag.SelectedIndex Case 0 Case 1
5
by: Alan T | last post by:
Currently our SQL Server 2000 database table field is using char to store as boolean, ie. "T" or "F". Now we change the field from char to bit field. I am not sure how it has impact on the C#...
0
by: taylorcarr | last post by:
A Canon printer is a smart device known for being advanced, efficient, and reliable. It is designed for home, office, and hybrid workspace use and can also be used for a variety of purposes. However,...
0
by: Charles Arthur | last post by:
How do i turn on java script on a villaon, callus and itel keypad mobile phone
0
by: aa123db | last post by:
Variable and constants Use var or let for variables and const fror constants. Var foo ='bar'; Let foo ='bar';const baz ='bar'; Functions function $name$ ($parameters$) { } ...
0
by: ryjfgjl | last post by:
In our work, we often receive Excel tables with data in the same format. If we want to analyze these data, it can be difficult to analyze them because the data is spread across multiple Excel files...
0
BarryA
by: BarryA | last post by:
What are the essential steps and strategies outlined in the Data Structures and Algorithms (DSA) roadmap for aspiring data scientists? How can individuals effectively utilize this roadmap to progress...
0
by: Hystou | last post by:
There are some requirements for setting up RAID: 1. The motherboard and BIOS support RAID configuration. 2. The motherboard has 2 or more available SATA protocol SSD/HDD slots (including MSATA, M.2...
0
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However,...
0
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can...
0
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers,...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.