When you create a field each field has a id number (field number) (how can you edit this number) 
Author Message
 When you create a field each field has a id number (field number) (how can you edit this number)

Does somebody now how ?

by example :> A Table by example  'Clients'

has 3 fields

- ClientID     [ Long]            Field number = 0
- Name        [ String]            Field number = 1
- LastName  [ String  ]        Field number = 2

Crystal Reports uses these numbers

but with ado and dao you can retrieve these numbers
but how can you edit these field numbers ?

With ADO OR DAO.



Tue, 25 Nov 2003 06:10:19 GMT  
 When you create a field each field has a id number (field number) (how can you edit this number)
What do you mean by "edit these field numbers"?

If you're looking to somehow change ClientID to be field 2, and LastName to
be field 0, change the order of the fields in your query.

If you're looking to do edits using the field numbers (rather than their
names), it's Recordset.Fields(n)

--
Doug Steele, Microsoft Access MVP
http://I.Am/DougSteele/


Quote:
> Does somebody now how ?

> by example :> A Table by example  'Clients'

> has 3 fields

> - ClientID     [ Long]            Field number = 0
> - Name        [ String]            Field number = 1
> - LastName  [ String  ]        Field number = 2

> Crystal Reports uses these numbers

> but with ado and dao you can retrieve these numbers
> but how can you edit these field numbers ?

> With ADO OR DAO.



Tue, 25 Nov 2003 06:44:54 GMT  
 When you create a field each field has a id number (field number) (how can you edit this number)
UH ... along with douglas, what about using the Alias' in yourSQL Statement
Like:

SELECT ClientID AS[Field 0], Name AS [Field 1],LastName AS [Field 2]
FROM MyTable
WHERE ...

Then use these alias name in your ADO recordset or even Crytal Report


Quote:
> Does somebody now how ?

> by example :> A Table by example  'Clients'

> has 3 fields

> - ClientID     [ Long]            Field number = 0
> - Name        [ String]            Field number = 1
> - LastName  [ String  ]        Field number = 2

> Crystal Reports uses these numbers

> but with ado and dao you can retrieve these numbers
> but how can you edit these field numbers ?

> With ADO OR DAO.



Tue, 25 Nov 2003 09:33:00 GMT  
 When you create a field each field has a id number (field number) (how can you edit this number)
The problem :>

i have by example a table in a database with 3 fields.

- IdUser                fields(1)
- Username           fields(2)
- UserLastName   fields(3)

When you add a field it wil add the fields as field(4) , thats normal !

but i want to make a new field 'UserPW' at position 3 and so the field
UserLastName will be fields(4) and not the field UserLastName :

See this in detail :

Table Now :                                        ->         Table Sync
with new Table from newer database

- IdUser                fields(1)                - IdUser          fields
(1)
- Username           fields(2)                - Username     fields(2)
- UserLastName   fields(3)                - UserPW       fields(3)        -
the new field at pos 3 and UserLastName at pos 4
                                                         - UserLastName
fields(4)

Because i'm making a upgrade program => users have a database and we as
developers have a new one ->
so database upgrade.



Quote:
> What do you mean by "edit these field numbers"?

> If you're looking to somehow change ClientID to be field 2, and LastName
to
> be field 0, change the order of the fields in your query.

> If you're looking to do edits using the field numbers (rather than their
> names), it's Recordset.Fields(n)

> --
> Doug Steele, Microsoft Access MVP
> http://I.Am/DougSteele/



> > Does somebody now how ?

> > by example :> A Table by example  'Clients'

> > has 3 fields

> > - ClientID     [ Long]            Field number = 0
> > - Name        [ String]            Field number = 1
> > - LastName  [ String  ]        Field number = 2

> > Crystal Reports uses these numbers

> > but with ado and dao you can retrieve these numbers
> > but how can you edit these field numbers ?

> > With ADO OR DAO.



Tue, 25 Nov 2003 22:01:10 GMT  
 When you create a field each field has a id number (field number) (how can you edit this number)
I'm afraid I can't think of a legitimate reason to need to insert new fields
"in the middle" of the row.

If the sequence of the fields is important, create a query (if Access) or
view that has them in the necessary order, and use that rather than the
table.

--
Doug Steele, Microsoft Access MVP
http://I.Am/DougSteele/


Quote:
> The problem :>

> i have by example a table in a database with 3 fields.

> - IdUser                fields(1)
> - Username           fields(2)
> - UserLastName   fields(3)

> When you add a field it wil add the fields as field(4) , thats normal !

> but i want to make a new field 'UserPW' at position 3 and so the field
> UserLastName will be fields(4) and not the field UserLastName :

> See this in detail :

> Table Now :                                        ->         Table Sync
> with new Table from newer database

> - IdUser                fields(1)                - IdUser          fields
> (1)
> - Username           fields(2)                - Username     fields(2)
> - UserLastName   fields(3)                - UserPW
ields(3)        -
> the new field at pos 3 and UserLastName at pos 4
>                                                          - UserLastName
> fields(4)

> Because i'm making a upgrade program => users have a database and we as
> developers have a new one ->
> so database upgrade.



> > What do you mean by "edit these field numbers"?

> > If you're looking to somehow change ClientID to be field 2, and LastName
> to
> > be field 0, change the order of the fields in your query.

> > If you're looking to do edits using the field numbers (rather than their
> > names), it's Recordset.Fields(n)

> > --
> > Doug Steele, Microsoft Access MVP
> > http://I.Am/DougSteele/



> > > Does somebody now how ?

> > > by example :> A Table by example  'Clients'

> > > has 3 fields

> > > - ClientID     [ Long]            Field number = 0
> > > - Name        [ String]            Field number = 1
> > > - LastName  [ String  ]        Field number = 2

> > > Crystal Reports uses these numbers

> > > but with ado and dao you can retrieve these numbers
> > > but how can you edit these field numbers ?

> > > With ADO OR DAO.



Wed, 26 Nov 2003 05:18:45 GMT  
 When you create a field each field has a id number (field number) (how can you edit this number)
Responding to private e-mail:

Quote:
> I now what you are saying but, crystal reports uses that number
> (in my program it will never used)
> but stupid crystal uses the id-numbers of the fields...

> do you have a sugestion ?

You mean other than my suggestion of creating a query or view that has the
fields in the order you need, and using that rather than the table? No,
afraid not.

What I don't understand is if you're adding new fields to the table, how
does CR get field numbers other than what you've created?

--
Doug Steele, Microsoft Access MVP
http://I.Am/DougSteele/



Quote:
> I'm afraid I can't think of a legitimate reason to need to insert new
fields
> "in the middle" of the row.

> If the sequence of the fields is important, create a query (if Access) or
> view that has them in the necessary order, and use that rather than the
> table.

> --
> Doug Steele, Microsoft Access MVP
> http://I.Am/DougSteele/



> > The problem :>

> > i have by example a table in a database with 3 fields.

> > - IdUser                fields(1)
> > - Username           fields(2)
> > - UserLastName   fields(3)

> > When you add a field it wil add the fields as field(4) , thats normal !

> > but i want to make a new field 'UserPW' at position 3 and so the field
> > UserLastName will be fields(4) and not the field UserLastName :

> > See this in detail :

> > Table Now :                                        ->         Table Sync
> > with new Table from newer database

> > - IdUser                fields(1)                - IdUser
fields
> > (1)
> > - Username           fields(2)                - Username     fields(2)
> > - UserLastName   fields(3)                - UserPW
> ields(3)        -
> > the new field at pos 3 and UserLastName at pos 4
> >                                                          - UserLastName
> > fields(4)

> > Because i'm making a upgrade program => users have a database and we as
> > developers have a new one ->
> > so database upgrade.



> > > What do you mean by "edit these field numbers"?

> > > If you're looking to somehow change ClientID to be field 2, and
LastName
> > to
> > > be field 0, change the order of the fields in your query.

> > > If you're looking to do edits using the field numbers (rather than
their
> > > names), it's Recordset.Fields(n)

> > > --
> > > Doug Steele, Microsoft Access MVP
> > > http://I.Am/DougSteele/



> > > > Does somebody now how ?

> > > > by example :> A Table by example  'Clients'

> > > > has 3 fields

> > > > - ClientID     [ Long]            Field number = 0
> > > > - Name        [ String]            Field number = 1
> > > > - LastName  [ String  ]        Field number = 2

> > > > Crystal Reports uses these numbers

> > > > but with ado and dao you can retrieve these numbers
> > > > but how can you edit these field numbers ?

> > > > With ADO OR DAO.



Thu, 27 Nov 2003 00:41:36 GMT  
 
 [ 6 post ] 

 Relevant Pages 

1. Reading a field and using that field to place a number in another field

2. Breaking up a phone number field into seperate fields

3. Convert number field to text field.

4. Concatenating a Text Field and a Number Field

5. need help finding first available number in an ID field

6. Auto Number in a Number Field

7. Adding Total Number of slides to the page number field in the footer

8. Having trouble accessing single field key with two concatenated fields

9. Creating a uniqued record number with outside fields

10. Creating Custom Auto Number Fields

11. Creating Custom Auto Number Fields

12. Create field with Number name

 

 
Powered by phpBB® Forum Software