[AccessD] (Simple?) Problem Creating a "Yes/No" [Data Type] F ield in a MakeTable Query

Mark A Matte markamatte at hotmail.com
Thu Sep 11 13:35:19 CDT 2003


Alan,

Not sure of your exact requirements...but if it is creating the same table 
over and over...why not created the table you need...and then use a DELETE 
query followed by an APPEND query each time instead of recreating the table?

Just a second thought...If it is an AUTONUMBER field keeping you from using 
this method...you can create an AUTONUMBER that starts over each time you 
run the APPEND query in VBA.

Hope it helps.

Thanks,

Mark


>From: "Ron  Allen" <chizotz at charter.net>
>Reply-To: Access Developers discussion and problem 
>solving<accessd at databaseadvisors.com>
>To: Access Developers discussion and problem 
>solving<accessd at databaseadvisors.com>
>Subject: Re: [AccessD] (Simple?) Problem Creating a "Yes/No" [Data Type] 
>F	ield in a MakeTable Query
>Date: Thu, 11 Sep 2003 13:54:25 -0400
>
>Hi Alan,
>
>If I understand what you're looking to do, I don't think it can be done 
>exactly that way. I don't know of a way to change the lookup type of a 
>table programatically, and I'm as certain as I can be that it can't be done 
>as part of the SQL.
>
>I handle this type of situation, usually, by creating the table and setting 
>the properties, then using an append query instead of a make table.
>
>However, you can resolve the problem easily by just changing the "0" to a 0 
>(converting it or however else works for you), which will be saved as a 
>numeric, and since booleans are actually numbers (0 or 1) your checkboxes 
>on forms will work fine. Unless you're giving your user access to the table 
>directly of course...
>
>HTH,
>
>Ron
>
>
>
>
>>Susan, Arthur, Rocky, William, Jim, John, Doris, Jim Lawrence, et al:
>>
>>I need help with an (easy?) Access problem - and I just know that somebody
>>on
>>this list knows the answer.
>>
>>I am working on a "Make Table" query which will have to be used (and 
>>reused)
>>repeatedly to create the same table from scratch.  One of the field cells 
>>in
>>this query is created (in the QBE pane) from an expression.  The 
>>expression
>>is
>>as follows:
>>
>>       Record_Select_Flag: "0"
>>
>>The corresponding phrase/clause for this expression (in SQL view) is:
>>
>>       "0" AS [Record_Select_Flag] INTO <table-name>
>>
>>Here's my problem.  The data type of the field created by this expression 
>>is
>>a
>>"Text" field.  I would like to create a "Yes/No" checkbox field rather 
>>than
>>a
>>"Text" field.  (Actually, a "Yes/No" field will work just fine.)  Can 
>>anyone
>>tell me how to modify the expression to create a "Yes/No" field?
>>
>>I've been searching the Access "Help" library, but so far I haven't found
>>the
>>answer ...
>_______________________________________________
>AccessD mailing list
>AccessD at databaseadvisors.com
>http://databaseadvisors.com/mailman/listinfo/accessd
>Website: http://www.databaseadvisors.com

_________________________________________________________________
Get a FREE computer virus scan online from McAfee. 
http://clinic.mcafee.com/clinic/ibuy/campaign.asp?cid=3963



More information about the AccessD mailing list