Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations strongm on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Default Values 0 to ""

Status
Not open for further replies.

troix

Technical User
Jan 20, 2004
46
US
I have about 250 fields (this is one momma of a database). Is there a RAPID way in the table to change all the 0's to "" (empty set)?
 
How are ya troix . . . . .

Have you tried an [blue]Update Query[/blue]?

Calvin.gif
See Ya! . . . . . .
 
There is no query yet.

Just the table. and all the default values are "0". I want NO default.
 
try some overtime...
i dont think there is a way to change default values (table field properties) using code

sorry for the glib remark

"My God! It's full of stars...
 
well, it's not glib, it's just true. *sigh* Why doesn't Microsoft make it where you can have NO default?
 
Have you considered the DefaultValue property of the Field object, member of the Fields collection of the TableDef object ?

Hope This Helps, PH.
Want to get great answers to your Tek-Tips questions? Have a look at FAQ219-2884 or FAQ222-2244
 
PHV

can you ellaborate on that?
sounds like you know what you are talking about and sounds like a timesaver

"My God! It's full of stars...
 
Tip: you have to reference the Microsoft DAO 3.x Object library.
Then feel free to play with the <F2> and <F1> keys.

Hope This Helps, PH.
Want to get great answers to your Tek-Tips questions? Have a look at FAQ219-2884 or FAQ222-2244
 
Hi

You do not mention if the fields in question are of type text, or number. If there are of type text, you can set the default value in the table definition (in design view) to "" instead of zero.

From your description of the problem I take it that all 250 fields are in one table? (question table design here?).

You can manipulate table design in code, using (as PVH says) the tabledef object of the DAO library

Also you can use DDL SQL commands (ALTER TABLE etc)




Regards

Ken Reay
Freelance Solutions Developer
Boldon Information Systems Ltd
Website needs upgrading, but for now - UK
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top